GUI mouse wheel control to scroll 2D images in axes

Discussion in 'MATLAB' started by Jim O'Doherty, Apr 29, 2011.

  1. Hi All,
    Looking for something that I reckon seems fairly simple yet I can't solve it. I've got a stack of 300 2D frames (medical DICOM) displayed in an axes on a GUI. I want to be able to scroll through the slices using the mouse wheel rather than a slider which I already have.
    On another note, does anyone know if its possible to change the contrast by holding the mouse button and moving the mouse left/right?

    Jim O' Doherty
    Jim O'Doherty, Apr 29, 2011
    1. Advertisements

  2. Jim O'Doherty

    Rune Allnor Guest

    These things are certainly *possible*. The question
    is rather if they will work fast enough that the user
    find the performance acceptable. You might find that
    run-time overhead is too high for such functionality
    to work satisfactorially with matlab.

    Rune Allnor, Apr 29, 2011
    1. Advertisements

  3. Jim O'Doherty

    Steven_Lord Guest

    Use the figure's WindowScrollWheelFcn property.
    Look at the figure's WindowButtonDownFcn and WindowButtonMotionFcn
    properties along with the root PointerLocation property.
    Steven_Lord, Apr 29, 2011
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.