Page 1 of 1

RenderMovieFrame with overlay text?

Posted: Wed Jul 26, 2006 12:11 am
by RoxBox
I have been reading the forums, searching, ... and can not find anything that seems to work.

What I want to do is play a MPG or AVI file and display text or other 2d items on the image that changes as the movie plays.

I want to create a OSD (On Screen Display) that overlays the movie.

in the moveplayer sample, I can do the following but then can not erase what has been drawn.

If StartDrawing(WindowOutput(0))

Box(10,10,20,20)
Line(30,50,100,MovieStatus(0))
StopDrawing()
EndIf

creates a line that draws with the end y changing, the prev line is left behind.

tried with rendermovieframe and could not see the line.


windows XP SP2 DX9.

Thank You
Frank

Posted: Wed Jul 26, 2006 2:02 am
by J. Baker
How about drawing it by a pixel at a time instead of a whole line. Also, if you make your 2D drawings as images, you can load and delete them.

another example

Posted: Wed Jul 26, 2006 3:33 am
by RoxBox
say I want to desplay the current time at the bottom left of the movie. the way that I can get it to work does not erase the time desplayed before and just writes on top of it. it does write on top of the movie, but after you write the time more then once, you can not read it.

I was thinking of XOR of the background to erase, but that I do not think would work as the movie image is changing and would not be the same image.

Thanks

Posted: Thu Jul 27, 2006 6:00 am
by superadnim
you should always go the GUI way, use the windows OS gadgets, in those versions where transparency and alpha is possible you can make the OSD etc with it, and even in those versions where you cant (like 9x) you still could have an OSD.

basically you make a borderless window and draw ON IT..

is that so hard? why the hell do you have to waste CPU on actual image processing for a silly OSD? you're nuts or your eyes still closed.

guess i am nuts!

Posted: Thu Jul 27, 2006 6:39 am
by RoxBox
(Closed eyes) Just so you will know, This would be used for more then just a simple OSD. The OSD is a way to explain something close to what I want to do without telling the world exactly what I am really going to do.

I did not ask how to overlay two windows or overlay a transparent window on top of a movie, I can do that now. I can even make the window the shape of the words and numbers that I want to overlay. Open your eyes and read what I was asking and if you can not answer it, and be nice about it, dont answer....

I see you have not posted more then four post, you must be new to purebasic, maybe you should read a few post before you try to help someone!

The above is the only item that would make my project better and If purebasic is not or can not do this in a fast and simple manner, I will stay with what I have now and not wast my time learning a new system.

As you can see, I have not used purebasic, I do not want to learn the low level directx code just to be able to display STUFF on top of a movie (MPG) that is playing. I am looking for the right tool for the job, Is purebasic it? thats what I am wanting to find out.


PS I did read a lot of post related to movies, sprites, images so that I could find out if purebasic would do what I wanted it to before I ask.

superadnim!, for someone that does not even know how to use simple pointers to pass arrays around you sure know everything else!



Frank

Posted: Thu Jul 27, 2006 7:56 am
by superadnim
I see you have not posted more then four post, you must be new to purebasic, maybe you should read a few post before you try to help someone!
RoxBox
New User
New User


Joined: 24 Jul 2006
Posts: 4
Maybe you should shut up, hipocrit.


You cant pass a pointer and later on access the array as in: array(0) = 2
thats why the question I made, you jerky.

Code: Select all

Dim Array(4)

Procedure Test( Pointer.l )
  
  Array() = Pointer

  Array(0) = 3
  Array(1) = 44
  
EndProcedure

Test(Array())
Debug Array(0)
Debug Array(1)

You cant do that in PB



As you can see, I have not used purebasic, I do not want to learn the low level directx code just to be able to display STUFF on top of a movie (MPG) that is playing. I am looking for the right tool for the job, Is purebasic it? thats what I am wanting to find out.
Shall Fred bring you a cup of coffee too?, what a newbie.
If you expect to find an "all in one" language, then you better rox da box somewhere else off this planet.

Posted: Thu Jul 27, 2006 9:54 am
by Dare
Whoa "superadnim", take a raincheck.

Posted: Thu Jul 27, 2006 11:12 am
by Pantcho!!
I am not taking anyone side but "superadnim" or superadmin i dont know... you are being a little rude and as for a newbie you should know you need to give a little respect, and if your such a hot shot why dont ya post some little code in tricks and tips instead of giving theories.

and as for a newbie it seems you know a little (you know who is Fred).
Forgot your forum password? :D

Posted: Thu Jul 27, 2006 12:24 pm
by Fred
superadmin: another reply with this tone and you're out.