Obi Official Forum
Errors building for Android - Printable Version

+- Obi Official Forum (https://obi.virtualmethodstudio.com/forum)
+-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html)
+--- Forum: Obi Rope (https://obi.virtualmethodstudio.com/forum/forum-4.html)
+--- Thread: Errors building for Android (/thread-608.html)



Errors building for Android - danblack - 28-05-2018

I've just purchased and imported AbiRope but I can't get it to build, either the demo scenes or an empty scene with one piece of rope added. I am trying to build for Android using Unity version 2018.1.0f2 on Windows 10.

I get the following errors : 
Shader error in 'Standard (Backfaces)': '_LightCoord' :  no such field in structure at Assets/Obi/Resources/ObiMaterials/UnityStandardCoreBackfaces.cginc(415) (on gles)

Compiling Vertex program with UNITY_PASS_FORWARDADD SPOT
Platform defines: UNITY_NO_DXT5nm UNITY_NO_RGBM UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_NO_CUBEMAP_ARRAY UNITY_NO_SCREENSPACE_SHADOWS UNITY_PBS_USE_BRDF2 SHADER_API_MOBILE UNITY_HARDWARE_TIER2 UNITY_COLORSPACE_GAMMA UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING

Shader error in 'Standard (Backfaces)': '_LightCoord' :  no such field in structure at Assets/Obi/Resources/ObiMaterials/UnityStandardCoreBackfaces.cginc(503) (on gles)

Compiling Vertex program with UNITY_PASS_FORWARDADD SPOT
Platform defines: UNITY_NO_DXT5nm UNITY_NO_RGBM UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_NO_CUBEMAP_ARRAY UNITY_NO_SCREENSPACE_SHADOWS UNITY_PBS_USE_BRDF2 SHADER_API_MOBILE UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING

Shader error in 'Obi/Particles': '' :  non-square matrices not supported (3x1) at Assets/Obi/Resources/ObiMaterials/ObiEllipsoids.cginc(83) (on gles)

Compiling Vertex program with UNITY_PASS_FORWARDBASE DIRECTIONAL
Platform defines: UNITY_NO_DXT5nm UNITY_NO_RGBM UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_NO_CUBEMAP_ARRAY UNITY_NO_SCREENSPACE_SHADOWS UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER SHADER_API_MOBILE UNITY_HARDWARE_TIER1 UNITY_COLORSPACE_GAMMA UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING


RE: Errors building for Android - danblack - 30-05-2018

- bump -


RE: Errors building for Android - danblack - 01-06-2018

anyone?


RE: Errors building for Android - josemendez - 01-06-2018

(01-06-2018, 07:15 AM)danblack Wrote: anyone?

HI,

maybe this thread will be helpful:
http://obi.virtualmethodstudio.com/forum/showthread.php?tid=588

cheers,


RE: Errors building for Android - danblack - 04-06-2018

(01-06-2018, 01:52 PM)josemendez Wrote: HI,

maybe this thread will be helpful:
http://obi.virtualmethodstudio.com/forum/showthread.php?tid=588

cheers,

Hi,

That helps a bit thanks. Changing line 83 & 84 in ObiEllipsoids.cginc fixes the third error, but allows the compiler to get further and find two more in ParticleShader.Shader. These are also caused by UNITY_MATRIX_V and fixed by adding a cast in the same way. 

This doesn't help with the first two errors though, on lines 415 and 503 of UnityStandardCoreBackfaces.cginc. They seem to be caused by 
UNITY_LIGHT_ATTENUATION(atten, i, s.posWorld);
(also line 503 seems to be missing a semi-colon)

Any ideas about what is causing this and how to fix it. It's been a week since I bought this now and I'd really like to get it compiling. 

Cheers,
Dan


RE: Errors building for Android - josemendez - 04-06-2018

(04-06-2018, 10:25 AM)danblack Wrote: Hi,

That helps a bit thanks. Changing line 83 & 84 in ObiEllipsoids.cginc fixes the third error, but allows the compiler to get further and find two more in ParticleShader.Shader. These are also caused by UNITY_MATRIX_V and fixed by adding a cast in the same way. 

This doesn't help with the first two errors though, on lines 415 and 503 of UnityStandardCoreBackfaces.cginc. They seem to be caused by 
UNITY_LIGHT_ATTENUATION(atten, i, s.posWorld);
(also line 503 seems to be missing a semi-colon)

Any ideas about what is causing this and how to fix it. It's been a week since I bought this now and I'd really like to get it compiling. 

Cheers,
Dan

If you're not using the standard backfaces material (if you don't know, you definitely aren't) a quick fix would be to just remove these files:
- StandardBackfaces.shader
- UnityStandardCoreBackfaces.cginc
- UnityStandardCoreForwardBackfaces.cginc
- UnityStandardCoreForwardSimpleBackfaces.cginc

They are all found in Obi/Resources/ObiMaterials. These are failing to compile probably due to differences in 2018's standard shader implementation. We'll make sure to update them in upcoming versions.


RE: Errors building for Android - danblack - 04-06-2018

(04-06-2018, 12:17 PM)josemendez Wrote: If you're not using the standard backfaces material (if you don't know, you definitely aren't) a quick fix would be to just remove these files:
- StandardBackfaces.shader
- UnityStandardCoreBackfaces.cginc
- UnityStandardCoreForwardBackfaces.cginc
- UnityStandardCoreForwardSimpleBackfaces.cginc

They are all found in Obi/Resources/ObiMaterials. These are failing to compile probably due to differences in 2018's standard shader implementation. We'll make sure to update them in upcoming versions.

Removing the files got it compiling. 
Thanks.