Texture does not wrap on Android ES2

Hello,

We are encountering a problem in UE 4.12 on Android ES2 where textures do not wrap correctly, instead acting as if they’re clamped. This has been tested on two Nexus 6Ps running Android N, a Samsung Galaxy S7 running Android 6.0.1, and a Samsung Galaxy Note 4 running Android 5.1.1. The Samsung devices are the Snapdragon equipped American versions.

This only occurs on the actual devices, appearing normally when previewed with the Android ES2 rendering level in the editor. This seems to happen regardless of texture dimensions, compression settings, mipmap settings, or power of two mode. When run with ES3.1, the problem does not occur.

On Windows, the 64x64 texture tiles just fine, even when set to the ES2 preview level.

On Android ES2, the same texture behaves as though it is clamped, even though wrapping is selected in the texture settings.

Assuming this isn’t intended behavior, is there any way to work around this? Using ES3.1 isn’t an option for us right now, unfortunately.

What are the UV ranges? This could be a too high a repeat rate (6 bits of precision used just for integer if x64). And make sure you don’t go too far from the origin (0,0) as this will also lower the bits for fraction. Try turning on “Use Full Precision” in the Mobile section on the material and see if it helps.

Upon closer inspection, this problem only seems to happen when the Google VR plugin is enabled. With it enabled, the problem even arises in things like the official Sun Temple and Strategy Game demos.
To answer your questions, though, the model in the images is the standard template floor, which seems to have UVs between (0,1) and (10, -9). The model is centered around the origin, so I don’t think that it would be getting into precision problems, even with half precision.
I cannot seem to find an option to enable full precision in the Mobile settings (just “Fully Rough”, “Use Lightmap Directionality”, “High Quality Reflections”, and “Planar Reflections”). Is there somewhere else I should be looking?
The problem seems to occur whenever a texture is sampled outside of the zero to one range. Maybe the Google VR plugin is overriding the tiling settings for textures or something similar?

Sorry, the Full Precision is a new setting for 4.13. You can find it in github master if you want to try it, but the extra information about Google VR plugin seems more likely.

It probably has to do with their library setting texture addressing separate from our state caching in GoogleVRHMDRender.cpp.

Is this something we should look into fixing ourselves? We can try and come up with a workaround, but if there’s a fix in the works already by the plugin developers, we might just wait until that’s available and devote manpower elsewhere for now.

It turns out this is a known bug and is fixed in an update to the SDK. It should be added to Dev-VR this week.

Hey Chris,

We took a look at the latest GoogleVR integration from HSL, CL #3033004, and this problem appears to persist in ‘Daydream-only’ builds (but does not occur in ‘Cardboard + Daydream’ builds). Our target is ‘Daydream-only’, as that is all that appears to support the Daydream controller.

This CL looks to be more about iOS support; I don’t see an update to the SDK itself for Android.