2025-01-07 03:59 AM
Hi,
By default, when you open a touchgfx project in the designer, images, texts and fonts come from the asset/ folder.
How can I change that? I'd like to use another folder by default. I haven't found in the config files where this option is.
Thanks in advance.
2025-01-07 04:58 AM
Hello @GMeur ,
I am afraid this is not an option.
TouchGFX stores all the required assets in the asset folder and converts them before compiling and flashing.
It would probably be easier to copy the assets from your other folder to the asset folder to be able to use them in your TouchGFX project.
Regards,
2025-01-07 06:17 AM
How sad…
The thing is I'm doing something a bit unconventional as I'm trying to have two different .touchgfx files with two different resolutions inside a same touchgfx folder as a client wants to use a screen with a different resolution for the exact same project (and we need to maintain both resolutions).
My idea was to use a different asset folders and a different touchgfx project for each configuration, both of them generating files in the same 'generated' folder. Doing so, I can keep using a single VS and IAR projects. I've already managed to generate imgs/texts/fonts from one folder or the other depending on which touchgfx project I use. Pb is, if I change an image (basically changing its size, as both resolutions will use exactly the same images, with the same names, with the exception that the size of most of them will change) in my 'assets-bis' folder, the 'my-application-bis' project doesn't realise it's changed and keeps showing its equivalent in the 'asset' folder. Therefore, hitting the 'generate' button doesn't do anything as it thinks the project is already 'up to date'. I can manage to make it work changing the config of a photo (not ideal but well, it works at least). 'Rebuilding' in VS also works as I import another '.target' file using the 'assets-bis/' folder in case I'm working with a VS config 'my_application-bis'.
However, I'd have really liked to visualize the images actually used in 'my-application-bis' project as it's a bit confusing to see the image from the 'asset' folder yet generate the one from the 'asset-bis' folder.
If you have another idea of how to work with two resolutions on a same project, I'm more than keen to hear it… Creating a whole different project just to manage a different screen resolution seemed an extremely bad idea to me tbh.
Thanks,
Guillaume.