Microsoft Developer Network > Forenhomepage > Windows Presentation Foundation (WPF) > MediaElement Position + MediaTimeLine Duration
Stellen Sie eine FrageStellen Sie eine Frage
 

FrageMediaElement Position + MediaTimeLine Duration

  • Dienstag, 16. Juni 2009 18:35zaurska TeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillen
     Enthält Code
    Hi

    I have an AVI

    I want to play it from a storyboard from position: 10seconds to position 13seconds.

    MediaTimeLine has "Duration", but the beginTime of course relates to the storyboard not the URIsource

    MediaElement has Position but can't set duration.

    There doesn't seem to be a way to play a section of AVI, even by using code behind.

    So, I have:

    		<Storyboard x:Key="Storyboard1" >
    		 <MediaTimeline Source="j:\DATA\study\18_01_2009_162353.AVI"
                            Storyboard.TargetName="vidMedia"
                            Duration="0:0:3"
                            />
    		</Storyboard>
    

    but want to add: <Position = "0:0:10">

    Has anyone achieved this?

    Z


Alle Antworten

  • Samstag, 4. Juli 2009 19:33wguy TeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillen
     
    hi, i am also waiting for this. Any help on this question will be greatly appreciated.
  • Sonntag, 5. Juli 2009 00:25zaurska TeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillenTeilnehmermedaillen
     
    Sorry

    No, still no answer as far as I know, and I spent at least 4 hours googling.

    My get around was to put the AVI into MS movie maker - which is of course part of XP - take the clip I needed, and save the result renaming to a *.WMV.  Not exactly dynamic, and useless for when I have a bunch of samples I want to show the middle of.

    I assume it will be part of 4.0 ???

    Likewise, if you come across the answer I'd be grateful to know it.