rsubtil/controller_icons

Optimize texture access on export

Opened this issue · 3 comments

Currently, the addon fetches separate image files for all button prompts. While this makes it easier for users to modify, it is inefficient, since the most popular solution is to have only one large image atlas.

It might be possible, however, to optimize this step on exported projects. The idea is to build the texture atlas and then fetch from there, instead of the individual image files (and don't even pack them on export).

You could also try using Resources to specify images (or file paths) for each controller. That way, images can be shared between multiple controllers.

You could also try using Resources to specify images (or file paths) for each controller. That way, images can be shared between multiple controllers.

The addon already caches texture assets, so in practice textures are already shared. This solution wouldn't help much because the issue is that there's many small textures in VRAM, which is less efficient than having one big texture atlas.

That's a good point. However, in order to make icons for multiple controllers, you need to duplicate assets and place them in their corresponding folder, which is wasteful of both developer time and storage space.

For example, left stick click does not need a separate image for each controller.