Topic locked

No live camera feed on iOS

August 21, 2013 - 3:12am #1

Hello folks,

I'm currently having some issues with my AR project. I'm using latest Unity3D Pro (4.2.0f4) and Vuforia 2.6.7. When running on an iOS device (iPad 3 / iPad mini - iOS 6.1.3), the background appears black and no live camera is rendered as expected. However, the tracking works without any issues. Is this a known bug or did I do something wrong?

Btw, when trying to find an answer, I found a thread describing a similar issue on Android devices: https://developer.vuforia.com/forum/unity-3-extension-technical-discussion/android-422-no-camera-display

Any help appreciated!

Thanks in advance.

No live camera feed on iOS

October 29, 2015 - 7:07am #38

Thanks for the confirmation.

--Cheers

 

No live camera feed on iOS

October 29, 2015 - 6:53am #37

I can confirm that I also had a cardboard sdk in my newer project that experienced this issue but not in the older project that worked, was not even using it (yet) but it was in my project.

No live camera feed on iOS

October 29, 2015 - 2:34am #36

Thanks. I'll try in the next 2 days and report result.

No live camera feed on iOS

October 29, 2015 - 2:31am #35

Ok, so, check the steps in "OS Specific Steps" section of this article (in particular the section about removing the VuforiaNativeRendererController.mm):

https://developer.vuforia.com/library/articles/Solution/Integrating-Cardboard-SDK-050

same as OMobile did; this will resolve your issue.

 

No live camera feed on iOS

October 29, 2015 - 2:29am #34

I currently use last Cardboard SDK version (0.5.2).

No live camera feed on iOS

October 29, 2015 - 2:27am #33

Great, thanks for confirming.

No live camera feed on iOS

October 29, 2015 - 2:26am #32

It was using Cardboard. Sorry.

But works fine under Android.

No live camera feed on iOS

October 29, 2015 - 2:21am #31

My setup is:

  • Unity 5.2.2p1
  • Xcode 7.1
  • iOS 9.1
  • iPhone 6 Plus
  • Vuforia 5.0.6
  • Google Cardboard 0.5.2

All is working as long as I modify the app controller as per your guide, as the Google Cardboard controller overrides the Vuforia render delegate.

No live camera feed on iOS

October 29, 2015 - 2:18am #30

OK, thanks OMobile;

so this combo (Unity 5.2.2 + Vuforia 5.0.6 + XCode 7.1 + iOS 9.1) now  works fine for you  on iPhone 6, right ?

 

 

Wondering if morininnovation could confirm that he is not using Cardboard or any other 3rd party plugin ?

 

No live camera feed on iOS

October 29, 2015 - 2:07am #29

Turns out my issue was due to Vuforia + Google Cardboard both being in the project. I read the release notes and saw they were supported, but did not realise I had to follow a separate guide to get them working together. Might be worth putting the guide in the release notes incase others dont see it :)

No live camera feed on iOS

October 28, 2015 - 12:11pm #28

@Radix88

Done by exporting a package with the scene from my new project to the old.

If the exported unity package works OK, then chances are that the 'broken' project was not working because the content of the 'Library' folder of your Unity project was out of sync with the project assets (this can happen occasionally e.g. if you upgraded a project from an old to a new version of Vuforia and/or Unity); typically, such an error condition can be resolved by closing the Unity Editor and deleting the Library folder of the broken project, and then re-opening the project in Unity so that it will automatically regenerate a Library folder with up-to-date content.

 

 

No live camera feed on iOS

October 28, 2015 - 6:01am #27

I did not figure out the issue but I have a working build now.
Done by exporting a package with the scene from my new project to the old.

The vuforia and project settings were the same in both projects.

No live camera feed on iOS

October 28, 2015 - 5:43am #26

OK, so, based on OMobile and moreininnovation reports,

it seems there might be an issue specifically on iPhone 6 / 6 Plus on iOS 9.1, when building Vuforia projects with with Xcode 7.1 and Unity 5.x.

We'll verify that.

 

 

@Radix88:

your issue seems possibly a slightly different one, as you mention iPad 3 and some previous builds of your App that were working; so, it could be just an upgrade/migration issue in your case; I'd recommend to try the Vuforia samples first and see if you can reproduce the same issue there, and in case, open a bug report with detailed steps to reproduce here:

https://developer.vuforia.com/forum/ar-technical-discussion/issues-and-bugs

 

 

No live camera feed on iOS

