Multiple World Translations
Posted: Sun May 29, 2011 3:23 pm
Hi there, I'm having a problem with translations.
This is how the scene should look:

This is how BEPU renders (world translation anyway) it:

The way this scene is made is by having one quad that gets translated into position for every side of the square it renders.
This is how the tranlation gets filled: (loops through all grids and if there is anything in there, translate the face by the XYZ)
Actual render code. The functions dont alter the world, view, projection or camera position; it just sends them the the shader.
Here is how the normal render code looks:

Here is how im trying to get bepu to do the same:

Any ideas on whats going on here?
This is how the scene should look:

This is how BEPU renders (world translation anyway) it:

The way this scene is made is by having one quad that gets translated into position for every side of the square it renders.
This is how the tranlation gets filled: (loops through all grids and if there is anything in there, translate the face by the XYZ)
Code: Select all
Camera.WorldTranslation = new Vector3(qLayer[k].grid[i].x, qLayer[k].grid[i].y, qLayer[k].grid[i].z);
Camera.UpdateBEPUMatrix();
Code: Select all
OI.render.UpdateMatrix(Camera.World, Camera.View, Camera.Projection, Camera.BCAM.Position); <- this BCAM is the camera for the Simple character controller
OI.render.Render(vbuff, Textures.textures[tidx].color, Textures.textures[tidx].norm, 1);

Here is how im trying to get bepu to do the same:

Any ideas on whats going on here?