this code uses a function to keep the blur equal as the cube changes distances from the camera
Graphics3D 640,480,0,2 ;Graphics3D 320,240,0,3 tex = CreateTexture(128,128) SetBuffer TextureBuffer(tex) Color 200,200,200 Rect 0,0,257,257,1 Color 0,0,255 Text 1,1, "Test Texture" Text 1,20, "Test Texture" Text 1,40, "Test Texture" Text 1,80, "Test Texture" Color 255,255,255 SetBuffer BackBuffer() cam = CreateCamera() MoveEntity cam, 0,0,-6 cube = CreateCube() EntityTexture cube,tex cube2 = CopyMesh(cube) EntityTexture cube2,tex cube3 = CopyMesh(cube) EntityTexture cube2,tex EntityParent cube2, cube EntityParent cube3, cube EntityAlpha cube2,.5 EntityAlpha cube3,.25 ScaleEntity cube2,1.01,1.01,1.01 ScaleEntity cube3,1.02,1.02,1.02 lit = CreateLight() TurnEntity lit, 90,0,0 hide = True cnt# = 0 While Not KeyDown(1) Cls cnt = cnt + 2 TurnEntity cube,1,1,0 PositionEntity cam,0,0,-7+ 4*Sin(cnt#/4) If KeyHit(57) Then hide = Not hide calcscale(cube2,cam,1) calcscale(cube3,cam,2) If hide = True Then HideEntity cube3 HideEntity cube2 Else ShowEntity cube2 ShowEntity cube3 EndIf UpdateWorld() RenderWorld() Text 1,1, "PRESS THE SPACEBAR TO TOGGLE BETWEEN SHARP EDGES AND BLURRY EDGES." If HIDE Then Text 1,20,"Sharp Edges" If Not hide Then Text 1,20,"Blurry Edges" Delay 20 Flip Wend Function calcscale(obj,camera,layer) dist# = EntityDistance(camera,obj) scl# = dist#/500 scl# = scl# * layer scl# = scl# + 1 ScaleEntity obj,scl#,scl#,scl# End Function