Drawing on a WMP Control?
WMPTalk.com Forum Index WMPTalk.com
Discuss Windows Media Player
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web wmptalk.com
Drawing on a WMP Control?

 
Post new topic   Reply to topic    WMPTalk.com Forum Index -> SDK
Author Message
Nick James
Guest





Posted: Sun Sep 05, 2004 11:14 am    Post subject: Drawing on a WMP Control? Reply with quote

I'm using VB.NET and want to draw a graphic (can be a BMP, JPG, GIF)
directly over a playing WMP control.

Any ideas on how to accomplish this? If possible, it'd be great to
incorporate transparency when drawing the graphic.

I'm hoping I don't have to use any DirectX to get it done but I'll do
what is necessary..

Thanks in advance

Back to top
Neil Smith [MVP Digital M
Guest





Posted: Sun Sep 05, 2004 2:45 pm    Post subject: Re: Drawing on a WMP Control? Reply with quote

There are some "Ifs" : The technique in general will only work if it's
an XP machine (its an OS display blending limitation), and then only
if the user has IE/windows (not in Netscape or on Mac for example)

If you're doing this in a web page, investigate the windowlessVideo
param tag <param name="windowlessVideo" value="true" />

The SDK docs say : "When windowlessVideo is set to true, the Player
object renders video directly in the client area, so you can apply
special effects or layer the video with text."

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmplay10/mmp_sdk/iwmpplayer2interface.asp

Then, you should set up two html layers, with non-identical z-indexes
and identical positioning (you'll probably need to use CSS absolute
positioning for this to work properly).

In your first container, apply your GIF or better, PNG with alpha
transparency. In your second container, with a lower z-index, embed
the media player indicating windowless video. This should make your
overlay effect work, but I'd avoid alpha transparency on any platform
other than XP, often providing a GIF with single level transparency as
your overlay would work out.

Best to investigate doing this in a static web page *before* trying to
throw vb.net into the mix I'd say ;-)

Cheers - Neil

On 5 Sep 2004 00:14:09 -0700, ryancassin@gmail.com (Nick James) wrote:

Quote:
I'm using VB.NET and want to draw a graphic (can be a BMP, JPG, GIF)
directly over a playing WMP control.

Any ideas on how to accomplish this? If possible, it'd be great to
incorporate transparency when drawing the graphic.

I'm hoping I don't have to use any DirectX to get it done but I'll do
what is necessary..

Thanks in advance
Back to top
 
Post new topic   Reply to topic    WMPTalk.com Forum Index -> SDK All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



Microsoft Office Forum New Topics
Powered by phpBB