Info

この質問は閉じられています。 編集または回答するには再度開いてください。

about the code question

1 回表示 (過去 30 日間)
Pan
Pan 2012 年 8 月 12 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
I have one question about my coed ,if someone could know how to amend my coed,please teach me.
This is my part code
function replay1_callback(hObject0,eventdata0)
set(hreplay1 ,'backgroundColor',[1,1,0],'string','重播中');
for im=idxip(a):idxip(a+1)
subplot(1,1,1);
imshow(uint8(xi(:,:,:,im)));
%pause(1);
% im
drawnow;
% if stopfor==100;
% break;
% im
% end
% for is=im:idxip(a+1)
%
% subplot(1,1,1);
% imshow(uint8(xi(:,:,:,is)));
% %pause(1);
%
% drawnow;
% end
end
I hope my code that could stop and continue play ,
in the code ,I used the "if ...break, it can't stop, and not continue play.
  1 件のコメント
per isakson
per isakson 2012 年 8 月 12 日
Please, markup the text!

回答 (1 件)

Azzi Abdelmalek
Azzi Abdelmalek 2012 年 8 月 12 日
there is an "end" missing
  1 件のコメント
Image Analyst
Image Analyst 2012 年 8 月 12 日
編集済み: Image Analyst 2012 年 8 月 12 日
Perhaps he edited the code, but there is no missing end. The for loop has an end, and functions don't require an end, and the rest of the lines are just comments. It is badly formatted though, and that can be fixed by highlighting the code and typing control-i. Another nice tip is that if you click on an end, it will tell you, via a pop up tool tip, the matching line for it.

この質問は閉じられています。

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by