mirror of
https://github.com/libretro/scummvm.git
synced 2025-03-05 09:49:14 +00:00
TWINE: removed lineData struct
This commit is contained in:
parent
023114f03c
commit
456801b29f
@ -1033,20 +1033,11 @@ uint8 *Renderer::prepareLines(Common::MemoryReadStream &stream, int32 &numOfPrim
|
||||
numOfPrimitives += numLines;
|
||||
|
||||
do {
|
||||
lineData line;
|
||||
line.colorIndex = stream.readByte();
|
||||
stream.skip(3);
|
||||
line.firstPointOffset = stream.readSint16LE();
|
||||
line.secondPointOffset = stream.readSint16LE();
|
||||
CmdRenderLine *lineCoordinatesPtr = (CmdRenderLine *)renderBufferPtr;
|
||||
|
||||
if (line.firstPointOffset % 6 != 0 || line.secondPointOffset % 6 != 0) {
|
||||
error("RENDER ERROR: lineDataPtr reference is malformed!");
|
||||
}
|
||||
|
||||
const int32 point1Index = line.firstPointOffset / 6;
|
||||
const int32 point2Index = line.secondPointOffset / 6;
|
||||
lineCoordinatesPtr->colorIndex = line.colorIndex;
|
||||
lineCoordinatesPtr->colorIndex = stream.readByte();
|
||||
stream.skip(3);
|
||||
const int32 point1Index = stream.readSint16LE() / 6;
|
||||
const int32 point2Index = stream.readSint16LE()/ 6;
|
||||
lineCoordinatesPtr->x1 = modelData->flattenPoints[point1Index].x;
|
||||
lineCoordinatesPtr->y1 = modelData->flattenPoints[point1Index].y;
|
||||
lineCoordinatesPtr->x2 = modelData->flattenPoints[point2Index].x;
|
||||
|
@ -232,15 +232,6 @@ private:
|
||||
#include "common/pack-end.h"
|
||||
static_assert(sizeof(pointTab) == 6, "Unexpected pointTab size");
|
||||
|
||||
struct lineData {
|
||||
uint8 colorIndex = 0;
|
||||
uint8 unk1 = 0;
|
||||
uint8 unk2 = 0;
|
||||
uint8 unk3 = 0;
|
||||
int16 firstPointOffset = 0; /**< byte offsets */
|
||||
int16 secondPointOffset = 0; /**< byte offsets */
|
||||
};
|
||||
|
||||
struct polyVertexHeader {
|
||||
int16 shadeEntry = 0;
|
||||
int16 dataOffset = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user