Hello, I am a total beginner on Matlab, and i am searching to convert an entire folder of .bmp images in a video file, with a specific rate of frame/second (like 25, 50 or 100 fps). I did see some explanations on the website, but did not succeed. Could someone give me some help, in order to create the simplest script ?
many thanks by advance.
Chris

 Respuesta aceptada

Image Analyst
Image Analyst el 27 de Mayo de 2016

0 votos

Attached is an application I made to make a movie out of a folder of images. It's not fully done yet but it works. I think the only thing I have to do is to add the option to sort the filenames by time/date stamp instead of alphanumerically based on the filename (which is what it does now). But it's enough to get you started.

1 comentario

matforpsychology
matforpsychology el 30 de Mayo de 2016
Many thanks for your help. I will try it.
thanks again, Best, Chris

Iniciar sesión para comentar.

Más respuestas (1)

Image Analyst
Image Analyst el 24 de Mayo de 2016
Editada: Image Analyst el 24 de Mayo de 2016

0 votos

Does the FAQ work or not work for you?
Set the framerate property to what you want.
writerObj.FrameRate = 25;

6 comentarios

matforpsychology
matforpsychology el 24 de Mayo de 2016
Hello, many thanks for your help. Actually, i just try the % Make an avi movie from a collection of PNG images in a folder. I copy/pasted the code, changed the directory and replaced '*.PNG' by '*.BMP'. My image folder is made of BMP incremented like 7567.bmp, 7568.bmp... When i run the script i get this error message : Undefined function or variable 'this image'.
Thanks a lot for your help. best, Chris
Image Analyst
Image Analyst el 24 de Mayo de 2016
The FAQ has an error, which I've just corrected. Use thisImage instead of imageArray:
thisimage = imread(fullFileName);
matforpsychology
matforpsychology el 24 de Mayo de 2016
Thank for your response; i just tried copying/pasted but got : Error using VideoWriter/writeVideo (line 338) OBJ must be open before writing video. Call open(obj) before calling writeVideo. Did i mistake ? you said you corrected the FAQ; does i have to replace imageArray by thisimage = imread(fullFileName); Many thanks by advance, best, Chris
matforpsychology
matforpsychology el 25 de Mayo de 2016
Hello, I am sorry, but i did not succeed with the modification, i got the following : Error using VideoWriter/writeVideo (line 338) OBJ must be open before writing video. Call open(obj) before calling writeVideo. Did i mistake ?
Many thanks for your help.
best, Chris
Image Analyst
Image Analyst el 25 de Mayo de 2016
I'll fix it later tonight hopefully.
matforpsychology
matforpsychology el 25 de Mayo de 2016
Many thanks. Best, Chris.

Iniciar sesión para comentar.

Categorías

Más información sobre Convert Image Type en Centro de ayuda y File Exchange.

Preguntada:

el 24 de Mayo de 2016

Comentada:

el 30 de Mayo de 2016

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by