Search Unity

Mobile Movie Texture

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

  1. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,620
    Any pointers for this? The link settings are as follows, with the error in bold. Unfortunately I don't know where the setting the typo originates from can be found:
    Perhaps it's a coincidence, but it's immediately after the inclusion of the theora stuff.
     
  2. Pon-Somean

    Pon-Somean

    Joined:
    Aug 5, 2013
    Posts:
    5
    Hi everyone, DanTreble !

    Can i ask you a question?
    I have a problem with Mobile Movie Texture

    When i am trying to download Video from server then write it StreamingAsset folder:
    - In Unity editor : it works well
    - In iOs : it doesn't allow me to write

    My question is:
    - How can we change the path of MobileMoveTexture to somewhere else besides StreamingAsset folder? like cache etc..
    - Do we have others solutions to download video from server by keep using Mobile Move Texture?

    Here is some Code i have tried , thanks :

    IEnumerator DownloadAndCache(ModelData data) {

    WWW www = new WWW(data.VideoUrl);
    yield return www;
    System.IO.File.WriteAllBytes( Application.streamingAssetsPath + "/MovieSamples/ExplosionSplitAlpha1.ogv", www.bytes);

    // After download video load Video prefab to scene hierarchy
    GameObject instance = Instantiate(Resources.Load("Prefabs/Video", typeof(GameObject))) as GameObject;
    instance.transform.name = "UFO";
    instance.transform.parent = gameObject.transform;
    instance.transform.localPosition = new Vector3(0,0,0);
    instance.transform.localRotation = Quaternion.Euler(new Vector3(0,180,0));
    instance.transform.localScale = new Vector3(0.0078125f,0.005f,0.00468f);
    isLoading = false;

    }
     
    Last edited: Mar 28, 2014
  3. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Ski Safari Adventure Time has the same -liPhone-lib in its linker command and it's shipped and on the store

    Code (csharp):
    1. Ld autopilot/SkiSafariAT.app/SkiSafariAT normal armv7
    2.     cd "/Users/Shared/Jenkins/Home/jobs/Ski Safari AT (iOS)/workspace/builds/iPhone"
    3.     export IPHONEOS_DEPLOYMENT_TARGET=5.0
    4.     export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    5.     /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.1.sdk -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/builds/iPhone/autopilot -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/Assets/Editor/TestFlightSDK -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/Assets/Editor/StoreKit -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/Assets/Editor/Omniture -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/Assets/Editor/iCloud -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/Assets/Editor/GameCenter -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/Assets/Editor/ComScore -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/builds/iPhone -L/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/builds/iPhone/Libraries -F/Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/builds/iPhone/autopilot -filelist /Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/builds/iPhone/build/Unity-iPhone.build/Release-iphoneos/Unity-iPhone.build/Objects-normal/armv7/SkiSafariAT.LinkFileList -dead_strip -weak_framework CoreMotion -weak-lSystem -ObjC -stdlib=libstdc++ -fobjc-link-runtime -miphoneos-version-min=5.0 -framework Foundation -framework UIKit -framework OpenGLES -framework QuartzCore -framework OpenAL -liconv.2 -lPlayHaven [B]-liPhone-lib [/B]-framework AudioToolbox -framework CFNetwork -framework MediaPlayer -framework CoreLocation -framework SystemConfiguration -weak_framework iAd -framework CoreMedia -framework CoreVideo -weak_framework AVFoundation -framework CoreGraphics -weak_framework CoreMotion -weak_framework GameKit -framework Security -lcomScore -framework AssetsLibrary -weak_framework MessageUI -lz.1.1.3 -lGameCenterPlugin -lP31MonoBridge -liCloudPlugin /Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/Assets/Editor/Omniture/admsAppLibrary.a -framework StoreKit -framework AdSupport -lStoreKit -lTestFlight -lz -Xlinker -dependency_info -Xlinker /Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/builds/iPhone/build/Unity-iPhone.build/Release-iphoneos/Unity-iPhone.build/Objects-normal/armv7/SkiSafariAT_dependency_info.dat -o /Users/Shared/Jenkins/Home/jobs/Ski\ Safari\ AT\ (iOS)/workspace/builds/iPhone/autopilot/SkiSafariAT.app/SkiSafariAT
    6.  
     
  4. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Check out the 2.0.2 demo on the first page, it has an option to specify an absolute path now. 2.0.2 is submitted and should be on the asset store soon.
     
  5. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,620
    Alright then. Any other clues as to what it could be?
     
  6. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Sorry, I've not seen that particular error before.
     
  7. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,620
    That in particular seems to be an issue with Xcode screwing up its own paths by over-escaping things. (See here and here.)

    However, fixing that takes me straight back to the linker errors. This is despite the fact that it's a complete rebuild from Unity. The libtheorawrapper.a file is definitely present both in the libraries list in Xcode and in the Libraries folder in the Xcode project.

    I'm currently updating Xcode, as it doesn't seem like I have any other options.
     
  8. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,620
    Same issue in Xcode 5.1.
     
  9. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,620
    Are the following the link errors your instructions.txt refers to?
    Code (csharp):
    1. Undefined symbols for architecture armv7:
    2.   "_UnitySetGraphicsDevice", referenced from:
    3.       RegisterMonoModules() in RegisterMonoModules.o
    4.   "_UnityRenderEvent", referenced from:
    5.       RegisterMonoModules() in RegisterMonoModules.o
    6. ld: symbol(s) not found for architecture armv7
    7. clang: error: linker command failed with exit code 1 (use -v to see invocation)
    Even with an updated Xcode and fixing its over-escaped paths, I still get the above after doing as the instructions say.
     
  10. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,620
    *sigh*

    For people in the future, if you use the demo then upgrade to the paid version of the Mobile Movie Texture, you need to delete the "...Manager" script. That's where the linker errors were coming from.

    @DanTreble: It'd be cool if you expanded your instructions to cover this case. They do mention different things that can come from upgrading, but not this. Though I'd suggest putting it at the start of the doc instead of / as well as in the troubleshooting at the end.
     
  11. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Sorry about that, the paid is at 1.1.7 and demo is at 2.0.2, when the updated paid version clears submission, it shouldn't be a problem.
     
  12. sd149759

    sd149759

    Joined:
    Mar 31, 2014
    Posts:
    1
    I had a same problems as MrBloggy.
    我也遇到了这个问题,在快速点击屏幕切换视频的时候,会出现闪紫色或绿色的现象
    How can I send .apk for you E-mail.My E-Mail sd149759@qq.com.
     
    Last edited: Mar 31, 2014
  13. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    My email is in the instructions.txt
     
  14. Voronoi

    Voronoi

    Joined:
    Jul 2, 2012
    Posts:
    587
    I am evaluating this script and would like to use a webcam and/or device camera for the movie source. Is this possible? And, could you direct me where I would feed the movie to your script?

    I'm interested in trying out the live chroma key abilities. Looks very cool!
     
  15. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Sorry Voronoi, I don't think this plugin will solve your problem. Feel free to check out the demo though, it is linked in the first post and fully featured.
     
  16. Pon-Somean

    Pon-Somean

    Joined:
    Aug 5, 2013
    Posts:
    5
    Hi Dan

    Thank you for your great plugin.
    I have seen the note of Mobile Movie Texture state that " Does not support audio or streaming form a URL".
    Does it simply mean that the plugin is support to play the video from URL without streaming?

    Recently, i want to download video from internet and write it to StreamingAsset folder but iOS does not allow me to do so.
    - Can you point me out some ideas of how to use video from internet?

    Now i am trying your demo version 2.0.2, and it works just fine because it support full path.
    - When will you exactly release your demo plugin 2.0.2 to asset store? I am waiting for it.

    Thank you !
     
  17. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Download to this path Application.persistentDataPath or this path Application.temporaryCachePath
    I got a email to say it had cleared about 4 hours ago, hopefully it is there.

    Thanks!
     
  18. mohydineName

    mohydineName

    Joined:
    Aug 30, 2009
    Posts:
    301
    Hello,

    Is streaming from an URL impossible to add as a feature?

    Stephane
     
  19. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    No, it is just a lot of work. It requires 3 very different implementations. I'd need to learn iOS objective c http api, Android java api and something different on Mac/PC
     
  20. Pon-Somean

    Pon-Somean

    Joined:
    Aug 5, 2013
    Posts:
    5
    Hi Dan
    Happy to see your plugin in the asset store.

    I am upgrading from demo version to the one from asset store but there is still a demo sign.
    Do you have a note for that upgrading.?
     
  21. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Try closing and reopening Unity. It doesn't reload the dll until till you close the application, re open and play a movie.

    There is a chance it didn't update the dll as the editor had it open during the upgrade. You may need to reimport.
     
  22. Pon-Somean

    Pon-Somean

    Joined:
    Aug 5, 2013
    Posts:
    5
    Thank you a lot Dan ...! It works now.
     
  23. mohydineName

    mohydineName

    Joined:
    Aug 30, 2009
    Posts:
    301
    Hello Dan,

    In that case, maybe it would be wise to let the community implement it for you?

    I mean if you can "open" your plugin just enough for this to work and provides a few directions, I would be glad to take a look at it and see if I can come up with something nice for it, using maybe the WWW class unity provides.

    The reason I am asking this is that I need a better control over how movies are played in Unity IOS and Android. I need to know where players click on a part of a movie, and so on. I'd prefer a solution like yours where everything runs inside Unity rather than a plugin-like implementation like the MPMovieViewController that unity provides.

    Stephane
     
  24. DavidRDev

    DavidRDev

    Joined:
    Jul 19, 2012
    Posts:
    47
    Hello I just updated to latest plugin version and now I'm getting this error when I build to device: Everything works fine in Editor?!!?


    (null): Internal error: atom not found in symbolIndex(__ZN13PlaybackState10UploadBodyEv) for architecture armv7


    What is going on?? now I can't revert to the previous version I had and I can't build to device.... everything was working fine?!?!
     
  25. HazelInANutshell

    HazelInANutshell

    Joined:
    Jul 26, 2013
    Posts:
    8
    Hi DanTreble,

    Is there future plan to play the video with sound ?

    If not ,what will be the best way to do it on android ?
     
  26. DavidRDev

    DavidRDev

    Joined:
    Jul 19, 2012
    Posts:
    47
    Hey Dan I believe there is a conflict between your plugins and other plugins that we have. Is there a way you could provide 1.6 or a previous version from 2.0.2? We bought the license a while ago. I need to revert the library files to that version(everything was working fine).

    My email is denko4986@gmail.com

    help would be really appreciated, thanks!
     
  27. TripAAA

    TripAAA

    Joined:
    Nov 20, 2012
    Posts:
    8
    Anyone figure out a decent solution for Audio when using this on mobile? Someone said , hey just handle it yourself but how? If I just throw it on a gameobject and tell it to play there is no way to keep it in synch with the video on the various devices with different CPU's!
     
  28. mohitramani

    mohitramani

    Joined:
    May 29, 2013
    Posts:
    4
    Hi,
    Need to buy the plugin but can't buy unless the sound is fixed. Any tentative date for that. I need the plugin urgently. Looking forward.

    Thanks,
    Mohit
     
  29. Virtualware

    Virtualware

    Joined:
    Sep 17, 2012
    Posts:
    75
    Hi,

    I'm developing an application that uses Qualcomms Vuforia and the Mobile Movie Texture plugin to play videos with chroma in Augmented Reality for Android and iOS.

    If you haven't heard of it, Vuforia uses it's own plugins, and it writes to the AndroidManifest.xml and its main Activity inherits from Unitys main Activity, initially the camera only worked in the devices but in one of its versions Unity Editor support was included by using the webcam.

    The problem I'm facing is that when the Mobile Movie Texture is included to the project, Vuforia starts to complain saying that Unity's Pro Version is required (it makes some sort of check in a dll) and the editor camera preview (using the webcam) won't work. In addition, when I publish the application it won't install in any device, it just prompts an error saying "The application wasn't installed" or similar.

    I know that the problem must be related to integrating both plugins and I was wondering if this has happened to anyone before.

    Thanks
     
  30. gkazamias

    gkazamias

    Joined:
    Apr 13, 2014
    Posts:
    2
    Hi Dan,

    I downloaded version 2.0.2 (it says 2.0.0 in instructions though) from the Asset store and I have an issue on an Android build.
    I get the following error:
    I am on Unity 4.3.4 Pro, Android Basic, Windows 7.
    It isn't supposed to demand Android Pro. Is it?

    I see this exception in the editor when trying to test it and of course it doesn't play on device.
    Switching back to a PC standalone build, It plays nice.

    Do I miss something here?
     
  31. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Uh oh :-( Looks like I've used pro api in my quest to make it faster.

    I'll PM you a link to 1.7.x that doesn't use those apis
     
  32. seyma

    seyma

    Joined:
    Sep 3, 2013
    Posts:
    4
    Hi Dan,

    I've use Mobile Movie Texture version 1.7. It worked smoothly.
    But just recently, I update to version 2.0, then it have a problem, the video is broken when display.
    See example in the picture $Screenshot.jpg $1238380_666551736726315_7221944650652454983_n.jpg
    Now I want to downgrade it, so how can I get the version 1.7.
     
  33. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Sorry to hear that :-(

    I have sent you a link to 1.7.

    Can you send me a copy of the video that doesn't play correctly please? Does it play correctly in my demo scene as opposed to the AR scene?
     
  34. seyma

    seyma

    Joined:
    Sep 3, 2013
    Posts:
    4
    Ah sorry Dan, it's my mistake, I want version 1.1.7 not 1.7.0.

    Not only one video that doesn't play correctly, but sample video and demo scene also doesn't work with AR.

    I PM u the video link
     
    Last edited: Apr 21, 2014
  35. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Sorry, that is 1.1.7, I got confused!
     
  36. seyma

    seyma

    Joined:
    Sep 3, 2013
    Posts:
    4
    Thanks a lot Dan!!!
    It seems to work correctly now.

    I am looking forward to see the updated version 2.0.

    Thanks again!!
     
  37. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Movie plays fine in a non AR scene. I probably need a GL.InvalidadeState somewhere else. Is this on iOS or Android? With Vuforia? And unity 4.3?
     
  38. seyma

    seyma

    Joined:
    Sep 3, 2013
    Posts:
    4
    I use Vuforia 2.8.7, and unity 4.3.4.
    Movie plays well in Unity editor, but doesn't work with both IOS and Android.
     
  39. Adiel

    Adiel

    Joined:
    Feb 20, 2012
    Posts:
    8
    I got the exact same problem...
    The previous version worked perfectly and this one gives us a purple-transparent version of the video when played regardless of the shader used.
     
  40. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Ive just tried Vuforia 2.8, MMT 2.0.3 and Unity 4.3.4 and it works fine :-/

    $Screenshot 2014.04.23 12.02.13 copy.png

    I need a small reproducible project if that's possible?
     
  41. Adiel

    Adiel

    Joined:
    Feb 20, 2012
    Posts:
    8

    Switched to the new 2.0.3 version, Fresh project with just vuforia 2.8, mmt 2.0.3, unity 4.3.4
    Compiled for Android (Asus Transformer), I'm experiencing a strange behavior by the plugin.
    When I try to compile it with "Play automatically" the screen is totally black and no AR camera is rendering in the background(as if it clashes with vuforia).
    When I disable the "play automatically" flag and try to call the MobileMovieTexture.Play command from within the DefaultTrackableEventHandler when the target is found - nothing happens.
    Both methods work perfectly well inside the Unity Editor.

    Monitor stuff:
    04-23 16:03:26.695: D/theorawrapper(4615): Mobile Movie Texture 2.0.2 - it's 2.0.3 regardless what it says here.
    ...
    04-23 16:03:32.235: D/dalvikvm(4615): Trying to load lib /data/data/com.qualcomm.QCARUnityPlayer/lib/libtheorawrapper.so 0x425fa5e0
    04-23 16:03:32.225: D/dalvikvm(4615): Shared lib '/data/data/com.qualcomm.QCARUnityPlayer/lib/libtheorawrapper.so' already loaded in same CL 0x425fa5e0
    ...
    04-23 16:03:32.435: D/theorawrapper(4615): Set OpenGL graphics device
     
    Last edited: Apr 23, 2014
  42. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    Sorry to hear that :-/

    Can you try adding a couple of GL.InvalidateStates around the code please?

    In MobileMovieTexture.cs

    Code (csharp):
    1.             //This is maximum frames decoded/uploaded
    2.             const int maxSkipFrames = 16;
    3.  
    4.             GL.InvalidateState(); //HERE!!!
    5.  
    6.             if (m_nativeContext != IntPtr.Zero  OpenStream(m_nativeContext, path, (int)offset, (int)length, powerOf2Textures, m_scanDuration, maxSkipFrames))
    7.             {
    8.                 GL.InvalidateState(); //AND HERE!!!
    9.  
    and maybe in MobileMovieManager.cs as well

    Code (csharp):
    1.  private IEnumerator DecodeCoroutine()
    2.         {
    3.             // Wait until all frame rendering is done
    4.             while (true)
    5.             {
    6.                 //Start a frame decoding
    7.                 yield return new WaitForEndOfFrame();
    8.  
    9. #if (UNITY_ANDROID || UNITY_IPHONE)  !UNITY_EDITOR
    10.                 GL.InvalidateState(); //HERE
    11.  
    12.                 UnityRenderEvent(7);
    I'll try and recreate the problem this end.
     
  43. hany-1

    hany-1

    Joined:
    Nov 9, 2013
    Posts:
    1
    Same issue here, any idea how to solve it ?
    Thanks
     
  44. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    None of those missing functions are from my plugin. Did you previously link another video plugin?
     
  45. MrCranky

    MrCranky

    Joined:
    Nov 20, 2012
    Posts:
    5
    Is the intention that you'll to rework that code to lose those Android Pro calls for a future revision? Or will the plugin be Pro-only from here on out?
     
  46. DanTreble

    DanTreble

    Joined:
    Aug 31, 2010
    Posts:
    590
    It sucks for a couple of reasons, but I'll try and support the non pro path as well with the next release.
     
  47. dm_reflekt

    dm_reflekt

    Joined:
    Mar 20, 2013
    Posts:
    8
    Hello DanTreble,

    I am using the plugin for a standalone build. It looks just great, but it makes the application crash sooner or later. It happens less often when I run it in a more powerful pc (better processor, better graphics card). It also happens in the editor, it makes the complete unity editor crash without warning. Here is a copy of a part of the error log produced by the build:

    "
    MSVCR90.dll caused and Access violation (0x0000005)
    in module MSVCR90.dll at 0023:1b80ae7a

    Error occured at 2014-04-28_105836

    ...

    "

    It seems to be something related to the architecture. I did some research and the bug seems to have something to do with running a x86 dll in a x64 environment or something similar. It might be fixed if I use a x64 build, but then your plugin doesn't work.

    I hope i can solve this (with your help), otherwise the project will be unsusable and I'll have to go back to the embedded MovieTexture which is just bad.

    Greetings,


    Diego
     
  48. JustGarry

    JustGarry

    Joined:
    Mar 11, 2014
    Posts:
    1
    DanTreble,

    Any chance I can get a demo of the 1.1.7 version, I don't have android pro, and want to make sure it will work before spending 70 euros.

    Thanks in advance
     
  49. Pedro-Garlaschi

    Pedro-Garlaschi

    Joined:
    Dec 6, 2012
    Posts:
    8
    Hi Guys ,

    I'm using the demo version and on my editor the alpha chroma texture works fine but when i publish to my iphone that becomes green :/ . Is that because i'm using the free version ? We are going to buy the pro anyways so let me know if i did something wrong or if is some bug or if i just need to update my license :) .
    Also you have an recommendation of any nice video converter ? Thanks

    Unity Editor
    $Screen Shot 2014-05-01 at 18.05.15.png

    Iphone
    $IMG_0055.PNG
     
  50. e3di

    e3di

    Joined:
    Nov 15, 2013
    Posts:
    14
    Hi All, does Mobile Movie Texture now support audio? or has anyone found a way to get audio running separately? I need to build an AR app using Vuforia for both iOS and Android using alpha video with audio.

    Thanks.