How can i use same colormap for diferent imagesc?

for i=1:tam %anima los tubos axes(handles.axes21); colormap('default'); imagesc(temp1); set(handles.axes21,'visible','off') hold on;
axes(handles.axes22);
imagesc(temp2);
set(handles.axes22,'visible','off')
hold on;
axes(handles.axes25);
imagesc(temp3);
set(handles.axes25,'visible','off')
hold on;
axes(handles.axes26);
imagesc(temp4);
set(handles.axes26,'visible','off')
hold on;
drawnow;
auxTemp=vectorTemperaturas(:,i);
%variables para la animacion de los tubos
temp1=(cat(1,auxTemp((IBAR/2)+3:end-1)));
temp2=fliplr((auxTemp(3:(IBAR/2)+1)'))'; %tubo 2
temp3=auxTemp(end);%fuente
temp4=auxTemp(((IBAR/2)+2));%sumidero
end
end
Hold on, seems to be the answer but as it's a loop it becomes slower and slower! pleaseeee help! THANKS!

답변 (1개)

Image Analyst
Image Analyst 2014년 5월 20일

0 개 추천

Yes that will happen because the axes keeps stacking up image after image as you load them in. Each one covers up the prior one. I find that if you call "cla reset" after you call "axes()" then it will not slow down as you go through all the images.

카테고리

도움말 센터File Exchange에서 Graphics Performance에 대해 자세히 알아보기

질문:

2014년 5월 20일

답변:

2014년 5월 20일

Community Treasure Hunt

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

Start Hunting!

Translated by