Skip to main content
MG.7
Associate
November 12, 2021
Solved

Question on video widget in TouchGFX new version(4.18.0)

  • November 12, 2021
  • 3 replies
  • 1337 views

Hi,

whenever we are using videos for video widget to upload it was not taken .only it gave output for what they were gave to us as a example video.

Any solution please how we can access our videos (that to is in avi format) for video widget in touchgfx 4.18.0 version.

This topic has been closed for replies.
Best answer by mƎALLEm

Hello,

Sorry but you didn't provide details of your issue!

OK. I'm putting an example and please try it:

1- Download this free mp4 video from this link:

https://www.videezy.com/abstract/44249-particle-strings-background-video

2- Convert the video in MJPEG format:

2-1 Rename the video "01__2822_29.mp4" to "test.mp4"

2-2 Apply this command to the downloaded video: 

ffmpeg -i test.mp4 -s 480x272 -vcodec mjpeg -qscale 1 -an output.avi

3- Put the generated video "output.avi" in the path: <YourProject>\TouchGFX\assets\videos

4- From TouchGFX designer please select output.avi as the video to play and try to run the simulator to visualize the video.

5- If all is OK. You can run the example on the target.

Note: these steps were tested with STM32F769-DISCO board.

3 replies

mƎALLEm
Technical Moderator
November 16, 2021

Hello,

Based on TouchGFX documentation, the video should be in MJPEG avi format.

You can use ffmpeg tool to generate this format.

For example to convert the video file input.mov to MJPEG use this command:

ffmpeg -i input.mov -s 480x272 -vcodec mjpeg -qscale 1 -an output.avi

For more details, refer to TouchGFX documentation (video section) from this link.

PS: If this comment answers your question, please mark this topic as answered by selecting Select as best. This will help other users find that answer faster.

And of course you have to put your videos under the path: \TouchGFX\assets\videos

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.
MG.7
MG.7Author
Associate
November 26, 2021

Hello,

Thanks for Reply. Tried this procedure also. Still same issue. Is there any particular frame rate to be used?

mƎALLEm
mƎALLEmBest answer
Technical Moderator
November 26, 2021

Hello,

Sorry but you didn't provide details of your issue!

OK. I'm putting an example and please try it:

1- Download this free mp4 video from this link:

https://www.videezy.com/abstract/44249-particle-strings-background-video

2- Convert the video in MJPEG format:

2-1 Rename the video "01__2822_29.mp4" to "test.mp4"

2-2 Apply this command to the downloaded video: 

ffmpeg -i test.mp4 -s 480x272 -vcodec mjpeg -qscale 1 -an output.avi

3- Put the generated video "output.avi" in the path: <YourProject>\TouchGFX\assets\videos

4- From TouchGFX designer please select output.avi as the video to play and try to run the simulator to visualize the video.

5- If all is OK. You can run the example on the target.

Note: these steps were tested with STM32F769-DISCO board.

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.