Placing a grid on a flat pano

  • http://www.highres.factum-arte.org/svf_lr/index.html
    Sorry this has only the preview image, so as to show what I need to do but not to show the actual data that I cannot publish yet.

    I am working on a painting and 3D viewer. The 3D is a rendering of 3D scanning of the surface at 100 microns resolution.
    I have worked on my code to build a few tools, as a ruler that update an indication of dimension as one zoom in or out, or resize the window.
    There is also a button on the ruler that places a grid on the image.
    The grid is made of hotspots that are created one by one and their placement is updated in an onviewchange event that trigger the updategrid action I wrote.
    In this example the grid is "only" 17 horizontal lines and 17 vertical ones so I just update them one by one.
    Of course I feel that both the creation of the hotspots lines and their updating should be done in a loop instead of one by one.
    Even more if I eventually want to add a 10mm grid as one zoom in.

    How would I create the hotspots and update them using a loop?

    The code is below

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!