tag:blogger.com,1999:blog-7135224450787989152.post1901833799996989445..comments2023-08-21T02:19:19.628-07:00Comments on My Adventures in Game Hacking: DirectX DepthIsaachttp://www.blogger.com/profile/10585942371837479099noreply@blogger.comBlogger1125tag:blogger.com,1999:blog-7135224450787989152.post-21299124954168158812013-10-18T02:18:54.057-07:002013-10-18T02:18:54.057-07:00i think each pixel holds depth or Z value.
when a ...i think each pixel holds depth or Z value.<br />when a point in a triangle projected in hlsl vertexshader function ,the point will be sent to pixel shader function as a parameter.the point colored-textured-fogged in pixel shader and then will be sent to screen array.<br /><br />i think far pixel values replaced with near pixel values.<br /><br />i think there is no complex structure behind that.lets suppose if there is a complex 3d structure behind that and you have 1920x1080 screen.<br />you need to acces this structure 60*1920*1080 times in a second.<br /><br /><br />i think there is a simple 2D pixel array<br />struct Pixel{<br />intX,intY<br />Color c,<br />float Depth<br />}<br /><br /><br />if( screen[newPixel.X][newPixel.Y].Depth<newPixel.Depth){<br />screen[newPixel.X][newPixel.Y]=newPixel;<br />}ayhan bilginhttps://www.blogger.com/profile/04907376533732355509noreply@blogger.com