Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Mobile Movie Texture

Discussion in 'Assets and Asset Store' started by DanTreble, Dec 17, 2011.

  1. GustavoVirtual

    GustavoVirtual

    Joined:
    Sep 5, 2012
    Posts:
    3
    Hello,
    I’m using your demo to check their behavior. I’m interested in buy it for RA mobile applications.

    I would like to ask some things.
    Could you upload the last version for a demo? Thanks a lot! :)

    I’m interested in play videos with sound, now I’m trying to add sound to a GameObject and play it. So I have sync problems. I’m looking for information about that problem in this thread. People ask about, but I didn’t found any solution.
    Have anybody some solution or trick for this problem? I don’t need an accurate sync.

    Best regards.
     
  2. darkmax

    darkmax

    Joined:
    Feb 21, 2012
    Posts:
    83
    i'm also interested in this about sync the audio, because i have working app,but the audio is not synchronized on some devices and on others is synchronized.

    Also if some one knows how can i check if the movie has ended?, i saw that the script has a event for this, but i have used events so i have no idea and how to use this, also i check some tutorials about this but without success on this matter.
     
  3. darkmax

    darkmax

    Joined:
    Feb 21, 2012
    Posts:
    83
    also i don't need a precise sync just something close to the sync, and i noticed on some devices y more accurate than other, i imagine because some has more power processor than others
     
  4. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    If the demo solves your problems, so will the paid version :)


    Try the attached script View attachment $MovieAudioController.cs as a starting point. Really the audio should start before the video to account for mixing buffers.
     
  5. J_P_

    J_P_

    Joined:
    Jan 9, 2010
    Posts:
    1,027
    Maybe I missed it, but I didn't see it in OP -- what do I use to encode a movie to ogg theora? I'm on OSX and would prefer a free option
     
  6. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    I use this it is free and works on all platforms (command line) //v2v.cc/~j/ffmpeg2theora/ I _think_ there are gui options available.
     
  7. J_P_

    J_P_

    Joined:
    Jan 9, 2010
    Posts:
    1,027
    Thanks -- saw in the instructions that VLC does it too. Worked fine
     
  8. J_P_

    J_P_

    Joined:
    Jan 9, 2010
    Posts:
    1,027
    Appreciate the demo -- made it an easy purchase when I already knew it'd work for my needs :)

    I'm doing an AR app and there'll be a few markers with video so I want to make sure it's optimized. If the movie is paused, will that relieve the CPU from most of its work? And do you have any suggestions for keeping RAM usage to a minimum so that I'm not using all my memory to hold movies that might not be visible at that time?
     
  9. Gnimmel

    Gnimmel

    Joined:
    Apr 21, 2010
    Posts:
    358
    I'm testing out the demo version and so far I'm very impressed. 720 by 480 movies on a iphone 4, nice plug-in Dan :)

    I do have a quick code question. I'm playing a movie, waiting for user input and then playing a second movie. The last frame of the first movie is the same as the first frame of the second movie, so it's a seamless change. I have this working, but I changed m_path in MobileMovieTextures.cs to public so I could change the path file from code. I'm simply calling .Stop of the first movie, changing m_path to a new movie file name and then playing it with .Play. Is this ok, or am I missing somthing that will cause memory leaks or problems latter? Is there a better way to change movies I'm missing?

    Thanks,

    Richard
     
  10. Edvard

    Edvard

    Joined:
    Sep 8, 2012
    Posts:
    1
    Hello

    I bought "Mobile Movie Texture" with Asset Store of Unity.
    Our animated video work correctly, the problem occurs when using the slider fast forward, we can not rewind our video, is it possible to do?.
     
  11. boonyifei

    boonyifei

    Joined:
    Sep 8, 2012
    Posts:
    6
    Hi, I'm currently evaluating the demo for a project and I'm almost ready to buy the full version, just need to clarify one more thing.
    Can I set the movie file to loop at the last few seconds once it has done playing? For example I have a movie clip that is 10 seconds long, the movie will start playing till the end and when it reaches the end, it will loop the last 3 seconds?
     
  12. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Yeah, the cpu wont be doing anything. Obviously if you can see the texture the gpu will still be running the shader

    If the movies are the same pixel dimensions, you can reuse mobilemovietexture components. It wont reallocate the textures.
     
  13. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    That's fine. Stop will call Close which cleans up the ogg internals and Play will call Open which will destroy and reallocate the textures if it has to.
     
  14. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    I'm really sorry Edvard, fast forward and rewind are not supported :-(
     
  15. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Easiest way of doing that is to chop the movie into two. The part that plays straight and the part that loops.
     
  16. boonyifei

    boonyifei

    Joined:
    Sep 8, 2012
    Posts:
    6
    Hi, Thanks for replying.
    I've another question, so once a movie has ended, I've tried playing it again with the Play() function but there's a significant delay (more than 30 seconds) before the movie plays again. Am I doing something wrong? I'm using the demo version, does it have the delay in the full version?
     
  17. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Shouldn't be a 30 second delay :-( Can you send me a sample I can check out please?
     
  18. boonyifei

    boonyifei

    Joined:
    Sep 8, 2012
    Posts:
    6
    Hi thanks for the fast reply.

    So I've tried a fresh install of the demo package and it is working now with no delay! Must have been something in my code that is causing the delay.
    Thanks again for your replies, I'll be buying the full version!
     
  19. runonthespot

    runonthespot

    Joined:
    Sep 29, 2010
    Posts:
    305
    I'm curious about using this package to do UI for a game I'm working on. The UI would be designed in after effects and consist largely of animated lines encoded into video (no sound), for use on iPad. Each clip would be quite short (probably 10 seconds maximum, or less)- is this something that is likely to be fast enough to achieve that? Would we be facing major fillrate problems for, say, a video that is 90% transparent except for lines?

    Thanks,
    Mike
    @runonthespot
     
  20. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Sounds like it should work. The limiting factor will be the resolution of the video. You might end up doing a second smaller copy for older devices (eg 3GS). The other trick will be in reusing the same textures to decode the multiple clips in. You don't want lots and lots of large 10 second video clips each with their own textures to decode in.
     
  21. runonthespot

    runonthespot

    Joined:
    Sep 29, 2010
    Posts:
    305
    This would probably target iPad 2 or better, so that initially sounds promising. Thanks!
     
  22. dev_peter

    dev_peter

    Joined:
    Aug 9, 2012
    Posts:
    38
    hi i've send you a PM. Could you perhaps check it and send me the new version since the store still isn't displaying the new version. Thanks!
     
  23. dev_peter

    dev_peter

    Joined:
    Aug 9, 2012
    Posts:
    38
    When I try to set the path: this.GetComponent(MobileMovieTexture).Path = "new_video.ogg"
    it says that Path is readonly. How can I change the path? I have to play 12 different movies and I want to use just one prefab with everything assigned and then just change the path to play the right movie.
     
  24. MatthewLeeFarmer

    MatthewLeeFarmer

    Joined:
    Jul 31, 2012
    Posts:
    14
    Hello Mr. Treble,

    So we're having some performance issues concerning mobile movie texture and some medium range ios devices. (iPod Touch Gen 4, iPhone 4, iPad Gen 2)

    When the scene contains a movie roughly about half the size of the screen, that's when frame-rate drops into problem territory. Full screen is unplayable. We've tried a few things to alleviate the issue.

    The main thing we tried was the bitrate. We lowered it to something like 10 (which also lowered it's disk size to somewhere in the kilobytes) but this had no benefits to performance. We also lowered other environmental factors of slow-down, but there's still to much of a drag on performance.

    I'm thinking it's probably due to the resolution of the video (due to textures being read into memory each frame). Is there anything we can do to the video/plugin that might improve performance besides reduce the resolution of the video?

    Thank you for your time!
     
  25. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    I don't have a PM yet :-(
     
  26. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    You could make it public or add a set property :)
     
  27. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Mr Lee Farmer

    Yeah resolution is a big factor, you could include smaller versions of the videos for these devices. I have looked to see if there is any kind of level of detail theora can do internally, but sadly there isn't anything. Internally you can turn the post processing up, but that only makes it slower. You could try playing round with where it uploads the textures in MMT, currently in Update, I've always wondered if LateUpdate might be better.

    Sorry to have no magic bullet :-/
     
  28. dev_peter

    dev_peter

    Joined:
    Aug 9, 2012
    Posts:
    38
    I'll try that :)
    Send you a PM just now. Hopefully this time it'll find the way to you :)
     
  29. J Rull

    J Rull

    Joined:
    Sep 24, 2012
    Posts:
    2
    Hello, we have bought the plugin in the last week and just found an issue with it, the movie texture looks great on the PC but when we try to build on to Android, we got the unexpected result. where the color channel is being offset.

    Any idea why would it happen and how to fix it?
    Thanks for the plugin and it saved a lot of time for us!

    Thank you very much!



    The result on the PC:


    The result on the Android (Samsung Galaxy Tab):
     
  30. dev_peter

    dev_peter

    Joined:
    Aug 9, 2012
    Posts:
    38
  31. J Rull

    J Rull

    Joined:
    Sep 24, 2012
    Posts:
    2
    Thanks! I didn't notice someone had posted the same issue before.
    the issue fixed after replaced two files.
     
  32. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
  33. wilco64256

    wilco64256

    Joined:
    Jul 3, 2012
    Posts:
    20
    I'm getting this error:

    EntryPointNotFoundException: OpenStream
    MobileMovieTexture.Open () (at Assets/Plugins/PosCommon/PosComponents/MobileMovieTexture.cs:268)
    MobileMovieTexture.Play () (at Assets/Plugins/PosCommon/PosComponents/MobileMovieTexture.cs:214)
    MobileMovieTexture.Start () (at Assets/Plugins/PosCommon/PosComponents/MobileMovieTexture.cs:203)

    On every attempt to play any video. I've restarted Unity, I've restarted my computer, no clue what it's upset about.
     
  34. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Sounds like you have a mismatch of retail MobileMovieTexture.cs and demo theorawrapper.dll
     
  35. wilco64256

    wilco64256

    Joined:
    Jul 3, 2012
    Posts:
    20
    THANK YOU. I originally thought it was a dll problem but for some reason Windows search wasn't finding that specific file when I searched the whole project for *.dll so I had to find it manually and move it over to my full project.
     
  36. harold.hou

    harold.hou

    Joined:
    Oct 10, 2012
    Posts:
    1
    Hi.

    I bought "Mobile Movie Texture" with Asset Store of Unity.
    But i can only download 1.1.4, how can i download the version 1.1.5 23/08/2012.
     
  37. dev_peter

    dev_peter

    Joined:
    Aug 9, 2012
    Posts:
    38
    1.1.4 is the latest version in the store. DanTreble mentioned before that the update is still pending
     
  38. willsnake

    willsnake

    Joined:
    Oct 16, 2012
    Posts:
    1
    Hi!
    I'm using the demo version, and I'va changed the video from the demo scene. I've converted a video from mp4 to ogg as the plugin needed. I've also got the sound of the video on a mp3 archive so it can be played diferent, but it's gonna look that it's played as the same time as the video.
    Anyway I've got everything up and running, except that the video is slower than the original version.
    How can I play it to the right speed?
    Thanks for your help.


    Daniel
     
  39. pmws

    pmws

    Joined:
    Sep 18, 2012
    Posts:
    7
    Hey,


    about the issue with the areno 200 crashes...
    MMT crashes every second time on my Nexus One. Does that mean that it will crash on any device with a areno 200 GPU?
    Unfortunatly I dont have any other devices with that chipset to test on,

    Thanks,

    paul
     
  40. wilco64256

    wilco64256

    Joined:
    Jul 3, 2012
    Posts:
    20
    So I've built a demo version of our current project with this and we have loads of people downloading and playing it, most of them with no problem at all, but I've had a few people run into an issue where they get this error making the game unresponsive when a video (which plays fine for 99% of the other people) tries to start playing:

    DllNotFoundException: C:/Users/Michael/Downloads/DemoTest/Cognition_Data/Plugins/theorawrapper.dll

    Even though that dll is most definitely in that folder, it's packaged with the demo and unpacks into that exact location.
     
  41. SevenBits

    SevenBits

    Joined:
    Dec 26, 2011
    Posts:
    1,953
    Which is a problem for anyone whose username is not Micheal.
     
  42. wilco64256

    wilco64256

    Joined:
    Jul 3, 2012
    Posts:
    20
    No that error is actually custom, in the error it reports the correct path for each person who is encountering the problem. It doesn't use an absolute path.
     
  43. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    What converter did you use?
    Does it play the right speed on a desktop player, VLC etc?
    The speed of a video should be encoded in the video itself.
     
  44. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
  45. SevenBits

    SevenBits

    Joined:
    Dec 26, 2011
    Posts:
    1,953
  46. lucas.tejero

    lucas.tejero

    Joined:
    Oct 15, 2012
    Posts:
    3
    Hi Dan i want to buy your plugin but first i want to know if i can change the Path by code and if i can know the currentFrame of a video,thank you in advice from Argentina
     
  47. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Hey Lucas, why don't you download the demo first and check it out?
     
  48. lucas.tejero

    lucas.tejero

    Joined:
    Oct 15, 2012
    Posts:
    3
    im using the demo but when i try to put public the m_path to change it by code the video change to negative and the watermarks disappear.thank you for the quick reply

     
    Last edited: Oct 25, 2012
  49. lucas.tejero

    lucas.tejero

    Joined:
    Oct 15, 2012
    Posts:
    3
    Dan i buy the full version and i try it again with excellents results,thank you very much for your time to do this great plugin!!
     
  50. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Great news! I don't know what was happening with the demo, but as long as the retail works I guess :)