|
I use so how is the correct way to get the length of video or
(comments are locked)
|
|
Do you not already know the duration of the movie clip from what you see in the import settings as well as in your finder? You also know what framerate it plays so you could just create a yield for that duration. well, how do i get that value programatically during runtime then?
Jul 04 '11 at 02:40 PM
uray
(comments are locked)
|
|
Start a timer and know the time for example void Awake() { } if(movieTexture.isPlaying == true) { } Now, elapsedTime will return your movieTexture Duration
(comments are locked)
|
|
We don't have a in built method to read the time but there's a traditional way.. function Awake() { startTime = Time.time; } Now some where in update or OnGUI write this following code.. if(movieTexture.isPlaying == true) { } Now elapsedTime returns the time taken by the movieTexture
(comments are locked)
|
