Click here to Skip to main content
15,902,032 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello, I have a query with MediaElement.

I want to add an image/text into the MediaElement while the control is playing a video.

Somethink like that:

[Image Link]

If this isn't possible or you have any other idea, please comment
Posted

1 solution

your link does not work/.

As it's WPF, you can place an image above the media element, and if it is a PNG with transparency, your image will appear above the video. You set Canvas.ZIndex on your controls to set their order, which is far from intuitive IMO.

*Edit by Mark S*
I usually use a Grid to overlay an element on another element as Christian described, something like this:
<Grid>
    <MediaElement />
    <Image />
</Grid>
 
Share this answer
 
v2
Comments
TANicox 21-Jul-11 18:06pm    
The link works perfectly in Firefox. I tried in Chrome and it's true.
Try adding http:// at start, and try again
Mark Salsbery 21-Jul-11 18:35pm    
The order of elements in the Children collection of a Panel element also determines the Z-order, so instead of using Panel.ZIndex, simply placing the desired topmost element after other elements will work.
Christian Graus 21-Jul-11 18:46pm    
It works for you because you have permission to view the file.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900