Link to home
Start Free TrialLog in
Avatar of BlueAlien
BlueAlien

asked on

Directshow subtitles (preferably anti-aliased)

Hi.

I'm writing a simple video player application, and I need to display subtitles and/or other controls (i.e. volume level). I'm using pure directshow from directx9 and windowless mode (at least i think, the video is displayed on a forms canvas). I need to display the subtitles (preferably anti-aliased). I tried to display the subtitles in a second form above the video, but it doesn't work in fullscreen.

Code prefered (delphi or c/c++), but any advice accepted.

Thanks.
Avatar of davebytes
davebytes
Flag of United States of America image

Have you checked out the DX9 DShow samples?  I just found the watermark sample:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnwmt/html/introducingsomenewvideomixingrenderersampleapplica.asp
(click the link to the watermark sample...)

Looks like it does what you are looking for, in terms of you saying "and/or other controls".  The sample should be a good starting point.

You could also ask this guy, if you specifically just want to do subtitles (sounds like there's some form of Subtitle Mixer already built-in to DS):
http://tobias.everwicked.com/

-d
Avatar of _corey_
_corey_

Depending on how you need to sync things up, the new VMR9 render filter might do what you want.  it provides an interface to use bitmap overlays and alpha values.

I've had to use a custom filter to draw text over the video stream, but you don't need to put that effort in unless you need that annotated video to save to a file.

corey
The Samples page I linked to above gives source examples that should work with both VMR7 and VMR9 -- in theory, if you believe MS. ;)

-d
Avatar of BlueAlien

ASKER

Thanks for the advice, but I wont't be able to try them till next week.
I checked out the Watermark sample, but it shows alpha-blending, not anti-aliasing. Though it helps with setting up the wmr9. I would need help with the anti-aliased text.

Thanks.
ASKER CERTIFIED SOLUTION
Avatar of davebytes
davebytes
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks for the answers and sorry for the late reply.