I thought I could use the normal picking procedure to select objects with a rubberband box but this only works if the area is completely covered with objects.
If I have a part of the area without objects, I get zero hits.
Is this expected behaviour?
If so, what can I do to create a rubberband selection?
Box diagonal corners (x0,y0) and (x,y)
Thanks for your feedback
/Jonas Forssell, Gothenburg, Sweden
Try something like this instead.
Math.min(y0,y)+ysize/2.0, xsize, ysize);
I have not tried it but something like that should work, the example above assume that your y values are correct OpenGL values and not standard mouse coordinates.
(You need to specify the center of the box and the width and height of the box as arguments)
I also found that the buffer was not set high enough so when the selection included too much element, none was selected!