Log in or register to post comments

Work with Unity 4 Beta?

August 26, 2012 - 11:03pm #1

I was able to get vuforia running with the Unity 4 beta by commenting out two lines in the Xcode project:

This line:

QCARUnityPlayer::getInstance().QCARNotifyCreated((int)surface->w, (int)surface->h);

generated the error: AppController.mm:781:52: Use of undeclared identifier '_curOrientation'; did you mean 'orientation'?

QCARUnityPlayer::getInstance().QCARSetOrientation(_curOrientation);

generated the error: AppController.mm:781:52: Cannot initialize a parameter of type 'int' with an lvalue of type 'NSString *'

The app ran, recognized the target but the display was kind of messed up. Seems like it almost works as is though, any ideas on how to fix the above errors? Or, are you planning any new releases for Unity 4?

Bryan

 

Good to hear. Do you mean

December 21, 2012 - 2:52am #8

Good to hear.

Do you mean with the new 2.0 SDK?

N

Nice 1.. it works nowThanks

December 20, 2012 - 8:25pm #7

 

shinichi88 wrote:

The current solution I found are:

1. Change ((int)surface->w, (int)surface->h) to ((int)surface->targetW, (int)surface->targetH)

2. Change (_curOrientation) to ((int)orientation)

 

Try it out if it work on your side.

Thanks.

 

Nice 1.. it works now

Thanks :)

Work with Unity 4 Beta?

November 21, 2012 - 4:07am #6

Is that camera issue a problem with a portrait app? I have flipped camera issues in Landscape but fixed it by adding the code below to line 219, inside the - (void)willRotateToInterfaceOrientation:duration: method in iPhone_View.mm:

QCARUnityPlayer::getInstance().QCARSetOrientation(toInterfaceOrientation);

Work with Unity 4 Beta?

October 11, 2012 - 2:14am #5

Hi,

I'm using the Unity 4 Beta in a project, too. Did anyone notice a displaced camera image when deploying as iOs App on an iPad 2?

On my iPad3 everything works like a charm (with the mentioned changes), but on the iPad 2 the camera picture is basically moved 1-2 inch to the top left leaving border-zones on the oppisite sides which produce graphical artefacts.

Not sure if this is a vuforia or a unity problem or if the mentioned changes are not working on an iPad 2. 

edit: After upgrading my iPad 3 to iOS 6 the same problem occurs. So it's probably some problem with iOS6 :( The model produced by unity is correctly displayed; only the camera image is displaced.

edit2 :)

I found the threads about broken orientations in iOs6 however the fixes mentioned in those threads are for Unity 3.x only. As I have basically no clue how to program for iOs I need help - Did anyone already manage to fix the rotation issues in Unity 4 for iOS 6?

- Kai

Work with Unity 4 Beta?

August 30, 2012 - 10:14am #4

Great! This works and I can report that the Vuforia plug-in works with Unity beta 4. I am using about 20 animated figures and I can say that the performance of the Mechamin figures is much faster with the new beta, so it's worth it for me to use the beta for my next project. Thanks for helping out so quickly!

Bryan

Work with Unity 4 Beta?

August 30, 2012 - 1:07am #3

The current solution I found are:

1. Change ((int)surface->w, (int)surface->h) to ((int)surface->targetW, (int)surface->targetH)

2. Change (_curOrientation) to ((int)orientation)

 

Try it out if it work on your side.

Thanks.

Work with Unity 4 Beta?

August 28, 2012 - 7:59am #2

Hi Bryan

Thanks for this.

We are investigating this issue and will revert back when there is some news here.

 

N

Log in or register to post comments