Thank you so much for your help.
You've been very helpful to me on my little project, both with direct answers to my questions, and with older forum threads where you've helped other people.
This really is a great community.
Okay, onto your solution...
That's a great idea - and really quite obvious now that it's been suggested to me.
I had trouble using a plane for picking the corners of the screen, but I used a flipped cube (like a skybox) and that worked!
Unfortunately the FlipMesh command still defeats me.
My mesh disappears if I use the FlipMesh command, and I just can't get my head around how FlipMesh works.
If I comment out the FlipMesh command, my mesh is visible.
Here's what I've got at the moment.
(buildMesh is just a routine that creates a mesh and adds some surfaces to it via AddVertex and AddTriangle).
You've been very helpful to me on my little project, both with direct answers to my questions, and with older forum threads where you've helped other people.
This really is a great community.
Okay, onto your solution...
That's a great idea - and really quite obvious now that it's been suggested to me.
I had trouble using a plane for picking the corners of the screen, but I used a flipped cube (like a skybox) and that worked!
Unfortunately the FlipMesh command still defeats me.
My mesh disappears if I use the FlipMesh command, and I just can't get my head around how FlipMesh works.
If I comment out the FlipMesh command, my mesh is visible.
Here's what I've got at the moment.
(buildMesh is just a routine that creates a mesh and adds some surfaces to it via AddVertex and AddTriangle).
Graphics3D 1024,768,32,2 SetBuffer BackBuffer() Global mesh Global cam=CreateCamera() Global camNear#=1 Global camFar#=1000 CameraRange cam,camNear,camFar Global boundLeft# Global boundRight# Global boundTop# Global boundBottom# Local cube=CreateCube() PositionEntity cube,0,0,0 EntityPickMode cube,2 FlipMesh cube CameraPick(cam,0,0) boundLeft=PickedX() boundTop=PickedY() CameraPick(cam,GraphicsWidth(),GraphicsHeight()) boundRight=PickedX() boundBottom=PickedY() FreeEntity cube buildMesh() FitMesh mesh,(boundRight-boundLeft)*-0.5,(boundBottom-boundTop)*0.5,1,boundRight-boundLeft,boundRight-boundLeft,0.001 Repeat RenderWorld Flip True Until KeyHit(1) End