필터 지우기
필터 지우기

imwrite makes correct file, then errors

조회 수: 2 (최근 30일)
Vladimir
Vladimir 2011년 8월 9일
I'm using imwrite to write a uint8 to bmp in object oriented matlab. The correct image appears in Windows Explorer, but matlab then throws the following error:
Can't open file "rawcode.bmp" for writing. You may not have write permission.
coming from:
imwrite(~obj.DMcells(1:obj.stepQ0,1:obj.stepQ1),'rawcode.bmp','bmp');
When you try to delete the file after this Windows 7 says matlab is holding it up. XP just says a process still has it. It deletes once matlab is closed.
The file we see has read/write privileges and was tried on a mapped network drive as well as locally in C:\. Windows 7 is successful once, but after that - without restarting matlab - will fail.
Additionally, I've been able to use imwrite in previous projects. Any insight into this problem is greatly appreciated.
EDIT: This is using R2011a

답변 (1개)

Friedrich
Friedrich 2011년 8월 10일
  댓글 수: 1
Vladimir
Vladimir 2011년 8월 10일
Thanks for looking too. I was really hoping the latter solution would apply here, but unfortunately it doesn't =/

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

카테고리

Help CenterFile Exchange에서 Convert Image Type에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by