Change Matlab heap from LIFO to FIFO
3 views (last 30 days)
Show older comments
I'm having some troubles with Matlab's heap. The thing is that I'm developing a GUI interface where the user can select a line a move it throughout one axes1 meanwhile in other axes2 some ball move through it depending on the line's position. If the user move the line slowly there is no problem, but if he moves it fast then Matlab catches some of the coordinates and once you stop moving the line it start executing the balls' algorithm (moving them) from the last position to the line to the firs one. As a consequence, the balls don't end on the correct position. I think that it's because Matlab heap is LIFO instead of FIFO, so it would be great if anybody could tell me how to change it, or what I'm doing wrong.
Thanks.
3 Comments
Geoff Hayes
on 29 Nov 2014
Óscar - you may need to post some of your code so that we can get an idea of how the two axes are interacting. It may be that certain events are "piling up" because the first action (moving the line) does not allow itself to be "interrupted" with the moving of the ball on the second axes.
Answers (0)
See Also
Categories
Find more on Interactive Control and Callbacks in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!