October 28, 2015 - 5:00am #25

I have tried 5.2.2p1 and 5.1.4 and neither of these are working. I will see if I can roll back even further.

No live camera feed on iOS

October 28, 2015 - 3:06am #24

Hi,

We are also experiencing this issue. Our setup is as follows:

  • Unity 5.2.2 (downloading p1 to test now)
  • Xcode 7.1
  • iPhone 6 Plus - 9.1
  • Vuforia 5.0.6
  • Player settings match your examples

I will let you know if 5.2.2p1 fixes it for us, if not does anyone know what I can roll back to Vuforia or Unity wise to fix this?

No live camera feed on iOS

October 28, 2015 - 2:27am #23

Some testing confirmed that an older build still works with the camera. I have done no changes to any vuforia settings but the project has evolved with an updated imagetracking behaviour and new parts of the program.

Is it possible some new part of the  project change the xcode export in some way? Considering the android version works without flaws. I am also not sure if I use the same version of xcode (I borrow a mac to build to iOs). I'm not sure were to start.

No live camera feed on iOS

October 28, 2015 - 1:56am #22

I am on an ipad 4,1 and my player settings seems fine: 

 

I will try to uppgrade unity I guess

AttachmentSize
Image icon Skärmklipp1.PNG42.48 KB
Image icon Skärmklipp2.PNG134.46 KB
Image icon Skärmklipp3.PNG86.42 KB

No live camera feed on iOS

October 28, 2015 - 1:48am #21

Radix88, are you also testing on iPhone 6 like moreininnovation? or else which device model?

Just in case, if you are working on Xcode 7.1 and iOS 9.1, try upgrading to Unity 5.2.2p1 and see if the issue persists..

also, always worth double-checking your Player settings: 

https://developer.vuforia.com/forum/faq/unity-player-settings

 

No live camera feed on iOS

October 28, 2015 - 1:42am #20

I am also running in to this issue. A build about 2 weeks ago worked but now it doesn't.

I am on Unity 5.2.1, I found the xcode setting "Requires Fullscreen" but it didn't help. I am running the project on ios 9.1

No live camera feed on iOS

October 27, 2015 - 11:40pm #19

In Unity 5.2.2 there is an option called "Requires Fullscreen" in the Player Settings for iOS (under the "Resolution and Presentation" tab); this should be enabled by default;

could you check that setting is ON ?

 

could you also post:

- a screenshot of your Player Settings (iOS) > Resolution and Presentation panel

- a screenshot of your Player Settings (iOS) > Other Settings panel

 

last question: what iPhone 6 model are you using  (iPhone 6, 6S or 6Plus) ?

 

No live camera feed on iOS

October 27, 2015 - 1:42pm #18

I have the same configuration, but tested with iPhone 6 and sample code. Same problem.

My configuration:

- OS X 10.11.1

- Unity 5.2.2p1

- Vuforia Unity 5.0.6

- XCode 7.1

- iOS 9.1

What happened:

- I can see my cube in a small part of screen

- I can't see camera (black screen in background)

For information, same code is working fine under Android.

No live camera feed on iOS

October 25, 2015 - 10:37am #17

Just tried the following:

  • created a new Unity 5.2.2p1 project and imported vuforia-unity-5-0-6.unitypackage
  • deleted the Main Camera
  • added a Vuforia ARCamera to the scene (from Assets/Vuforia/Prefabs)
  • set the License Key (for "Mobile") in the ARCamera inspector
  • added an Image Target (using "Tarmac.xml" dataset from the ImageTargets sample)
  • added a Cube as augmentation child of the Tarmac Target
  • saved the scene and added to the scene list in the Build Settings panel
  • set the Player Settings (Graphics API and IL2CPP backend) for iOS according to this (note: this step is very important): 
  • built and run on Mac 10.10 with Xcode 7.1 on iPhone 5S running iOS 9.1

Works fine over here (can see the video camera feed as well as the augmentation on the target when it is tracked)

 

No live camera feed on iOS

October 24, 2015 - 12:56am #16

2 years later, same problem with Unity 5.2.2, Vuforia 5.0.6, iOS 9.1 and XCode 7.1.

Image tracking: OK

Video rendering: black screen.

No live camera feed on iOS

April 2, 2015 - 1:53pm #15

Try setting the publish to use OpenGL ES 2.0 not the default 3.0

No live camera feed on iOS

December 11, 2014 - 1:05pm #14

