wavelength 1.0.0
Loading...
Searching...
No Matches
rndmesh.h File Reference
#include <cstddef>
#include <list>
#include <memory>
#include <vector>
#include "math/box.h"
#include "math/color.h"
#include "math/plane.h"
#include "math/sphere.h"
#include "math/transform.h"
#include "math/vector2.h"
#include "math/vector3.h"
#include "os/binstream.h"
#include "os/mem.h"
#include "os/prnstream.h"
#include "rnd/rndcollideable.h"
#include "rnd/rnddrawable.h"
#include "rnd/rndmat.h"
#include "rnd/rndtransformable.h"
Include dependency graph for rndmesh.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  RndMesh
 Triangle mesh with a material. More...
class  RndMesh::Vert
 One vertex. More...
class  RndMesh::Face
 One triangle, as indices into the vertices. More...
class  RndMesh::Edge
 One edge, as indices into the vertices. More...
struct  RndMesh::Bones
 The two bone transforms the vertex weights blend. More...

Functions

PrnStream & operator<< (PrnStream &stream, const RndMesh::Vert &vert)
 Write a vertex.
PrnStream & operator<< (PrnStream &stream, const RndMesh::Face &face)
 Write a triangle.
PrnStream & operator<< (PrnStream &stream, const RndMesh::Edge &edge)
 Write an edge.
PrnStream & operator<< (PrnStream &stream, RndMesh::ZMode eMode)
 Write the name of a depth mode.
PrnStream & operator<< (PrnStream &stream, RndMesh::ZFunc eFunc)
 Write the name of a depth comparison.
BinStream & operator<< (BinStream &stream, const RndMesh::Vert &vert)
 Write a vertex as its position, weights, normal, colour, and texture coordinates.
BinStream & operator>> (BinStream &stream, RndMesh::Vert &vert)
 Read a vertex the vertex writer wrote, or an earlier version of it.
BinStream & operator<< (BinStream &stream, const RndMesh::Face &face)
 Write a triangle as its three indices.
BinStream & operator>> (BinStream &stream, RndMesh::Face &face)
 Read a triangle the triangle writer wrote, or an earlier version of it.
BinStream & operator<< (BinStream &stream, const RndMesh::Edge &edge)
 Write an edge as its two indices.
BinStream & operator>> (BinStream &stream, RndMesh::Edge &edge)
 Read an edge the edge writer wrote.

Function Documentation

◆ operator<<() [1/8]

PrnStream & operator<< ( PrnStream & stream,
const RndMesh::Vert & vert )

Write a vertex.

Parameters
streamThe stream to write to.
vertThe vertex.
Returns
The stream.
Ghidra address:
NTSC-U/C: 0x00232c98
Ghidra address:
PAL: 0x0023b860

◆ operator<<() [2/8]

PrnStream & operator<< ( PrnStream & stream,
const RndMesh::Face & face )

Write a triangle.

Parameters
streamThe stream to write to.
faceThe triangle.
Returns
The stream.
Ghidra address:
NTSC-U/C: 0x002349e0
Ghidra address:
PAL: 0x0023d560

◆ operator<<() [3/8]

PrnStream & operator<< ( PrnStream & stream,
const RndMesh::Edge & edge )

Write an edge.

Parameters
streamThe stream to write to.
edgeThe edge.
Returns
The stream.
Ghidra address:
NTSC-U/C: 0x00234b08
Ghidra address:
PAL: 0x0023d688

◆ operator<<() [4/8]

PrnStream & operator<< ( PrnStream & stream,
RndMesh::ZMode eMode )

Write the name of a depth mode.

An unknown mode writes nothing.

Parameters
streamThe stream to write to.
eModeThe mode.
Returns
The stream.
Ghidra address:
NTSC-U/C: 0x00234b80
Ghidra address:
PAL: 0x0023d700

◆ operator<<() [5/8]

PrnStream & operator<< ( PrnStream & stream,
RndMesh::ZFunc eFunc )

Write the name of a depth comparison.

An unknown comparison writes nothing.

Parameters
streamThe stream to write to.
eFuncThe comparison.
Returns
The stream.
Ghidra address:
NTSC-U/C: 0x00234c38
Ghidra address:
PAL: 0x0023d7b8

◆ operator<<() [6/8]

BinStream & operator<< ( BinStream & stream,
const RndMesh::Vert & vert )

Write a vertex as its position, weights, normal, colour, and texture coordinates.

The binary expands the writer inline in the vertex vector writer.

Parameters
streamThe stream to write to.
vertThe vertex.
Returns
The stream.

◆ operator>>() [1/3]

BinStream & operator>> ( BinStream & stream,
RndMesh::Vert & vert )

Read a vertex the vertex writer wrote, or an earlier version of it.

The version is the one RndMesh::Load() read last.

Parameters
streamThe stream to read from.
vertReceives the vertex.
Returns
The stream.
Ghidra address:
NTSC-U/C: 0x00234248
Ghidra address:
PAL: 0x0023cdc8

◆ operator<<() [7/8]

BinStream & operator<< ( BinStream & stream,
const RndMesh::Face & face )

Write a triangle as its three indices.

The binary expands the writer inline in the triangle vector writer at 0x003893e0.

Parameters
streamThe stream to write to.
faceThe triangle.
Returns
The stream.

◆ operator>>() [2/3]

BinStream & operator>> ( BinStream & stream,
RndMesh::Face & face )

Read a triangle the triangle writer wrote, or an earlier version of it.

The version is the one RndMesh::Load() read last.

Parameters
streamThe stream to read from.
faceReceives the triangle.
Returns
The stream.
Ghidra address:
NTSC-U/C: 0x00234a70
Ghidra address:
PAL: 0x0023d5f0

◆ operator<<() [8/8]

BinStream & operator<< ( BinStream & stream,
const RndMesh::Edge & edge )

Write an edge as its two indices.

The binary expands the writer inline in the edge vector writer at 0x003894b0.

Parameters
streamThe stream to write to.
edgeThe edge.
Returns
The stream.

◆ operator>>() [3/3]

BinStream & operator>> ( BinStream & stream,
RndMesh::Edge & edge )

Read an edge the edge writer wrote.

The binary expands the reader inline in the edge vector reader at 0x00389768.

Parameters
streamThe stream to read from.
edgeReceives the edge.
Returns
The stream.