Bear on the job.6273:

I’m working on a project that is making use of the vector information in the Mumble link data to draw overlay information on the player’s screen. However, I’m having a problem resolving some of the vectors. Most notably, the “fCameraFront[]” vector is missing the z-axis information (fCameraFront1 is always 0). It contains the x and y-axis information (for providing a top-down camera facing direction), but not the z-axis.

Could this information be added to the vectors? I’ve been trying to estimate the front vector by tracing the line between fCameraPosition[] and fAvatarPosition[]…but it seems like there is some offset in play, and that traced vector is not accurate.

Cliff Spradlin.3512:

fCameraFront is derived directly from our camera data. fAvatarFront does force the z axis to be 0, but it normalizes out the z axis into the x and y coordinate. Maybe your structure is wrong?

Note, I didn’t test it to see if the fCameraFront1 is always 0, maybe it is. If so, it might be fixable.

What are you trying to do?

Bear on the job.6273:

I’m trying to project an icon onto the player screen (drawing a transparent window over the game in windowed mode). To draw the icon properly, I need to know the pitch of the camera, which should be obtainable from the z-axis portion of the normalized fCameraFront[] vector. Unfortunately, fCameraFront [ 1 ] is always reporting as 0, so the camera facing is only being projected onto the x/y plane.

I noticed that fAvatarFront [ 1 ] is also being forced to 0. That seems approrpriate, as the player character can’t pitch and should always be standing upright. But imo, fCameraFront [ 1 ] being should be available, as the camera angle can be pitched by the player’s mouse.

EDIT: Also just to note, all the other vector data from the struct is accuracte. fAvatarPosition and fCameraPosition work properly, and I can get a pretty good estimate of the camera facing from those points. But when the camera clips on a hill or something, or you pitch really high or low, the vector extrapolated from those points gets wonky.

EDIT: P.S. Thanks for the quick response, I’m always amazed by how attentive you are to this forum. It is much appreciated.

Cliff Spradlin.3512:

Yeah, that makes sense to me. I’ve filed a bug on it.

Bear on the job.6273:

Thanks much. I was getting frustrated trying to use the estimated vector. If the fCameraFront[] vector will eventually report the full camera facing, along with fCameraPosition[] being the actual position (taking clipping into account) that will make things worlds easier.

Firilion.3867:

A fix to the missing z-axis would be very much appreciated.
I was getting kinda mad trying to resolve this issue until i found this post here.

I’m trying to build an application like the one Bear on the job is working on. It will bring up Information to the player within a transparent window, a bit like a H.U.D.
It is part of a complete Solution for my guild to enhance the experience of the game.
It has a Client Server Architecture (WPF Service on an IIS with a SQL DB behind and a WPF Client) which provides a calendar, wvw live maps, boss-event timer, countdowntimer, an imagegallery, own chats and a lot more useful functions shared within my guild.
The H.U.D will be the central display unit for all those informations.

But without the z-axis i cannot place the icons correct, when the player pitches his camera.

And thank you for your fast response Cliff an that great API you are providing for us!

Cliff Spradlin.3512:

This should be fixed in the latest patch.