mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 21:39:52 +00:00
softgpu: Storing view coordinates in VertexData is not necessary anymore.
This commit is contained in:
parent
3cdf2a789d
commit
72a71702a5
@ -140,8 +140,7 @@ void TransformUnit::SubmitPrimitive(void* vertices, void* indices, u32 prim_type
|
||||
if (!gstate.isModeThrough()) {
|
||||
ModelCoords mcoords(pos[0], pos[1], pos[2]);
|
||||
data[i].worldpos = WorldCoords(TransformUnit::ModelToWorld(mcoords));
|
||||
data[i].viewpos = TransformUnit::WorldToView(data[i].worldpos);
|
||||
data[i].clippos = ClipCoords(TransformUnit::ViewToClip(data[i].viewpos));
|
||||
data[i].clippos = ClipCoords(TransformUnit::ViewToClip(TransformUnit::WorldToView(data[i].worldpos)));
|
||||
data[i].drawpos = DrawingCoords(TransformUnit::ScreenToDrawing(TransformUnit::ClipToScreen(data[i].clippos)));
|
||||
|
||||
if (vreader.hasNormal()) {
|
||||
|
@ -44,7 +44,7 @@ struct VertexData
|
||||
#define LINTERP(T, OUT, IN) (OUT) + ((IN - OUT) * T)
|
||||
#define LINTERP_INT(T, OUT, IN) (OUT) + (((IN - OUT) * T) >> 8)
|
||||
|
||||
// World and view coords only needed for lighting, so we don't Lerp those
|
||||
// World coords only needed for lighting, so we don't Lerp those
|
||||
|
||||
clippos.x = LINTERP(t, a.clippos.x, b.clippos.x);
|
||||
clippos.y = LINTERP(t, a.clippos.y, b.clippos.y);
|
||||
@ -76,7 +76,6 @@ struct VertexData
|
||||
}
|
||||
|
||||
WorldCoords worldpos; // TODO: Storing this is dumb, should transform the light to clip space instead
|
||||
ViewCoords viewpos; // TODO: Storing this is dumb, should transform the light to clip space instead
|
||||
ClipCoords clippos;
|
||||
DrawingCoords drawpos; // TODO: Shouldn't store this ?
|
||||
Vec2<float> texturecoords;
|
||||
|
Loading…
Reference in New Issue
Block a user