16 #include "fltRecordReader.h" 17 #include "fltRecordWriter.h" 36 _transition_range = 0.0;
49 if (!FltBeadID::extract_record(reader)) {
53 nassertr(reader.
get_opcode() == FO_lod,
false);
57 _switch_in = iterator.get_be_float64();
58 _switch_out = iterator.get_be_float64();
59 _special_id1 = iterator.get_be_int16();
60 _special_id2 = iterator.get_be_int16();
61 _flags = iterator.get_be_uint32();
62 _center_x = iterator.get_be_float64();
63 _center_y = iterator.get_be_float64();
64 _center_z = iterator.get_be_float64();
65 _transition_range = iterator.get_be_float64();
81 if (!FltBeadID::build_record(writer)) {
This class writes a sequence of FltRecords to an ostream, handling opcode and size counts properly...
A base class for any of a broad family of flt beads that include an ID.
This class turns an istream into a sequence of FltRecords by reading a sequence of Datagrams and extr...
void check_remaining_size(const DatagramIterator &di, const string &name=string()) const
Checks that the iterator has no bytes left, as it should at the end of a successfully read record...
DatagramIterator & get_iterator()
Returns an iterator suitable for extracting data from the current record.
void pad_bytes(size_t size)
Adds the indicated number of zero bytes to the datagram.
void add_be_float64(PN_float64 value)
Adds a 64-bit big-endian floating-point number to the datagram.
void skip_bytes(size_t size)
Skips over the indicated number of bytes in the datagram.
FltOpcode get_opcode() const
Returns the opcode associated with the current record.
A class to retrieve the individual data elements previously stored in a Datagram. ...
void add_be_uint32(PN_uint32 value)
Adds an unsigned 32-bit big-endian integer to the datagram.
TypeHandle is the identifier used to differentiate C++ class types.
void set_opcode(FltOpcode opcode)
Sets the opcode associated with the current record.
Datagram & update_datagram()
Returns a modifiable reference to the datagram associated with the current record.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...
void add_be_int16(PN_int16 value)
Adds a signed 16-bit big-endian integer to the datagram.