Having trouble with what should be a trivial problem.
I have a 10x10 grid rendered into an EditorWindow via GL. I can scroll the grid infinitely and i can zoom it infinitely by multiplying the underlying cells by x2 and wrapping that zoomfactor so it loops back to 1. If i keep the grid at my ‘scrolled’ origin then it all works great.
If i ‘scroll’ the grid, the cells ‘pop’ when they should be smooth everytime the zoom factor loops. So, having realised i needed to apply an offset to compensate for the zoomed origin of the graph, i now have issues with scrolling through it smoothly. It appears to be non-trivial in calculating the cell distance travelled via a modulus.
So…i feel i’m probably going tackling this issue the wrong way and making it more difficult than expected. So the question should be more, how would you do it…so that ultimately it will support framing of a certain region of data and so on and allow the user to smoothly scrolling around, in and out like the softimage editor etc…
Any ideas/insights would be helpful.