Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Mobile Movie Texture

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

  1. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    Do you have Unity Pro?
     
  2. Pon-Somean

    Pon-Somean

    Joined:
    Aug 5, 2013
    Posts:
    5
    Hi there,
    I am running into an issue when trying to play a movie with Vuforia sample. I got this error message in Xcode "
    Error: Incorrect Event ID ! " and it show nothing.
    In that sample app, I use Split Alpha movie, Unity 4.6.3, Vuforia 4 and MMT v 2.1.1
    Is there any body here have noticed about that?
     
    Last edited: Feb 28, 2015
  3. StandLee

    StandLee

    Joined:
    Mar 2, 2015
    Posts:
    2
    Hello, I'm using 4.6.2p2 version of unity on mac.

    When Play movie, it can't work and just show "pink" background.

    But 4.6.1f1 version of unity is OK to play my video.

    Any suggestions?

    My Test device: IPhone 6
     

    Attached Files:

  4. juanje_89

    juanje_89

    Joined:
    Feb 6, 2014
    Posts:
    22
    Hello!

    Running the latest version (2.1.1) gives me a black texture on iOS when I updated the plugin from 2.0.4 version.
    I don't know why it happens, because when I create a new project and import it, it works perfectly on iOS.

    (Update)
    Realized that on an empty project, it works, but when using Vuforia 4, it does not work anymore As I said before, only shows a black image on iOS.

    (Update 2)
    There seems to be some problems between MMTAppController.mm and VuforiaNativeRendererController.mm
    I tried to merge them unsuccessfully, as I sadly don't know how to do it without crashing the scene with the Vuforia camera.

    (Update 3)
    Finally, I got it working by creating a new app controller (MyAppController.mm in my case) and trying to merge those two files (MMTAppController and VuforiaNativeRendererController) into it.
     
    Last edited: Mar 2, 2015
  5. c_andrews

    c_andrews

    Joined:
    Jan 26, 2015
    Posts:
    106
    Hi,

    I am also having a pink screen issue on IOS, all running IOS 8 and I sometimes get a Green screen in the editor. I have tried removing MMT from my project and added it again but I haven't had much luck.

    Any idea what could be causing the issue and if it is going to be fixed? We are currently using MMT in our project and is quite a big part of it.

    Thanks,
    Chris
     
  6. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    If you are using the latest version of Unity (4.6.3) it could be that Metal on iOS is causing the issue. To fix this you need to change the graphics choice from "Automatic" to something else so Metal is not being used. It could be another issue, but check this for now.

    What are people using MMT for exactly now? We was using it for the chroma keying functionality and its cross platform use, but the lack of audio and the issues we face more often that not, we have switched over to other solutions for iOS and Android. I am not going to hijack this thread, but if people want to PM me we can talk about the best options we have found for Chroma Keying, iOS/Android playback (with audio) and Vuforia support.
     
  7. Dylan4Vr

    Dylan4Vr

    Joined:
    Mar 14, 2014
    Posts:
    1
    How can you setup multiple videos to be rendered at once?
    What I mean is to have 2 different meshes playing 2 different movies at the same time?
     
  8. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    You need to have a separate material for each video, and then they will both play together.
     
  9. JosepSerres

    JosepSerres

    Joined:
    Nov 24, 2014
    Posts:
    5
    I'm having the same issue with Vuforia 4, can u share how u merged both files?

    Thanks!
     
    JorgeQuevedoC likes this.
  10. LimSaJang

    LimSaJang

    Joined:
    Oct 26, 2012
    Posts:
    3
    Hi, I found Crash in the GearVR SDK.
    Is there a workaround?
     
  11. c_andrews

    c_andrews

    Joined:
    Jan 26, 2015
    Posts:
    106
    Thanks I think that has worked. Im using 4.6.2f1 but my Graphics Level in player settings was set to Force Open GL ES 2.0. Setting it to Automatic seems to have fixed the issue on the device. I still get a Green screen in the Editor but thats not holding up the project.
     
  12. oldbushie

    oldbushie

    Joined:
    Mar 30, 2012
    Posts:
    24
    I upgraded to Unity Pro 5 and I'm having trouble getting movies to work on Android and iOS. Android builds but won't play, and XCode refuses to sign the iOS build due to theora issues.
     
  13. juanje_89

    juanje_89

    Joined:
    Feb 6, 2014
    Posts:
    22
    Hi!

    Mine more ore less like this:


    #import <UIKit/UIKit.h>
    #import "UnityAppController.h"
    #import "VuforiaRenderDelegate.h"


    // Unity native rendering callback plugin mechanism is only supported
    // from version 4.5 onwards
    #if UNITY_VERSION>434

    // Exported methods for native rendering callback
    extern "C" void UnitySetGraphicsDevice(void* device, int deviceType, int eventType);
    extern "C" void UnityRenderEvent(int marker);

    #endif

    extern "C" void MMTUnitySetGraphicsDevice(void* device, int deviceType, int eventType);
    extern "C" void MMTUnityRenderEvent(int marker);

    // Controller to support native rendering callback
    @interface MyAppController : UnityAppController
    {
    }
    - (void)shouldAttachRenderDelegate;
    @End

    @implementation MyAppController

    - (void)shouldAttachRenderDelegate
    {
    self.renderDelegate = [[VuforiaRenderDelegate alloc] init];
    // Unity native rendering callback plugin mechanism is only supported
    // from version 4.5 onwards
    #if UNITY_VERSION>434
    UnityRegisterRenderingPlugin(&UnitySetGraphicsDevice, &UnityRenderEvent);
    UnityRegisterRenderingPlugin(&MMTUnitySetGraphicsDevice, &MMTUnityRenderEvent);
    #endif
    }
    @End


    IMPL_APP_CONTROLLER_SUBCLASS(MyAppController)

    I really don't know if thats the way it should be done, but it works for me!
     
    Abaobao, JorgeQuevedoC and Pon-Somean like this.
  14. meint8d

    meint8d

    Joined:
    Jan 31, 2014
    Posts:
    5
    Hi,
    I need to use a movie texture for IOS and would like to use the Mobile Movie Texture.
    It works fine in Unity 4.5.5 and 4.6.2, but i'm getting a green screen in Unity 4.6.3 and Unity 5 where the movie should be.
    I have an Unity Pro and Unity IOS Pro licence and using the MMT_2.1.1_Demo.

    What can i do to make this work in Unity 4.6.3 or even better, Unity 5?
     

    Attached Files:

  15. dreamade

    dreamade

    Joined:
    Feb 26, 2014
    Posts:
    5
    Hi,
    I used Mobile movie Texture Demo version, it works perfectly but when i buy MMT , i am getting black screen.
    I have Unity IOS pro license and also i use vuforia 4 but video is in another scene.
     
    BEFaughnan and rterblan like this.
  16. c_andrews

    c_andrews

    Joined:
    Jan 26, 2015
    Posts:
    106
    Ok So i thought that my issue was resolved but for some reason it has cropped back up on other devices, iPad 2 and iPhone 6 both running latest version of IOS 8. Can any one help?
     
  17. TheBlaXnoW_0

    TheBlaXnoW_0

    Joined:
    Mar 10, 2015
    Posts:
    1
    Hi,
    I'm using MMT latest version on unity 4.6.3 / windows.
    I have some issue that movie is stop in 70 seconds after start playing.
    All movies have same issue on playing.
    The movies run over 3 minutes each.
    May MMT has time limit on playing?

    Thank you.
     
  18. tomtong

    tomtong

    Joined:
    Aug 5, 2013
    Posts:
    17
    Hello. Could I use mobile camera to capture MP4 movie and load it in the texture by this plugin directly?
     
  19. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    This plugin does not offer any video capture. Only playback. The videos also have to be in the theora format, so you would need to process them before playing them.

    In short, no you cannot without finding solutions for 1) capturing 2) conversion.
     
  20. StudCortex

    StudCortex

    Joined:
    Feb 25, 2015
    Posts:
    9
    Hello,

    I tried the demo version of your plugin using Unity5 on Android and didn't obtain anything better than white/black screens using your sample scenes.
    It works fine in the editor (even with android build settings) and adb logcat do not print any error.

    Did I miss something ?
     
  21. AbandonedCart

    AbandonedCart

    Joined:
    Mar 4, 2014
    Posts:
    72
    Is there any advantage to using this over the video texture support offered directly in Vuforia?
    I was able to disconnect the video player from the target workflow and it worked perfectly. I am exploring this option for a project where I do not want Vuforia, but it seems excessive to use both.
     
  22. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    The Vuforia playback works well, but is limited in some areas. You will have to customise the scripts to make them load the videos efficiently, without an additional shader you cannot use Chroma Keying, without MMT you cannot use Split Alpha, plus unless you are using Unity 4.0 you cannot submit iOS apps anymore as Vuforia 3.x is not 64bit compatible.

    There are various reasons to use this asset, mainly for the features it contains over and above what Vuforia offers as standard.
     
  23. Spulit

    Spulit

    Joined:
    Jul 15, 2014
    Posts:
    7
    Hi,

    Any chance for a quick fix to get the plugin working using Unity 5 on Android? It worked perfectly in version 4, but I upgraded and now I only get pink screens...
     
  24. andrewfungxx

    andrewfungxx

    Joined:
    Mar 11, 2015
    Posts:
    3
    Have you find any solution on arm64?
     

    Attached Files:

  25. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    Are you using the latest version? It should be compatible.
     
  26. Ulven2

    Ulven2

    Joined:
    Apr 23, 2012
    Posts:
    64
    We're having issues with Vuforia 4 + MMT on Mac/iOS too.
    Vuforia finds and places the video plane fine and plays the video fine in windows.
    On mac in the editor the error reads:
    DllNotFoundException: theorawrapper
    MMT.MobileMovieTexture.Start () (at Assets/MobileMovieTexture/MobileMovieTexture.cs:322)
    DllNotFoundException: theorawrapper
    MMT.MobileMovieTexture.OnDestroy () (at Assets/MobileMovieTexture/MobileMovieTexture.cs:339)
    Unable to open movie 0
    UnityEngine.Debug:LogError(Object, Object)
    MMT.MobileMovieTexture:Open() (at Assets/MobileMovieTexture/MobileMovieTexture.cs:470)
    MMT.MobileMovieTexture:play() (at Assets/MobileMovieTexture/MobileMovieTexture.cs:405)
    UnityEngine.GameObject:SendMessage(String, SendMessageOptions)
    Interface:Update() (at Assets/Scripts/Interface.boo:20)

    On iOS we get this when calling play on the movie texture:
    Error: Incorrect Event ID !

    The movie does not play and we just see a black polygon where there the movie should display.
     
  27. misc

    misc

    Joined:
    Jul 11, 2012
    Posts:
    8
    Unity 5: movie with green coloring

    In Unity 5 (professional edition) with Linear Color Space active, the movie has a green coloring. When setting to Gamma Color Space the movie looks fine. What can I do to have MMT work with Linear Color Space?
     
  28. misc

    misc

    Joined:
    Jul 11, 2012
    Posts:
    8
    I run a WIN8 standalone build directly from usb stick on a desktop pc (i5, 760gtx, 8 gb ram) and MMT works fine. On a nuc (i3, intel hd graphics 4000, 8 gb ram) MMT shows a black texture. Any idea why?
     
  29. oldbushie

    oldbushie

    Joined:
    Mar 30, 2012
    Posts:
    24
  30. AbandonedCart

    AbandonedCart

    Joined:
    Mar 4, 2014
    Posts:
    72
    So it sounds like there is really no reason to purchase this if using Vuforia 4 and Unity 5 for basic playback on a texture. Thanks. All I needed to know.
     
    Last edited: Mar 15, 2015
  31. ClementDupret

    ClementDupret

    Joined:
    Feb 23, 2015
    Posts:
    3
    The demo version 2.1.1 works on Samsung Galaxy S3 and Kindle fire HD but the video is not played on Galaxy tab 8.9 (android 4.0.4).

    the log says :

    D/dalvikvm( 5716): Trying to load lib /data/data/com.testmmt/lib/libtheorawrapper.so 0x4134ea58
    D/dalvikvm( 5716): Added shared lib /data/data/com.testmmt/lib/libtheorawrapper.so 0x4134ea58
    D/dalvikvm( 5716): No JNI_OnLoad found in /data/data/com.testmmt/lib/libtheorawrapper.so 0x4134ea58, skipping init
    I/Unity ( 5716): Create context
    I/Unity ( 5716):
    I/Unity ( 5716): (Filename: ./artifacts/AndroidManagedGenerated/UnityEngineDebug.cpp Line: 49)
    I/Unity ( 5716):
    W/PowerManagerService( 190): Timer 0x7->0x3|0x15
    I/Unity ( 5716): ExecutionEngineException: SIGILL
    I/Unity ( 5716): at MMT.MobileMovieTexture.Start () [0x00000] in <filename unknown>:0


    Any idea why ?
     
  32. Whelandrew

    Whelandrew

    Joined:
    Jul 29, 2011
    Posts:
    17
    Using Unity 5 and MobileMovieTexture Full, when I run my app on iPad Mini, the video does not show and this error message appears in XCode output on a loop. Any ideas?

    OpenGLES error 0x0502 in /SampleProject/SampleProjectiOS/Classes/Unity/GlesHelper.mm:208
     
    questmill likes this.
  33. PhoeniXTail26

    PhoeniXTail26

    Joined:
    Aug 31, 2013
    Posts:
    12
    Having the same issue except I'm using the demo version. Unity 5 on iOS gives a pink texture and an OpenGLES error (0x0502). Seems to work fine in Unity 4.6.1f1 on Android. Can't test Android on Unity 5 because I don't have pro android for that.

    Is this something that is being worked on?
     
  34. shadows_s

    shadows_s

    Joined:
    Oct 7, 2013
    Posts:
    4
    Can I use it with the Windows Phone 8+ ?
     
  35. c_andrews

    c_andrews

    Joined:
    Jan 26, 2015
    Posts:
    106
    I have just updated to Unity 5 Pro and when i try to build the project for IOS i get the following error:

    Plugin 'theorawrapper.dll' is used from several locations:
    Assets/Plugins/x86/theorawrapper.dll would be copied to <PluginPath>/theorawrapper.dll
    Assets/Plugins/x86_64/theorawrapper.dll would be copied to <PluginPath>/theorawrapper.dll
    Please fix plugin settings and try again.

    UnityEditor.Modules.DefaultPluginImporterExtension:CheckFileCollisions(String)
    UnityEditorInternal.PluginsHelper:CheckFileCollisions(BuildTarget) (at /Users/builduser/buildslave/unity/build/Editor/Mono/Plugins/PluginsHelper.cs:25)
    UnityEditor.BuildPlayerWindow:BuildPlayerAndRun()

    Plugins colliding with each other.

    Any ideas no how to fix this?
     
  36. Whelandrew

    Whelandrew

    Joined:
    Jul 29, 2011
    Posts:
    17
    I bypassed this by removing one of the "theorawrapper.dll" files in the plugin folder. This will compile and run it onto your devices, but you will get the pink screen that we are seeing.
     
  37. detomato

    detomato

    Joined:
    Aug 16, 2013
    Posts:
    54
    After such a long time, anyway to get the audio to sync with the movie?
    I hope the dev is more active here, but apparently not.
     
  38. c_andrews

    c_andrews

    Joined:
    Jan 26, 2015
    Posts:
    106
    Thanks, I got the same error as well so I have reverted back to Unity 4.6.3 for the time being.
     
  39. OlliQueck

    OlliQueck

    Joined:
    Apr 11, 2013
    Posts:
    49
    Update for unity5 plz! rendertexture seems to be free now so this could work for free version maybe? I'd buy it instantly, i have multiple projects running with multiple agencies where i need video-textre for mobile systems. Different filetypes like mp4 h264 would be awesome.
     
  40. PhoeniXTail26

    PhoeniXTail26

    Joined:
    Aug 31, 2013
    Posts:
    12
    If you're getting plugin collisions in Unity 5, you can go to the separate plugin dlls in Unity, select them and make sure that only the applicable platforms are ticked instead of "All Platforms". But the pink screen problem remains. Seems this plugin needs to be updated for Unity 5.
     
  41. Nutteen

    Nutteen

    Joined:
    Sep 1, 2014
    Posts:
    4
    Hi, is there any chance I could load movie resources from a bundle file. I'm developing a game that has a lot of movies and they took so much space that they wont fit in 50 Mb (Size limitation of Android).
     
  42. SAT521

    SAT521

    Joined:
    Mar 20, 2015
    Posts:
    1
    Hi DanTreble! I have question, i make prefab use mobiletexture, but the function of open error in IPhone

    > at MobileMovieTexture.Open () [0x00000] in <filename unknown>:0
    > at MobileMovieTexture.Play () [0x00000] in <filename unknown>:0
     
  43. KieranBaker

    KieranBaker

    Joined:
    Feb 25, 2014
    Posts:
    3
    A trick we use (that may or not be useful to you) is we download a file to unity's cache location then use the absolute path for MMT to point at this location. We used .net to download the file but could use www.bytes or something similar at a guess. (Not sure how secure the transfer would be over WWW though if it's client material). This does mean you'd need somewhere to host it.
     
    Last edited: Mar 20, 2015
  44. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    MMT supports loading of videos from OBB, check the release notes. Actually what we ended up doing was copying the videos out of the expansion file and into the devices persistent data path (usually external storage). We could then load the video from that path on disk, and it works great.
     
  45. Nutteen

    Nutteen

    Joined:
    Sep 1, 2014
    Posts:
    4
  46. ClementDupret

    ClementDupret

    Joined:
    Feb 23, 2015
    Posts:
    3
    Hi,

    Does anybody have framerate problems on android ? On iOS, I can play a movie in 1280x720 at 4000 bps without problem. On Kindle fire HD or Galaxy S3, even at 2000bps it is very very laggy.
     
  47. mimminito

    mimminito

    Joined:
    Feb 10, 2010
    Posts:
    780
    All depends on the device. Certain devices will be less powerful and less able to cope with 720p videos, its advised you try and use a lower quality to enhance the frame rate.
     
  48. ClementDupret

    ClementDupret

    Joined:
    Feb 23, 2015
    Posts:
    3
    I was able to optimize the framerate by disabling VSync. For the moment I use the demo version and I wonder if the addition of watermark does'nt decrease the playback speed.
     
  49. pcion123

    pcion123

    Joined:
    Dec 24, 2014
    Posts:
    1
    The method HasFinished will not work.
    It can't feedback result,correctly
    Have anyone the same situation.
    Maybe i switch the video,frequently.

    ps.My english is not well sorry guys.
     
  50. flapy-monkey

    flapy-monkey

    Joined:
    Dec 23, 2014
    Posts:
    7

    thx for that, yes it work for mine, but it is a simple and quick way to fix the "black screen", open Xcode you still find "error event".
    any way , it works, hope plugin writer can notice the problem.
     
    juanje_89 likes this.