I've been looking through this guys journal some just to get a feel for where he started and how he got there, and if any of it is useful to us.
First of all, can someone with more graphics background explain field of view?
Specifically I'm referring to his Aug 30, 2004 post.
I finally fixed the impostor bug. The formula i used was wrong, i was not calculating the frustum field of view angle correctly. It was a bit tricky to understand why, but revising my trigonometry helped a bit. For those interesting, the code looks like this: for a viewer position located at ViewPos, the impostored object being represented as its bounding sphere Center, Radius,
float d = distance(ViewPos, Center)
float fov = asin(Radius / d)
float l = d * tan(fov)
matrix4x4 viewMatrix = buildLookAtMatrix(ViewPos, Center)
viewMatrix = buildTranslateMatrix(-ViewPos) * viewMatrix.transpose()
matrix4x4 projMatrix = buildProjectionMatrix(fov, 1, znear, zfar)
matrix4x4 worldMatrix = buildIdentityMatrix()
Looking at what kind of triangle that math produces makes absolutely no sense physically. I'd expect something more like.
fov = atan(Radius/d)
l = Radius / sin(fov)
Is there something missing? (Probably the definition of field of view).