+ case SPR_VP_PARALLEL_UPRIGHT:
+ // flames and such
+ // vertical beam sprite, faces view plane
+ VectorNegate(vpn, matrix3[0]);
+ matrix3[0][2] = 0;
+ VectorNormalizeFast(matrix3[0]);
+ VectorVectors(matrix3[0], matrix3[1], matrix3[2]);
+ break;
+ case SPR_FACING_UPRIGHT:
+ // flames and such
+ // vertical beam sprite, faces viewer's origin (not the view plane)
+ VectorSubtract(r_origin, currentrenderentity->origin, matrix3[0]);
+ matrix3[0][2] = 0;
+ VectorNormalizeFast(matrix3[0]);
+ VectorVectors(matrix3[0], matrix3[1], matrix3[2]);
+ break;
+ default:
+ Con_Printf("R_SpriteSetup: unknown sprite type %i\n", type);
+ // fall through to normal sprite
+ case SPR_VP_PARALLEL:
+ // normal sprite
+ // faces view plane
+ VectorCopy(vpn, matrix3[0]);
+ VectorCopy(vright, matrix3[1]);
+ VectorCopy(vup, matrix3[2]);
+ break;
+ case SPR_ORIENTED:
+ // bullet marks on walls
+ // ignores viewer entirely
+ AngleVectors (currentrenderentity->angles, matrix3[0], matrix3[1], matrix3[2]);
+ // nudge it toward the view, so it will be infront of the wall
+ VectorSubtract(org, vpn, org);
+ break;
+ case SPR_VP_PARALLEL_ORIENTED:
+ // I have no idea what people would use this for
+ // oriented relative to view space
+ // FIXME: test this and make sure it mimicks software
+ AngleVectors (currentrenderentity->angles, matrix1[0], matrix1[1], matrix1[2]);
+ VectorCopy(vpn, matrix2[0]);
+ VectorCopy(vright, matrix2[1]);
+ VectorCopy(vup, matrix2[2]);
+ R_ConcatRotations (matrix1, matrix2, matrix3);
+ break;