PBR material error on Android

Problems building or running the engine, queries about how to use features etc.
Post Reply
Slicky
Bronze Sponsor
Bronze Sponsor
Posts: 614
Joined: Mon Apr 14, 2003 11:48 pm
Location: Was LA now France
x 25

PBR material error on Android

Post by Slicky »

Ogre Version: :1.12 latest:
Operating System: :Windows 10 building for Android:
Render System: :GLES 2:

I am getting this error which prevents my Android app from starting. I will go and study the Ogre android app too.

Code: Select all

'pbr-frag.glsl' 0:9: P0003: Warning: Extension 'GL_EXT_shader_texture_lod' not supported
The debug breakpoint is here in OgreException:

Code: Select all

case Exception::ERR_RENDERINGAPI_ERROR:     throw RenderingAPIException(number, desc, src, file, line);
Is this a limitation of my device (I don't think so) or something else that I need to do?

Update:
It is hard to debug arm7 in VS. I am not getting string values in the debugger so I have to guess some of the time as to what filename or other issue it actually is. Has anyone else got debug values to show for strings?

Anyway, bizarrely the problem seems to be not finding a texture file in a pbr material. The texture is in the same folder as the material. I changed to a different mesh with a simpler material file and it got past that one error. Not sure yet how to fix it.
User avatar
sercero
Bronze Sponsor
Bronze Sponsor
Posts: 449
Joined: Sun Jan 18, 2015 4:20 pm
Location: Buenos Aires, Argentina
x 156

Re: PBR material error on Android

Post by sercero »

Do you have a way to check the ogre.log?

Because it should say if GL_EXT_shader_texture_lod is supported.
Slicky
Bronze Sponsor
Bronze Sponsor
Posts: 614
Joined: Mon Apr 14, 2003 11:48 pm
Location: Was LA now France
x 25

Re: PBR material error on Android

Post by Slicky »

Yes I have a logcat window in VS. I will check.

Update:
Ok I had a chance to check and I see this in the log.

Code: Select all

Parsing script glTF2_PBR.material
'pbr-frag.glsl' 0:9: P0003: Warning: Extension 'GL_EXT_shader_texture_lod' not supported
I have 2 devices that I am debugging on I will check if it is the same error on the other.

I am currently:
(1) Trying to work out a build for ARM64 since I do get warnings that ARM7 might not debug well (to try and get strings to show in debugger)
(2) I need to look if the above warning is because I didn't build or include a feature of Ogre. I didn't specifically exclude GL_EXT
(3) Seeing if this is all related to the fact that a pbr script seems to not find the image file referenced in the material.

Quite a wormhole I've got here.

Update:
On my other devise I don't get the warning:

Code: Select all

Parsing script glTF2_PBR.material
but the same problem that seems to be not finding a file (image I think even) though in the same folder as the PBR material script.

Code: Select all

case Exception::ERR_FILE_NOT_FOUND:         throw FileNotFoundException(number, desc, src, file, line);
paroj
OGRE Team Member
OGRE Team Member
Posts: 1994
Joined: Sun Mar 30, 2014 2:51 pm
x 1074
Contact:

Re: PBR material error on Android

Post by paroj »

please post the whole log.
Slicky
Bronze Sponsor
Bronze Sponsor
Posts: 614
Joined: Mon Apr 14, 2003 11:48 pm
Location: Was LA now France
x 25

Re: PBR material error on Android

Post by Slicky »

Well I made some progress. I went away and rebuilt all the libraries not using Cmake. I think it helped because the app launched. I couldn't work out with Cmake how to build the specific architecture files for Android. Maybe redo Cmake x numner of times but I don't know where the define would go in the Cmake config screen.

I still have a problem that I can't see debug visualisation of strings in VS. That is not an Ogre problem but it is weird and makes debugging hard.

Anyway let's mark this one closed.
paroj
OGRE Team Member
OGRE Team Member
Posts: 1994
Joined: Sun Mar 30, 2014 2:51 pm
x 1074
Contact:

Re: PBR material error on Android

Post by paroj »

Slicky wrote: Mon Aug 09, 2021 4:06 pm Maybe redo Cmake x numner of times but I don't know where the define would go in the Cmake config screen.
you have to pass that on the command line instead. See:
https://github.com/OGRECave/ogre/blob/b ... .cmake#L74
Slicky
Bronze Sponsor
Bronze Sponsor
Posts: 614
Joined: Mon Apr 14, 2003 11:48 pm
Location: Was LA now France
x 25

Re: PBR material error on Android

Post by Slicky »

Ah ok thanks I will give that a spin next time. I don't see the other armabi's other than -DANDROID_ABI=arm64-v8a.
Post Reply