Finding 3Dworld position of texture pixel (texel)?

Blitz3D Forums/Blitz3D Programming/Finding 3Dworld position of texture pixel (texel)?

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

As in a radar map?

I did it as a 2D image for the hud...

And I as I remember it's easy math, just get the pixel cordinate x&y subtract half the width&height (if you want the center to be 0) devide it by the whole width& height and multiply the result by the scale of the map.

So it would be something like...
x#=(Pixel_X-(ImageWidth(map)/2))/ImageWidth(map)
z#=(Pixel_Y-(ImageHeight(map)/2))/ImageHeight(map)
PositionEntity(obj,x#*Scale#,0,z#=*Scale#)