How can I convert 'file.fig' to to jpg?
243 次查看(过去 30 天)
显示 更早的评论
I have 'file.fig' that consists from 50 figures. I would like to convert them to jpeg. How can I do that?
Thanks
Riyadh
3 个评论
Miguel Rodriguez Talaveron
2019-10-14
Hi the question is: the moment you have a file.fig and you want to convert it
采纳的回答
Walter Roberson
2016-5-2
figs = openfig('TheFigFile.fig');
for K = 1 : length(figs)
filename = 'figure_%02d.jpg';
saveas(figs(K), filename);
end
5 个评论
Walter Roberson
2016-12-20
If they need to appear together in the same image, then save them as png or tif, read the png (or tif) and combine the images in an appropriate way, such as horzcat or vertcat or perhaps imagepatch. Then save that result into an appropriate file format.
Use png or tiff as the intermediate format so that you do not end up losing information twice from the JPEG lossy compression.
更多回答(4 个)
Bahamut Zero
2017-8-10
编辑:Bahamut Zero
2017-8-10
You can download a tool for converting a folder of .fig to .jpeg en masse here. Just make sure you have the correct MATLAB Runtime Compiler (license not required).
0 个评论
MATCHA SIVA KUMAR
2023-1-28
figs = openfig('TheFigFile.fig');
for K = 1 : length(figs)
filename = 'figure_%02d.jpg';
saveas(figs(K), filename);
end
1 个评论
Walter Roberson
2023-1-28
I posted that more than 6 years ago, and it had a mistake that was corrected later.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 FPGA, ASIC, and SoC Development 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!