Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Material / MaterialInstance getName is unset in release mode #7793

Open
hannojg opened this issue Apr 24, 2024 · 0 comments
Open

Material / MaterialInstance getName is unset in release mode #7793

hannojg opened this issue Apr 24, 2024 · 0 comments
Assignees

Comments

@hannojg
Copy link
Contributor

hannojg commented Apr 24, 2024

⚠️ Issues not using this template will be systematically closed.

Describe the bug

Using material.getName() or materialInstance.getName() always gives an empty value on filament release build, while on debug it returns the name.
I assume it's this line probably being completely optimised away in release mode:

UTILS_UNUSED_IN_RELEASE bool const nameOk = parser->getName(&mName);

To Reproduce
Steps to reproduce the behavior:

  1. Call getName() in debug and release and compare the output

Expected behavior

It should also return the name in release mode. We need the material name to select the right one from a complex model where guessing the index isn't really feasible.

Screenshots
n/a

Logs
n/a

Desktop (please complete the following information):

  • OS: Android
  • GPU: Mali-G78 MP14
  • Backend: OpenGL

Smartphone (please complete the following information):

  • Device: sm-g991b/ds aka. Samsung Galaxy S21 5G
  • OS: Android 14

Additional context
n/a

@pixelflinger pixelflinger self-assigned this Apr 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants