How do I save Simlulink model to JPG or any other image formats?

조회 수: 72 (최근 30일)
Aniket
Aniket 2013년 2월 27일
댓글: Bharath 2024년 8월 30일
How do I save Simlulink model to JPG or any other image formats?

채택된 답변

Azzi Abdelmalek
Azzi Abdelmalek 2013년 2월 27일
편집: Azzi Abdelmalek 2013년 2월 27일
Manually,
  1. Open your model
  2. click on edit
  3. copy model to clipboard
  4. in paint past your image
  댓글 수: 3
Trig
Trig 2019년 4월 9일
or just straight to jpg:
print(['-s',ModelName],'-djpeg',[ModelName,'.jpg'])

댓글을 달려면 로그인하십시오.

추가 답변 (3개)

Harish Balaga
Harish Balaga 2013년 7월 3일
편집: Harish Balaga 2013년 7월 3일
as Azzi Abdelmalek said above, print command can be used. And one can directly save it in required fomat in single command. (no need to use imead, imwite commands). Example: use
ModelName % to open the model
print('-sModelName','-dtiff','model.tiff')
to save ModelName.mdl in TIFF format. Image name will be model.tiff
replace -dtiff with -djpeg for saving the model in jpeg format
  댓글 수: 3
Jérôme
Jérôme 2023년 2월 13일
You can select the resolution with the resolution parameter:
print('-sModelName', '-dpng', 'model.png', 'r0') % Screen resolution, same as without parameter
print('-sModelName', '-dpng', 'model.png', 'r300') % Resolution of 300 dots per inch
Instead of 300, you can put what you want.
Bharath
Bharath 2024년 8월 30일
Correction in the code add a -before the resolution '-r300'

댓글을 달려면 로그인하십시오.


fathi jamila
fathi jamila 2020년 4월 19일
How can i read image SLC by matlab ?

Anil Chowdary Tummala
Anil Chowdary Tummala 2021년 2월 5일
You may use this to save simulink model as image with extension .tiff
print('-sModelName','-dtiff','model.tiff')

카테고리

Help CenterFile Exchange에서 Modeling에 대해 자세히 알아보기

태그

제품

Community Treasure Hunt

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

Start Hunting!

Translated by