Application compiler does not recognize button press
1 view (last 30 days)
Show older comments
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
0 Comments
Answers (0)
See Also
Categories
Find more on Startup and Shutdown in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!