That could be the problem, yes; It's recommended to build iOS projects on MacOS directly.

No live camera feed on iOS

December 11, 2014 - 12:07pm #13

Could I be having the same problem as this person? https://developer.vuforia.com/forum/ios/black-screen

I am currently building the iOS project from a PC with Unity and then moving it to a Mac for Xcode deployment. Is that not advised?

It does seem weird that the other features of the app would still be working in this case, though.

No live camera feed on iOS

December 11, 2014 - 9:21am #12

Thanks for the suggestion! I am attempting the solution for Camera Access, specifically for my Unity iOS project. The camera check is being prompted in the app but the camera still does not operate when confirmed.

As an aside, I don't appear to have the line:

QCARUnityPlayer::getInstance().QCARInit([orientation UTF8String]);

... in my UnityAppController::applicationDidBecomeActive(), which in my build appears thus:

(void)applicationDidBecomeActive:(UIApplication*)application
{
    printf_console("-> applicationDidBecomeActive()\n");
 
    if(_unityAppReady)
    {
        if(_didResignActive)
            UnityPause(false);
    }
    else
    {
        [self performSelector:@selector(startUnity:) withObject:application afterDelay:0];
    }
 
    _didResignActive = false;
}
 
I went ahead and added the CameraCheckDone loop in the _unityAppReady block, but I'm wondering if this inconsistency might be telling in any way.

No live camera feed on iOS

December 11, 2014 - 6:33am #11

Have you checked this?

https://developer.vuforia.com/forum/ios/ios-8-xcode-6-and-vuforia-30-compatibility

If your device is running on iOS 8, the issue could just be with the camera access feature introduced with iOS8; please check the notice above.\

 

No live camera feed on iOS

December 10, 2014 - 11:51am #10

I've run into this too. Testing both my own AR app and the Background Texture sample (https://developer.vuforia.com/resources/sample-apps/background-texture-access-sample-app) on an iPhone 5s gives me a black screen. They are working on my PC and our Android test devices. I'm waiting on another iOS device to check with just in case it's the individual device that's the problem, but I wanted to stop in here to avoid wasting too much time. The sample linked above should work as-is on iOS devices, right?

No live camera feed on iOS

November 19, 2014 - 12:34am #9

Hi there. I am also experiencing the same problem. I tried it in ipod touch but the screen appears to be black. no camera feed at all. how do I fix this?

Thanks in advance! :)

No live camera feed on iOS

August 22, 2013 - 5:07am #8

That's great to hear - thanks for sharing!

 

N

No live camera feed on iOS

August 22, 2013 - 5:02am #7

Ok, I had a second camera for GUI elements only. That camera was set to "Depth Only" and only showed elements on my GUI layer. As soon as I switched that one off, the background video showed up again. Guess my scene needs some refactoring :)

Thanks for all the help.

 

Cheers

No live camera feed on iOS

August 21, 2013 - 6:53am #6

Hi,

You may find this thread helpful:

https://developer.vuforia.com/forum/unity-3-extension-technical-discussion/latest-update-breaks-projected-shadows

 

Essentially, we had to change the native video background to render in OnPreCull() instead of Update() in order to support Unity4.2, where rendering outside the main render loop is no longer supported.
 
Consequently certain scripts and techniques that used to work before now may no longer work.
 
The recommendation here is to use the background texture access (see the sample) to render the background directly in Unity, because we have seen a number of complex render setups that tend to work better with this approach and you may find it works better as well.
 
Hope this makes sense.
 
 
N
 

No live camera feed on iOS

August 21, 2013 - 6:39am #5

Ah actually a clue here.  On one of my scenes I use a render texture to show a second camera (it's a dance selector showing an avatar dancing) - THAT camera has the video background, not the AR camera.

 

Note that with WebCamBehaviour the editor is fine, it's only on the device.

No live camera feed on iOS

August 21, 2013 - 6:30am #4

My project which is released and worked fine witn 4.1.5 and 2.0.3 is also showing a black background on both Droid and iOS now I've upgraded to 4.2 and 2.6.7.  I've tried just about everything I can think of so would love an update if you can find out why it isn't working for you.   I will do the same.

No live camera feed on iOS

August 21, 2013 - 5:56am #3

Ok, that's strange - works like a charm :) Must be my fault then. I'll report back, once I find the solution.

Thanks for the hint.

No live camera feed on iOS

August 21, 2013 - 4:10am #2

What happens when you run the Image Targets Sample?

N

Topic locked