cancel
Showing results for 
Search instead for 
Did you mean: 

I used pixel datawidget to display video from camera through the DCMI but i only get 1 frame on the screen like in snapshot mode not video. i think i must i must the pixel widget to refresh for every frame but i dont know where to do it.

MSale
Associate III
 
10 REPLIES 10
HP
Senior III

Sounds like you need to call invalidate() on your widget.

This is done in the view on the screen that has the widget. when you have defined a function that can invalidate the view, your presenter can call that function.

lastly the model will have to call the presenter.

your model have the function called tick() which is called each time a frame is finished rendering. this way you can easily control if you want to wait a couple of frames before refreshing the screen.

MSale
Associate III

@HP​ 

Thank you. another thing how to put GUI widgets above the pixel widget. till now all other GUI widgets are beneath the pixel data widget.

That is most likely because you have added the pixel widget last in the designer.

In the designer, select the screen in the top left corner. open the drop-down box and see all the elements in your design there. you can re-arrange the order by dragging the items up or down. this also changes the layering of your items

MSale
Associate III

@HP​ 

I tried this before but its not visible there and i think thats because you can not add pixel Data Widget from the designer directly

MSale
Associate III

@HP​ 

Thanks for your help i found way to solve it.

Best Regards

Mahmoud

HP
Senior III

@Community member​ - that sounds great!

Can you tell me what you did to make it work?

MSale
Associate III

@HP​ 

I just changed the order in the generated GUI/src/screen1viewbase.cpp. but i am not sure if this is the right solution. maybe there is another better way.

HP
Senior III

Sounds like a fine solution if you don't have the option to rearrange the orders inside the TouchGFX.

I'm not familiar with the pixel widget you're referring to so it might not pop up.

@Martin KJELDSEN​ might be able to tell you if the widget is accessible through the designer.

Hi,

There's no PixelData widget accessible from the designer - It's kind of the first attempts at loading data from somewhere other than flash so it's becoming legacy and won't see support from the designer.

What you can use instead is an image which can then be configured as a dynamic image to load its data from somewhere in memory that you specify.

/Martin