37 if (!FltBeadID::extract_record(reader)) {
44 if (!FltGeometry::extract_record(reader)) {
48 nassertr(reader.
get_opcode() == FO_mesh,
false);
61 if (reader.
get_opcode() == FO_local_vertex_pool) {
62 _vpool =
new FltLocalVertexPool(_header);
63 return _vpool->extract_record(reader);
66 return FltBeadID::extract_ancillary(reader);
76 if (!FltBeadID::build_record(writer)) {
83 if (!FltGeometry::build_record(writer)) {
98 if (_vpool !=
nullptr) {
99 if (!_vpool->build_record(writer)) {
100 assert(!flt_error_abort);
103 FltError result = writer.
advance();
104 if (result != FE_ok) {
109 return FltBeadID::write_ancillary(writer);
void skip_bytes(size_t size)
Skips over the indicated number of bytes in the datagram.
void pad_bytes(size_t size)
Adds the indicated number of zero bytes to the datagram.
This is a base class for both FltFace and FltMesh, which are two different kinds of geometric primiti...
This class turns an istream into a sequence of FltRecords by reading a sequence of Datagrams and extr...
FltOpcode get_opcode() const
Returns the opcode associated with the current record.
DatagramIterator & get_iterator()
Returns an iterator suitable for extracting data from the current record.
This class writes a sequence of FltRecords to an ostream, handling opcode and size counts properly.
void set_opcode(FltOpcode opcode)
Sets the opcode associated with the current record.
FltError advance()
Writes the current record to the flt file, and resets the current record to receive new data.
Datagram & update_datagram()
Returns a modifiable reference to the datagram associated with the current record.
void check_remaining_size(const DatagramIterator &di, const std::string &name=std::string()) const
Checks that the iterator has no bytes left, as it should at the end of a successfully read record.
TypeHandle is the identifier used to differentiate C++ class types.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.