samples/mak/multicam
multicam.abs
59 lines of ArcBasic. Words in colour that are commands link to their help page. To run it, download ArcBasic, open the file and press F5.
Graphics3D 640,480tex=CreateTexture( 64,64 )SetBuffer TextureBuffer( tex )Color 255,0,0:Rect 0,0,32,32:Rect 32,32,32,32Color 255,128,0:Rect 32,0,32,32:Rect 0,32,32,32SetBuffer BackBuffer()Color 255,255,255cone=CreateCone(20)EntityTexture cone,texsphere=CreateSphere(10)PositionEntity sphere,2,0,0EntityTexture sphere,texcylinder=CreateCylinder(20)PositionEntity cylinder,-2,0,0EntityTexture cylinder,texlight=CreateLight()TurnEntity light,45,45,0pivot=CreatePivot()z_cam=CreateCamera( pivot )CameraViewport z_cam,0,0,320,240PositionEntity z_cam,0,0,-5y_cam=CreateCamera( pivot )CameraViewport y_cam,320,0,320,240PositionEntity y_cam,0,5,0TurnEntity y_cam,90,0,0x_cam=CreateCamera( pivot )CameraViewport x_cam,0,240,320,240TurnEntity x_cam,0,-90,0PositionEntity x_cam,-5,0,0While Not KeyHit(1) If KeyDown(203) MoveEntity pivot,-.1,0,0 If KeyDown(205) MoveEntity pivot,.1,0,0 If KeyDown(200) MoveEntity pivot,0,.1,0 If KeyDown(208) MoveEntity pivot,0,-.1,0 If KeyDown(30) MoveEntity pivot,0,0,.1 If KeyDown(44) MoveEntity pivot,0,0,-.1 UpdateWorld RenderWorld Text 0,0,"Front" Text 320,0,"Top" Text 0,240,"Left" FlipWendEnd
