Hey everyone!
can you give me a detailed explanation on how to display my 3d program on my desktop?
thanks in advance.
can you give me a detailed explanation on how to display my 3d program on my desktop?
thanks in advance.
.lib "user32.dll" GetFocus%():"GetFocus" GetWindowLong%(hwnd%,index%):"GetWindowLongA" SetWindowLong%(hwnd%,index%,newvalue%):"SetWindowLongA" SetWindowPos%(hwnd%,a%,x%,y%,cx%,cy%,wFlags%):"SetWindowPos" GetSystemMetrics%(a%):"GetSystemMetrics"
Global SX%=GetSystemMetrics(0) Global SY%=GetSystemMetrics(1) SetDesktopOverscanMode() camera=CreateCamera() light=CreateLight() cube=CreateCube() EntityColor cube,100,0,120 EntityShininess cube,1 PositionEntity camera,0,0,-10 While Not KeyHit(1) RenderWorld TurnEntity cube,.5,.1,.2 UpdateWorld Delay(1) Flip False Wend End Function SetDesktopOverscanMode() Graphics3D SX,SY,32,2 hwnd%=GetFocus%() x%=GetWindowLong%(hwnd,(-16)) x = x Xor $80000 x = x Xor $20000 x = x Xor $10000 x = x Xor $C00000 SetWindowLong%(hwnd,(-16),x) SetWindowPos%(hwnd,0,0,0,sx,sy,$20) End Function