cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGFX problem when trying to render 2 images on the same screen

G_Anastasopoulos
Associate II

Dear All,

I am developing an application on the STM32F746 that uses TouchGFX. I am able to load some images from my SD card to the primary cache and I am able to display the images individually on the screen. But when I try to display them together I am struggling. One of the images has unknown size at compile time, since it is loaded from the SD card.

This is what does my screen look like in the TouchGFX designer:

G_Anastasopoulos_0-1712663347084.png

Both DynamicBackground and DynamicIcon_1 use the same configuration:

G_Anastasopoulos_1-1712663406303.png

At times, in my application I need to be able to show one of them or both of them. The location of the image is supposed to be passed by the application.

What I am experiencing is that if I try to draw one image, while the other is already being drawn, I am getting a hardfault at this point:

G_Anastasopoulos_2-1712665063477.png

From what I have seen so far, if I set the alpha of each image less than 255, then I am not experiencing this issue.

But I am trying to understand why does this happen and if there is a fix that does not require to change the alpha of the images.

Thank you in advance



 

1 ACCEPTED SOLUTION

Accepted Solutions

Hello @G_Anastasopoulos ,

The reason you cannot display both images simultaneously without setting the alpha value to less than 255 is that TouchGFX cannot determine how the pixels should be combined when both images are set to be solid (so, you cannot see what is behind them).

Do your image holders DynamicIcon_1 and DynamicBackground collide/cover each other?

Mohammad MORADI
ST Software Developer | TouchGFX

View solution in original post

3 REPLIES 3

Hello @G_Anastasopoulos ,

The reason you cannot display both images simultaneously without setting the alpha value to less than 255 is that TouchGFX cannot determine how the pixels should be combined when both images are set to be solid (so, you cannot see what is behind them).

Do your image holders DynamicIcon_1 and DynamicBackground collide/cover each other?

Mohammad MORADI
ST Software Developer | TouchGFX
G_Anastasopoulos
Associate II

@Mohammad MORADI ESFAHANIASL 

Thank you for your reply. My images were indeed colliding. As a solution to the issue I used texture mappers instead and that did the trick for me.

You're very welcome

Glad to hear you managed to fix it
Good luck

Mohammad MORADI
ST Software Developer | TouchGFX