Log in or register to post comments

EXC_BAD_ACCESS with Unity

October 29, 2014 - 4:52am #1

Hi,

i made a cutom app with unity and build it to xCode. When i start the app and show the tracing object to the camera, app freezes and xCode shows an error in DisplayManager.mm;


	if(surface.context != nil)
	{
		PreparePresentRenderingSurface(&surface, [[DisplayManager Instance] mainDisplay]->surface.context);

		EAGLContextSetCurrentAutoRestore autorestore(surface.context);
		GLES_CHK(glBindRenderbuffer(GL_RENDERBUFFER, surface.systemColorRB));
		[surface.context presentRenderbuffer:GL_RENDERBUFFER]; //Thread 1:EXC_BAD ACCESS(code=1, adress=0x1)

		if(needRecreateSurface)
		{
			RenderingSurfaceParams params =
			{
				surface.msaaSamples, (int)requestedRenderingSize.width, (int)requestedRenderingSize.height,
				surface.use32bitColor, surface.use24bitDepth, surface.cvTextureCache != 0
			};
			[self recreateSurface:params];

			needRecreateSurface = NO;
			requestedRenderingSize = CGSizeMake(surface.targetW, surface.targetH);
		}
	}

I searched for a solution on this forum and some other sites but didn't get one yet...(i think this link doesn't work anymore https://developer.vuforia.com/forum/unity-3-extension-technical-discussion/unity-454-and-vuforia-ios)

EXC_BAD_ACCESS with Unity

October 31, 2014 - 8:17am #6

Is there anybody to help me with this issue friends, please? I got stuck in that...

EXC_BAD_ACCESS with Unity

October 30, 2014 - 10:15am #5

yeah, now i'm trying with the videoplayback unity package and everything works fine but in my app the error still occurs. That's the last thing the log says;

-> applicationDidBecomeActive()

Trackable yemek found

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

 

i did it as the vuforia example, everything seems the same but something must be different and i can't figured it out.

 

I'm sorry if i can't describe the exact situation, actually i'm not an ios developer but in my country, one man should do everything :)

 

full log recordings;

 

2014-10-30 19:13:07.452 BursaKulturAR[227:13751] -> registered mono modules 0xee1760

-> applicationDidFinishLaunching()

QCAR Extension version 3.0.0

2014-10-30 19:13:07.667 BursaKulturAR[227:13751] INFO/AR(227) 2014-10-30 19:13:07: QCAR SDK version 3.0.9

Mono path[0] = '/private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed'

Mono config path = '/private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed'

Renderer: Apple A7 GPU

Vendor:   Apple Inc.

Version:  OpenGL ES 2.0 Apple A7 GPU - 50.5.1

GL_OES_depth_texture GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_texture_float GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_vertex_array_object GL_EXT_blend_minmax GL_EXT_color_buffer_half_float GL_EXT_debug_label GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_draw_instanced GL_EXT_instanced_arrays GL_EXT_map_buffer_range GL_EXT_occlusion_query_boolean GL_EXT_pvrtc_sRGB GL_EXT_read_format_bgra GL_EXT_separate_shader_objects GL_EXT_shader_framebuffer_fetch GL_EXT_shader_texture_lod GL_EXT_shadow_samplers GL_EXT_sRGB GL_EXT_texture_filter_anisotropic GL_EXT_texture_rg GL_EXT_texture_storage GL_APPLE_clip_distance GL_APPLE_color_buffer_packed_float GL_APPLE_copy_texture_levels GL_APPLE_framebuffer_multisample GL_APPLE_rgb_422 GL_APPLE_sync GL_APPLE_texture_format_BGRA8888 GL_APPLE_texture_max_level GL_APPLE_texture_packed_float GL_IMG_read_format GL_IMG_texture_comp

ression_pvrtc 

Creating OpenGLES2.0 graphics device

Initialize engine version: 4.3.0f4 (e01000627d60)

Begin MonoManager ReloadAssembly

Platform assembly: /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/UnityEngine.dll (this message is harmless)

Loading /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/UnityEngine.dll into Unity Child Domain

Platform assembly: /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/Assembly-CSharp.dll (this message is harmless)

Loading /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/Assembly-CSharp.dll into Unity Child Domain

Platform assembly: /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/Qualcomm.Vuforia.UnityExtensions.dll (this message is harmless)

Platform assembly: /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/System.dll (this message is harmless)

Platform assembly: /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/System.Core.dll (this message is harmless)

Platform assembly: /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/Qualcomm.Vuforia.UnityExtensions.dll (this message is harmless)

