Application compiler does not recognize button press

1 visualización (últimos 30 días)
Konvictus177
Konvictus177 el 18 de Oct. de 2021
Editada: Konvictus177 el 18 de Oct. de 2021
Hi,
I wrote a matlab code where I use left arrow and right arrow button keys to increase my frame counter in a while loop where I plot a video. On the plot window it basically plots the new frame each time the left or right button key is pressed.
Now I used the application compiler to create an application. However when I execute the application it does not do anything on left arrow and right arrow button press.
Any idea why?
Here is a short description of the code:
while (frame <= endframe & frame >= startframe)
thisFrame = read(v, frame);
hImage = subplot(2, 1, 1);
imshow(thisFrame, 'Parent', ax1);
pause(); % wait for a keypress
currkey=get(gcf,'CurrentKey');
if strcmp(currkey, 'rightarrow')
frame = frame + 1;
continue;
end
if strcmp(currkey, 'leftarrow')
frame = frame -1;
continue;
end

Respuestas (0)

Categorías

Más información sobre Startup and Shutdown en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by