x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Shader compilation fails on Tegra 3 (Nexus 7 2012)

I am trying to run a very simple project on an Android device, which is a first generation Nexus 7 (uses Tegra 3). The .apk builds fine, but crashes when trying to run with the following:

 D/UE4     (11530): D:\BuildFarm\buildmachine_++depot+UE4-Releases+4.0\Engine\Source\Runtime\OpenGLDrv\Private\OpenGLShaders.cpp(49): Fatal error:    
 D/UE4     (11530): Failed to compile shader. Compile log:    
 D/UE4     (11530): (34) : error C1101: ambiguous overloaded function reference "max(mediump float, float)"    
 D/UE4     (11530):     (0) : vec4 max(vec4, float)    
 D/UE4     (11530):     (0) : vec3 max(vec3, float)    
 D/UE4     (11530):     (0) : vec2 max(vec2, float)    
 D/UE4     (11530):     (0) : ps gp4 cp50 fp50 vp50 gp50 mediump float max(mediump float, mediump float)    
 D/UE4     (11530):     (0) : float max(float, float)    
 D/UE4     (11530): (35) : error C1101: ambiguous overloaded function reference "max(mediump float, float)"    
 D/UE4     (11530):     (0) : vec4 max(vec4, float)    
 D/UE4     (11530):     (0) : vec3 max(vec3, float)    
 D/UE4     (11530):     (0) : vec2 max(vec2, float)    
 D/UE4     (11530):     (0) : ps gp4 cp50 fp50 vp50 gp50 mediump float max(mediump float, mediump float)    
 D/UE4     (11530):     (0) : float max(float, float)    
 D/UE4     (11530):     
 D/UE4     (11530): [2014.04.12-19.56.09:390][  0]LogRHI:Fatal: Failed to compile shader. Compile log:    
 D/UE4     (11530): (34) : error C1101: ambiguous overloaded function reference "max(mediump float, float)"    
 D/UE4     (11530):     (0) : vec4 max(vec4, float)    
 D/UE4     (11530):     (0) : vec3 max(vec3, float)    
 D/UE4     (11530):     (0) : vec2 max(vec2, float)    
 D/UE4     (11530):     (0) : ps gp4 cp50 fp50 vp50 gp50 mediump float max(mediump float, mediump float)    
 D/UE4     (11530):     (0) : float max(float, float)    
 D/UE4     (11530): (35) : error C1101: ambiguous overloaded function reference "max(mediump float, float)"    
 D/UE4     (11530):     (0) : vec4 max(vec4, float)    
 D/UE4     (11530):     (0) : vec3 max(vec3, float)  
 D/UE4     (11530):     (0) : vec2 max(vec2, float)    
 D/UE4     (11530):     (0) : ps gp4 cp50 fp50 vp50 gp50 mediump float max(mediump float, mediump float)    
 D/UE4     (11530):     (0) : float max(float, float)    
 F/libc    (11530): Fatal signal 6 (SIGABRT) at 0x00002d0a (code=-6), thread 11567 (Rendering 1)

The scene consists of a few static meshes using a very basic shader (no textures) and a static point light.

The strategy game example crashes with the same error, while Tappy Chicken example runs fine.

Product Version: Not Selected
Tags:
more ▼

asked Apr 12 '14 at 09:37 PM in Packaging & Deployment

avatar image

mechkg
17 4 7 11

avatar image mechkg Apr 12 '14 at 11:50 PM

Seems to be an issue with Tegra shader compiler, stumbled upon this in Unity shader code:

 // tegra is confused if we use _LightShadowData.x directly
 // with "ambiguous overloaded function reference max(mediump float, float)"
 
 half lightShadowDataX = _LightShadowData.x;
 return max(dist > (shadowCoord.z/shadowCoord.w), lightShadowDataX);
(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

Hello Mechkg,

Unfortunately The Nexus 7 is not on our current list of supported devices which you can find here: https://docs.unrealengine.com/latest/INT/Platforms/Android/DeviceCompatibility/index.html

-Max B.

more ▼

answered Apr 22 '14 at 03:13 PM

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

If you haven't already, go into your project settings and turn off Mobile HDR. Doing this let's me run most projects on my first generation Nexus 7.

EDIT: Also, build with either ETC1 or DXT

more ▼

answered Apr 23 '14 at 02:05 PM

avatar image

Monophobe
56 3 4 5

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question