Loading /private/var/mobile/Containers/Bundle/Application/BD30FBD9-378E-4ED2-A239-AF4AFD310713/BursaKulturAR.app/Data/Managed/Qualcomm.Vuforia.UnityExtensions.dll into Unity Child Domain

- Completed reload, in  0.025 seconds

Can't add component because class 'PremiumObjectFactoryStarterBehaviour' doesn't exist!

 

(Filename:  Line: 38)

 

Can't add component because class 'PremiumComponentFactoryStarterBehaviour' doesn't exist!

 

(Filename:  Line: 38)

 

Trackable 3 lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable 3 lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable keskek lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable keskek lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable oyunlar lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable oyunlar lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

QCARWrapper.Start

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

trackerManagerInitTracker

trackerManagerInitTracker

SetHint

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Setting Unity version 4.3.0

dataSetExists

imageTrackerCreateDataSet

2014-10-30 19:13:08.477 BursaKulturAR[227:13751] INFO/AR(227) 2014-10-30 19:13:08: ImageTracker: Successfully created dataset

Successfully created data set.

dataSetLoad

dataSetGetNumTrackableType

dataSetGetTrackablesOfType

dataSetGetTrackableName

imageTargetGetSize

imageTargetGetNumVirtualButtons

dataSetGetTrackableName

imageTargetGetSize

imageTargetGetNumVirtualButtons

dataSetGetTrackableName

imageTargetGetSize

imageTargetGetNumVirtualButtons

dataSetGetTrackableName

imageTargetGetSize

imageTargetGetNumVirtualButtons

dataSetGetTrackableName

imageTargetGetSize

imageTargetGetNumVirtualButtons

dataSetGetNumTrackableType

dataSetGetNumTrackableType

dataSetGetNumTrackableType

imageTargetSetSize

Found Trackable named 3 with id 4

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

imageTargetSetSize

Found Trackable named keskek with id 5

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

imageTargetSetSize

Found Trackable named oyunlar with id 1

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

imageTargetSetSize

Found Trackable named yemek with id 3

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

imageTargetSetSize

Found Trackable named 2 with id 2

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

imageTrackerActivateDataSet

StartQCAR

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

cameraDeviceInitCamera

2014-10-30 19:13:08.580 BursaKulturAR[227:13751] *** -[AVCaptureVideoDataOutput setVideoSettings:] - videoSettings dictionary contains one or more unsupported (ignored) keys: (

    Height,

    Width

)

2014-10-30 19:13:08.583 BursaKulturAR[227:13751] DEBUG/AR(227) Could not find a UIView with CAEAGLLayer layer class that responds to selector renderFrameQCAR

cameraDeviceGetVideoMode

2014-10-30 19:13:08.587 BursaKulturAR[227:13751] DEBUG/AR(227) Could not find a UIView with CAEAGLLayer layer class that responds to selector renderFrameQCAR

cameraDeviceSelectVideoMode

2014-10-30 19:13:08.589 BursaKulturAR[227:13751] DEBUG/AR(227) Could not find a UIView with CAEAGLLayer layer class that responds to selector renderFrameQCAR

cameraDeviceStartCamera

markerTrackerStart

imageTrackerStart

Trackable yemek lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable yemek lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable 2 lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable 2 lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

cameraDeviceGetVideoMode

2014-10-30 19:13:08.737 BursaKulturAR[227:13751] DEBUG/AR(227) Could not find a UIView with CAEAGLLayer layer class that responds to selector renderFrameQCAR

Trackable 3 lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable keskek lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable oyunlar lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable yemek lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

Trackable 2 lost

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

cameraDeviceGetVideoMode

Setting camera clear flags to depth only

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

-> applicationDidBecomeActive()

Trackable yemek found

 

(Filename: /Applications/buildAgent/work/d3d49558e4d408f4/artifacts/iPhonePlayer-armv7Generated/UnityEngineDebug.cpp Line: 53)

 

(lldb)

EXC_BAD_ACCESS with Unity

October 29, 2014 - 5:31pm #4

The EXC_BAD_ACCESS is just a general error message. There are usually more specific errors in the Xcode log. Are you able to reproduce the error in one of our sample apps?

EXC_BAD_ACCESS with Unity

October 29, 2014 - 5:07pm #3

Unfortunately the error still occurs. my Info.plist already got that line;

Supported interface orientations

    -Item0 Portrait(bottom home button)

and

Initial interface orientation  Portrait(bottom home button)

i selected "portrait" also in Unity. i don't think that this issue is about orientations but i can't find what the real problem is... and i have to make a presentation to my boss after in a couple of days with our ar application. so i have to make it work...

EXC_BAD_ACCESS with Unity

October 29, 2014 - 11:10am #2
Log in or register to post comments