Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

FltHeader Class Reference

#include <fltHeader.h>

Inheritance diagram for FltHeader:

FltBeadID FltBead FltRecord TypedReferenceCount TypedObject ReferenceCount List of all members.

Public Types

enum  AttrUpdate { AU_none, AU_if_missing, AU_always }
enum  Units {
  U_meters = 0, U_kilometers = 1, U_feet = 4, U_inches = 5,
  U_nautical_miles = 8
}
enum  Flags { F_save_vertex_normals = 0x80000000 }
enum  ProjectionType {
  PT_flat_earth = 0, PT_trapezoidal = 1, PT_round_earth = 2, PT_lambert = 3,
  PT_utm = 4
}
enum  VertexStorageType { VTS_double = 1 }
enum  DatabaseOrigin {
  DO_open_flight = 100, DO_dig = 200, DO_es_ct6 = 300, DO_psp = 400,
  DO_ge_civ = 600, DO_es_gdf = 700
}
enum  EarthModel {
  EM_wgs84 = 0, EM_wgs72 = 1, EM_bessel = 2, EM_clarke_1866 = 3,
  EM_nad27 = 4
}

Public Member Functions

 FltHeader (PathReplace *path_replace)
virtual void apply_converted_filenames ()
void set_path_replace (PathReplace *path_replace)
PathReplaceget_path_replace ()
const PathReplaceget_path_replace () const
Filename convert_path (const Filename &orig_filename, const DSearchPath &additional_path=DSearchPath())
void set_flt_filename (const Filename &flt_filename)
const Filenameget_flt_filename () const
FltError read_flt (Filename filename)
FltError read_flt (istream &in)
FltError write_flt (Filename filename)
FltError write_flt (ostream &out)
void set_auto_attr_update (AttrUpdate attr)
AttrUpdate get_auto_attr_update () const
int get_flt_version () const
void set_flt_version (int version)
bool check_version () const
DistanceUnit get_units () const
bool has_instance (int instance_index) const
FltInstanceDefinitionget_instance (int instance_index) const
void clear_instances ()
void add_instance (FltInstanceDefinition *instance)
void remove_instance (int instance_index)
int get_num_vertices () const
FltVertexget_vertex (int n) const
void clear_vertices ()
void add_vertex (FltVertex *vertex)
FltVertexget_vertex_by_offset (int offset)
int get_offset_by_vertex (FltVertex *vertex)
int get_num_colors () const
Colorf get_color (int color_index) const
RGBColorf get_rgb (int color_index) const
bool has_color_name (int color_index) const
string get_color_name (int color_index) const
int get_closest_color (Colorf color) const
int get_closest_rgb (RGBColorf color) const
int get_num_color_entries () const
int get_num_color_shades () const
Colorf get_color (int color_index, bool use_packed_color, const FltPackedColor &packed_color, int transparency)
RGBColorf get_rgb (int color_index, bool use_packed_color, const FltPackedColor &packed_color)
bool has_material (int material_index) const
FltMaterialget_material (int material_index) const
void clear_materials ()
void add_material (FltMaterial *material)
void remove_material (int material_index)
bool has_texture (int texture_index) const
FltTextureget_texture (int texture_index) const
void clear_textures ()
void add_texture (FltTexture *texture)
void remove_texture (int texture_index)
bool has_light_source (int light_index) const
FltLightSourceDefinitionget_light_source (int light_index) const
void clear_light_sources ()
void add_light_source (FltLightSourceDefinition *light_source)
void remove_light_source (int light_index)
bool got_eyepoint_trackplane_palette () const
void set_eyepoint_trackplane_palette (bool flag)
int get_num_eyepoints () const
FltEyepointget_eyepoint (int n)
int get_num_trackplanes () const
FltTrackplaneget_trackplane (int n)
virtual TypeHandle get_type () const
virtual TypeHandle force_init_type ()

Static Public Member Functions

int min_flt_version ()
int max_flt_version ()
TypeHandle get_class_type ()
void init_type ()

Public Attributes

int _format_revision_level
int _edit_revision_level
string _last_revision
int _next_group_id
int _next_lod_id
int _next_object_id
int _next_face_id
int _unit_multiplier
Units _vertex_units
bool _texwhite_new
unsigned int _flags
ProjectionType _projection_type
int _next_dof_id
VertexStorageType _vertex_storage_type
DatabaseOrigin _database_origin
double _sw_x
double _sw_y
double _delta_x
double _delta_y
int _next_sound_id
int _next_path_id
int _next_clip_id
int _next_text_id
int _next_bsp_id
int _next_switch_id
double _sw_lat
double _sw_long
double _ne_lat
double _ne_long
double _origin_lat
double _origin_long
double _lambert_upper_lat
double _lambert_lower_lat
int _next_light_id
int _next_road_id
int _next_cat_id
EarthModel _earth_model
int _next_adaptive_id
int _next_curve_id
double _delta_z
double _radius
int _next_mesh_id

Protected Member Functions

virtual bool extract_record (FltRecordReader &reader)
virtual bool extract_ancillary (FltRecordReader &reader)
virtual bool build_record (FltRecordWriter &writer) const
virtual FltError write_ancillary (FltRecordWriter &writer) const

Private Types

typedef pmap< int, PT(FltInstanceDefinitionInstances )
typedef pvector< PT(FltVertexVertices )
typedef pset< FltVertex * > UniqueVertices
typedef pmap< int, FltVertex * > VerticesByOffset
typedef pmap< FltVertex *,
int
OffsetsByVertex
typedef pvector< FltPackedColorColors
typedef pmap< int, string > ColorNames
typedef pmap< int, PT(FltMaterialMaterials )
typedef pmap< int, PT(FltTextureTextures )
typedef pmap< int, PT(FltLightSourceDefinitionLightSources )

Private Member Functions

int update_vertex_lookups ()
 PT (PathReplace) _path_replace
bool extract_vertex (FltRecordReader &reader)
bool extract_color_palette (FltRecordReader &reader)
bool extract_material (FltRecordReader &reader)
bool extract_14_material_palette (FltRecordReader &reader)
bool extract_texture (FltRecordReader &reader)
bool extract_texture_map (FltRecordReader &reader)
bool extract_light_source (FltRecordReader &reader)
bool extract_eyepoint_palette (FltRecordReader &reader)
FltError write_vertex_palette (FltRecordWriter &writer) const
FltError write_color_palette (FltRecordWriter &writer) const
FltError write_material_palette (FltRecordWriter &writer) const
FltError write_texture_palette (FltRecordWriter &writer) const
FltError write_light_source_palette (FltRecordWriter &writer) const
FltError write_eyepoint_palette (FltRecordWriter &writer) const

Private Attributes

Instances _instances
Vertices _vertices
UniqueVertices _unique_vertices
VerticesByOffset _vertices_by_offset
OffsetsByVertex _offsets_by_vertex
bool _vertex_lookups_stale
int _current_vertex_offset
bool _got_color_palette
Colors _colors
ColorNames _color_names
bool _got_14_material_palette
Materials _materials
AttrUpdate _auto_attr_update
Textures _textures
LightSources _light_sources
bool _got_eyepoint_trackplane_palette
FltEyepoint _eyepoints [10]
FltTrackplane _trackplanes [10]
Filename _flt_filename

Static Private Attributes

TypeHandle _type_handle

Member Typedef Documentation

typedef pmap<int, string> FltHeader::ColorNames [private]
 

Definition at line 273 of file fltHeader.h.

typedef pvector<FltPackedColor> FltHeader::Colors [private]
 

Definition at line 272 of file fltHeader.h.

typedef pmap<int, PT(FltInstanceDefinition) FltHeader::Instances) [private]
 

Definition at line 245 of file fltHeader.h.

typedef pmap<int, PT(FltLightSourceDefinition) FltHeader::LightSources) [private]
 

Definition at line 291 of file fltHeader.h.

typedef pmap<int, PT(FltMaterial) FltHeader::Materials) [private]
 

Definition at line 280 of file fltHeader.h.

typedef pmap<FltVertex *, int> FltHeader::OffsetsByVertex [private]
 

Definition at line 256 of file fltHeader.h.

typedef pmap<int, PT(FltTexture) FltHeader::Textures) [private]
 

Definition at line 286 of file fltHeader.h.

typedef pset<FltVertex *> FltHeader::UniqueVertices [private]
 

Definition at line 253 of file fltHeader.h.

typedef pvector<PT(FltVertex) FltHeader::Vertices) [private]
 

Definition at line 252 of file fltHeader.h.

typedef pmap<int, FltVertex *> FltHeader::VerticesByOffset [private]
 

Definition at line 255 of file fltHeader.h.


Member Enumeration Documentation

enum FltHeader::AttrUpdate
 

Enumeration values:
AU_none 
AU_if_missing 
AU_always 

Definition at line 72 of file fltHeader.h.

enum FltHeader::DatabaseOrigin
 

Enumeration values:
DO_open_flight 
DO_dig 
DO_es_ct6 
DO_psp 
DO_ge_civ 
DO_es_gdf 

Definition at line 105 of file fltHeader.h.

enum FltHeader::EarthModel
 

Enumeration values:
EM_wgs84 
EM_wgs72 
EM_bessel 
EM_clarke_1866 
EM_nad27 

Definition at line 114 of file fltHeader.h.

enum FltHeader::Flags
 

Enumeration values:
F_save_vertex_normals 

Definition at line 89 of file fltHeader.h.

enum FltHeader::ProjectionType
 

Enumeration values:
PT_flat_earth 
PT_trapezoidal 
PT_round_earth 
PT_lambert 
PT_utm 

Definition at line 93 of file fltHeader.h.

enum FltHeader::Units
 

Enumeration values:
U_meters 
U_kilometers 
U_feet 
U_inches 
U_nautical_miles 

Definition at line 81 of file fltHeader.h.

enum FltHeader::VertexStorageType
 

Enumeration values:
VTS_double 

Definition at line 101 of file fltHeader.h.


Constructor & Destructor Documentation

FltHeader::FltHeader PathReplace path_replace  ) 
 

Definition at line 48 of file fltHeader.cxx.

References _auto_attr_update, _current_vertex_offset, _database_origin, _delta_x, _delta_y, _delta_z, _earth_model, _edit_revision_level, _flags, _format_revision_level, _got_14_material_palette, _got_color_palette, _got_eyepoint_trackplane_palette, _lambert_lower_lat, _lambert_upper_lat, _ne_lat, _ne_long, _next_adaptive_id, _next_bsp_id, _next_cat_id, _next_clip_id, _next_curve_id, _next_dof_id, _next_face_id, _next_group_id, _next_light_id, _next_lod_id, _next_mesh_id, _next_object_id, _next_path_id, _next_road_id, _next_sound_id, _next_switch_id, _next_text_id, _origin_lat, _origin_long, _projection_type, _radius, _sw_lat, _sw_long, _sw_x, _sw_y, _texwhite_new, _unit_multiplier, _vertex_lookups_stale, _vertex_storage_type, _vertex_units, AU_if_missing, DO_open_flight, EM_wgs84, NULL, PS_absolute, PT_flat_earth, U_feet, and VTS_double.


Member Function Documentation

void FltHeader::add_instance FltInstanceDefinition instance  ) 
 

Definition at line 510 of file fltHeader.cxx.

References FltInstanceDefinition::_instance_index, and _instances.

Referenced by FltRecord::read_record_and_children().

void FltHeader::add_light_source FltLightSourceDefinition light_source  ) 
 

Definition at line 1081 of file fltHeader.cxx.

References FltLightSourceDefinition::_light_index, and _light_sources.

Referenced by extract_light_source().

void FltHeader::add_material FltMaterial material  ) 
 

Definition at line 959 of file fltHeader.cxx.

References FltMaterial::_material_index, and _materials.

Referenced by extract_14_material_palette(), and extract_material().

void FltHeader::add_texture FltTexture texture  ) 
 

Definition at line 1020 of file fltHeader.cxx.

References _textures, and texture.

Referenced by extract_texture().

void FltHeader::add_vertex FltVertex vertex  ) 
 

Definition at line 568 of file fltHeader.cxx.

References _unique_vertices, _vertex_lookups_stale, _vertices, and nassertv.

void FltHeader::apply_converted_filenames  )  [virtual]
 

Reimplemented from FltRecord.

Definition at line 123 of file fltHeader.cxx.

References _textures, FltRecord::apply_converted_filenames(), and texture.

bool FltHeader::build_record FltRecordWriter writer  )  const [protected, virtual]
 

Reimplemented from FltBeadID.

Definition at line 1349 of file fltHeader.cxx.

References _database_origin, _delta_x, _delta_y, _delta_z, _earth_model, _edit_revision_level, _flags, _format_revision_level, _lambert_lower_lat, _lambert_upper_lat, _last_revision, _ne_lat, _ne_long, _next_adaptive_id, _next_bsp_id, _next_cat_id, _next_clip_id, _next_curve_id, _next_dof_id, _next_face_id, _next_group_id, _next_light_id, _next_lod_id, _next_mesh_id, _next_object_id, _next_path_id, _next_road_id, _next_sound_id, _next_switch_id, _next_text_id, _origin_lat, _origin_long, _projection_type, _radius, _sw_lat, _sw_long, _sw_x, _sw_y, _texwhite_new, _unit_multiplier, _vertex_storage_type, _vertex_units, Datagram::add_be_float64(), Datagram::add_be_int16(), Datagram::add_be_int32(), Datagram::add_be_uint32(), Datagram::add_fixed_string(), Datagram::add_int8(), FltBeadID::build_record(), FO_header, get_flt_version(), Datagram::pad_bytes(), and writer().

bool FltHeader::check_version  )  const
 

Definition at line 408 of file fltHeader.cxx.

References get_flt_version(), max_flt_version(), min_flt_version(), and nout.

void FltHeader::clear_instances  ) 
 

Definition at line 496 of file fltHeader.cxx.

References _instances.

void FltHeader::clear_light_sources  ) 
 

Definition at line 1068 of file fltHeader.cxx.

References _light_sources.

void FltHeader::clear_materials  ) 
 

Definition at line 946 of file fltHeader.cxx.

References _materials.

void FltHeader::clear_textures  ) 
 

Definition at line 1007 of file fltHeader.cxx.

References _textures.

void FltHeader::clear_vertices  ) 
 

Definition at line 552 of file fltHeader.cxx.

References _offsets_by_vertex, _unique_vertices, _vertex_lookups_stale, _vertices, and _vertices_by_offset.

Referenced by extract_ancillary().

Filename FltHeader::convert_path const Filename orig_filename,
const DSearchPath additional_path = DSearchPath()
 

Definition at line 179 of file fltHeader.cxx.

References _flt_filename, DSearchPath::append_directory(), DSearchPath::append_path(), Filename::empty(), and Filename::get_dirname().

Referenced by FltTexture::extract_record(), and FltExternalReference::extract_record().

bool FltHeader::extract_14_material_palette FltRecordReader reader  )  [private]
 

Definition at line 1565 of file fltHeader.cxx.

References _got_14_material_palette, _materials, add_material(), FltRecord::check_remaining_size(), FO_14_material_palette, DatagramIterator::get_remaining_size(), nassertr, nout, PT(), and reader().

Referenced by extract_ancillary().

bool FltHeader::extract_ancillary FltRecordReader reader  )  [protected, virtual]
 

Reimplemented from FltBeadID.

Definition at line 1299 of file fltHeader.cxx.

References _current_vertex_offset, clear_vertices(), extract_14_material_palette(), FltBeadID::extract_ancillary(), extract_color_palette(), extract_eyepoint_palette(), extract_light_source(), extract_material(), extract_texture(), extract_texture_map(), extract_vertex(), FO_14_material_palette, FO_15_material, FO_color_palette, FO_eyepoint_palette, FO_light_definition, FO_texture, FO_texture_map_palette, FO_vertex_c, FO_vertex_cn, FO_vertex_cnu, FO_vertex_cu, FO_vertex_palette, and reader().

bool FltHeader::extract_color_palette FltRecordReader reader  )  [private]
 

Definition at line 1500 of file fltHeader.cxx.

References _color_names, _colors, _got_color_palette, FltRecord::check_remaining_size(), FltPackedColor::extract_record(), FO_color_palette, DatagramIterator::get_be_int16(), DatagramIterator::get_be_uint16(), DatagramIterator::get_fixed_string(), DatagramIterator::get_remaining_size(), nassertr, nout, reader(), and DatagramIterator::skip_bytes().

Referenced by extract_ancillary().

bool FltHeader::extract_eyepoint_palette FltRecordReader reader  )  [private]
 

Definition at line 1653 of file fltHeader.cxx.

References _eyepoints, _got_eyepoint_trackplane_palette, _trackplanes, FltRecord::check_remaining_size(), FltTrackplane::extract_record(), FltEyepoint::extract_record(), FO_eyepoint_palette, get_flt_version(), get_num_eyepoints(), get_num_trackplanes(), nassertr, reader(), and DatagramIterator::skip_bytes().

Referenced by extract_ancillary().

bool FltHeader::extract_light_source FltRecordReader reader  )  [private]
 

Definition at line 1637 of file fltHeader.cxx.

References add_light_source(), FltLightSourceDefinition::extract_record(), and reader().

Referenced by extract_ancillary().

bool FltHeader::extract_material FltRecordReader reader  )  [private]
 

Definition at line 1549 of file fltHeader.cxx.

References add_material(), PT(), and reader().

Referenced by extract_ancillary().

bool FltHeader::extract_record FltRecordReader reader  )  [protected, virtual]
 

Reimplemented from FltBeadID.

Definition at line 1209 of file fltHeader.cxx.

References _database_origin, _delta_x, _delta_y, _delta_z, _earth_model, _edit_revision_level, _flags, _format_revision_level, _lambert_lower_lat, _lambert_upper_lat, _last_revision, _ne_lat, _ne_long, _next_adaptive_id, _next_bsp_id, _next_cat_id, _next_clip_id, _next_curve_id, _next_dof_id, _next_face_id, _next_group_id, _next_light_id, _next_lod_id, _next_mesh_id, _next_object_id, _next_path_id, _next_road_id, _next_sound_id, _next_switch_id, _next_text_id, _origin_lat, _origin_long, _projection_type, _radius, _sw_lat, _sw_long, _sw_x, _sw_y, _texwhite_new, _unit_multiplier, _vertex_storage_type, _vertex_units, FltRecord::check_remaining_size(), FltBeadID::extract_record(), FO_header, DatagramIterator::get_be_float64(), DatagramIterator::get_be_int16(), DatagramIterator::get_be_int32(), DatagramIterator::get_be_uint32(), DatagramIterator::get_fixed_string(), get_flt_version(), DatagramIterator::get_int8(), DatagramIterator::get_remaining_size(), nassertr, reader(), and DatagramIterator::skip_bytes().

bool FltHeader::extract_texture FltRecordReader reader  )  [private]
 

Definition at line 1599 of file fltHeader.cxx.

References add_texture(), reader(), and texture.

Referenced by extract_ancillary().

bool FltHeader::extract_texture_map FltRecordReader reader  )  [private]
 

Definition at line 1617 of file fltHeader.cxx.

References FltRecord::add_ancillary(), FltUnsupportedRecord::extract_record(), and reader().

Referenced by extract_ancillary().

bool FltHeader::extract_vertex FltRecordReader reader  )  [private]
 

Definition at line 1478 of file fltHeader.cxx.

References _current_vertex_offset, _offsets_by_vertex, _unique_vertices, _vertices, _vertices_by_offset, FltVertex::extract_record(), and reader().

Referenced by extract_ancillary().

virtual TypeHandle FltHeader::force_init_type void   )  [inline, virtual]
 

Reimplemented from FltBeadID.

Definition at line 332 of file fltHeader.h.

References get_class_type(), and init_type().

FltHeader::AttrUpdate FltHeader::get_auto_attr_update  )  const
 

Definition at line 337 of file fltHeader.cxx.

References _auto_attr_update.

Referenced by FltTexture::build_record().

TypeHandle FltHeader::get_class_type void   )  [inline, static]
 

Reimplemented from FltBeadID.

Definition at line 333 of file fltHeader.h.

References _type_handle.

Referenced by force_init_type(), and get_type().

int FltHeader::get_closest_color Colorf  color  )  const
 

Definition at line 720 of file fltHeader.cxx.

References _colors, Colorf, dot(), get_num_color_entries(), get_num_color_shades(), nassertr, and scale.

int FltHeader::get_closest_rgb RGBColorf  color  )  const
 

Definition at line 785 of file fltHeader.cxx.

References _colors, dot(), get_num_color_entries(), get_num_color_shades(), nassertr, RGBColorf, and scale.

Referenced by FltLocalVertexPool::build_record().

Colorf FltHeader::get_color int  color_index,
bool  use_packed_color,
const FltPackedColor packed_color,
int  transparency
 

Definition at line 873 of file fltHeader.cxx.

References FltPackedColor::_b, FltPackedColor::_g, FltPackedColor::_r, Colorf, and get_color().

Colorf FltHeader::get_color int  color_index  )  const
 

Definition at line 649 of file fltHeader.cxx.

References _colors, Colorf, get_num_color_shades(), get_num_colors(), index, level, and nassertr.

Referenced by FltGeometry::get_alt_color(), FltVertex::get_color(), and get_color().

string FltHeader::get_color_name int  color_index  )  const
 

Definition at line 703 of file fltHeader.cxx.

References _color_names.

FltEyepoint * FltHeader::get_eyepoint int  n  ) 
 

Definition at line 1141 of file fltHeader.cxx.

References _eyepoints, get_num_eyepoints(), n, nassertr, and NULL.

const Filename & FltHeader::get_flt_filename  )  const
 

Definition at line 207 of file fltHeader.cxx.

References _flt_filename.

int FltHeader::get_flt_version  )  const
 

Definition at line 349 of file fltHeader.cxx.

References _format_revision_level.

Referenced by FltVertex::build_record(), build_record(), FltGeometry::build_record(), FltRecord::check_remaining_size(), check_version(), extract_eyepoint_palette(), FltVertex::extract_record(), FltTexture::extract_record(), extract_record(), FltGroup::extract_record(), FltGeometry::extract_record(), FltVertex::get_record_length(), and write_material_palette().

FltInstanceDefinition * FltHeader::get_instance int  instance_index  )  const
 

Definition at line 481 of file fltHeader.cxx.

References _instances, and NULL.

Referenced by FltInstanceRef::get_instance(), FltInstanceRef::write(), and FltRecordWriter::write_instance_def().

FltLightSourceDefinition * FltHeader::get_light_source int  light_index  )  const
 

Definition at line 1053 of file fltHeader.cxx.

References _light_sources, and NULL.

FltMaterial * FltHeader::get_material int  material_index  )  const
 

Definition at line 931 of file fltHeader.cxx.

References _materials, and NULL.

int FltHeader::get_num_color_entries  )  const
 

Definition at line 846 of file fltHeader.cxx.

References _colors.

Referenced by get_closest_color(), and get_closest_rgb().

int FltHeader::get_num_color_shades  )  const
 

Definition at line 859 of file fltHeader.cxx.

Referenced by get_closest_color(), get_closest_rgb(), get_color(), get_num_colors(), and get_rgb().

int FltHeader::get_num_colors  )  const
 

Definition at line 637 of file fltHeader.cxx.

References _colors, and get_num_color_shades().

Referenced by get_color(), and get_rgb().

int FltHeader::get_num_eyepoints  )  const
 

Definition at line 1130 of file fltHeader.cxx.

Referenced by extract_eyepoint_palette(), get_eyepoint(), and write_eyepoint_palette().

int FltHeader::get_num_trackplanes  )  const
 

Definition at line 1154 of file fltHeader.cxx.

Referenced by extract_eyepoint_palette(), get_trackplane(), and write_eyepoint_palette().

int FltHeader::get_num_vertices  )  const
 

Definition at line 531 of file fltHeader.cxx.

References _vertices.

int FltHeader::get_offset_by_vertex FltVertex vertex  ) 
 

Definition at line 609 of file fltHeader.cxx.

References _offsets_by_vertex, nout, and update_vertex_lookups().

Referenced by FltVertexList::build_record().

const PathReplace * FltHeader::get_path_replace  )  const
 

Definition at line 167 of file fltHeader.cxx.

PathReplace * FltHeader::get_path_replace  ) 
 

Definition at line 154 of file fltHeader.cxx.

RGBColorf FltHeader::get_rgb int  color_index,
bool  use_packed_color,
const FltPackedColor packed_color
 

Definition at line 900 of file fltHeader.cxx.

References FltPackedColor::_b, FltPackedColor::_g, FltPackedColor::_r, get_rgb(), and RGBColorf.

RGBColorf FltHeader::get_rgb int  color_index  )  const
 

Definition at line 671 of file fltHeader.cxx.

References _colors, get_num_color_shades(), get_num_colors(), index, level, nassertr, and RGBColorf.

Referenced by FltGeometry::get_alt_rgb(), FltGeometry::get_color(), FltVertex::get_rgb(), get_rgb(), and FltGeometry::get_rgb().

FltTexture * FltHeader::get_texture int  texture_index  )  const
 

Definition at line 992 of file fltHeader.cxx.

References _textures, and NULL.

FltTrackplane * FltHeader::get_trackplane int  n  ) 
 

Definition at line 1165 of file fltHeader.cxx.

References _trackplanes, get_num_trackplanes(), n, nassertr, and NULL.

virtual TypeHandle FltHeader::get_type void   )  const [inline, virtual]
 

Reimplemented from FltBeadID.

Definition at line 329 of file fltHeader.h.

References get_class_type().

DistanceUnit FltHeader::get_units  )  const
 

Definition at line 441 of file fltHeader.cxx.

References DU_feet, DU_inches, DU_invalid, DU_kilometers, DU_meters, DU_nautical_miles, U_feet, U_inches, U_kilometers, U_meters, and U_nautical_miles.

FltVertex * FltHeader::get_vertex int  n  )  const
 

Definition at line 541 of file fltHeader.cxx.

References _vertices, n, and nassertr.

FltVertex * FltHeader::get_vertex_by_offset int  offset  ) 
 

Definition at line 586 of file fltHeader.cxx.

References _vertices_by_offset, nout, NULL, and update_vertex_lookups().

Referenced by FltVertexList::extract_record().

bool FltHeader::got_eyepoint_trackplane_palette  )  const
 

Definition at line 1104 of file fltHeader.cxx.

References _got_eyepoint_trackplane_palette.

bool FltHeader::has_color_name int  color_index  )  const
 

Definition at line 692 of file fltHeader.cxx.

References _color_names.

bool FltHeader::has_instance int  instance_index  )  const
 

Definition at line 470 of file fltHeader.cxx.

References _instances.

bool FltHeader::has_light_source int  light_index  )  const
 

Definition at line 1042 of file fltHeader.cxx.

References _light_sources.

bool FltHeader::has_material int  material_index  )  const
 

Definition at line 920 of file fltHeader.cxx.

References _materials.

bool FltHeader::has_texture int  texture_index  )  const
 

Definition at line 981 of file fltHeader.cxx.

References _textures.

void FltHeader::init_type void   )  [inline, static]
 

Reimplemented from FltBeadID.

Definition at line 336 of file fltHeader.h.

References _type_handle, FltBeadID::get_class_type(), FltBeadID::init_type(), and register_type().

Referenced by force_init_type(), and init_libflt().

int FltHeader::max_flt_version  )  [static]
 

Definition at line 393 of file fltHeader.cxx.

Referenced by FltRecord::check_remaining_size(), check_version(), and FltTrans::run().

int FltHeader::min_flt_version  )  [static]
 

Definition at line 381 of file fltHeader.cxx.

Referenced by check_version(), and FltTrans::run().

FltHeader::PT PathReplace   )  [private]
 

Referenced by extract_14_material_palette(), extract_material(), and write_material_palette().

FltError FltHeader::read_flt istream &  in  ) 
 

Definition at line 240 of file fltHeader.cxx.

References assert, FE_empty_file, FE_end_of_file, FE_extra_data, FE_ok, flt_error_abort, FltError, FltRecord::read_record_and_children(), and reader().

FltError FltHeader::read_flt Filename  filename  ) 
 

Definition at line 219 of file fltHeader.cxx.

References _flt_filename, assert, FE_could_not_open, flt_error_abort, and Filename::set_binary().

void FltHeader::remove_instance int  instance_index  ) 
 

Definition at line 521 of file fltHeader.cxx.

References _instances.

void FltHeader::remove_light_source int  light_index  ) 
 

Definition at line 1092 of file fltHeader.cxx.

References _light_sources.

void FltHeader::remove_material int  material_index  ) 
 

Definition at line 970 of file fltHeader.cxx.

References _materials.

void FltHeader::remove_texture int  texture_index  ) 
 

Definition at line 1031 of file fltHeader.cxx.

References _textures.

void FltHeader::set_auto_attr_update AttrUpdate  attr  ) 
 

Definition at line 326 of file fltHeader.cxx.

References _auto_attr_update.

void FltHeader::set_eyepoint_trackplane_palette bool  flag  ) 
 

Definition at line 1118 of file fltHeader.cxx.

References _got_eyepoint_trackplane_palette.

void FltHeader::set_flt_filename const Filename flt_filename  ) 
 

Definition at line 196 of file fltHeader.cxx.

References _flt_filename.

void FltHeader::set_flt_version int  version  ) 
 

Definition at line 365 of file fltHeader.cxx.

References _format_revision_level.

void FltHeader::set_path_replace PathReplace path_replace  ) 
 

Definition at line 141 of file fltHeader.cxx.

int FltHeader::update_vertex_lookups  )  [private]
 

Definition at line 1182 of file fltHeader.cxx.

References _offsets_by_vertex, _vertex_lookups_stale, _vertices, _vertices_by_offset, and FltVertex::get_record_length().

Referenced by get_offset_by_vertex(), and get_vertex_by_offset().

FltError FltHeader::write_ancillary FltRecordWriter writer  )  const [protected, virtual]
 

Reimplemented from FltBeadID.

Definition at line 1434 of file fltHeader.cxx.

References FE_ok, FltError, FltBeadID::write_ancillary(), write_color_palette(), write_eyepoint_palette(), write_light_source_palette(), write_material_palette(), write_texture_palette(), write_vertex_palette(), and writer().

FltError FltHeader::write_color_palette FltRecordWriter writer  )  const [private]
 

Definition at line 1724 of file fltHeader.cxx.

References _color_names, _colors, Datagram::add_be_uint16(), Datagram::add_fixed_string(), assert, FltPackedColor::build_record(), FE_invalid_record, flt_error_abort, FO_color_palette, Datagram::pad_bytes(), and writer().

Referenced by write_ancillary().

FltError FltHeader::write_eyepoint_palette FltRecordWriter writer  )  const [private]
 

Definition at line 1877 of file fltHeader.cxx.

References _eyepoints, _got_eyepoint_trackplane_palette, _trackplanes, assert, FltTrackplane::build_record(), FltEyepoint::build_record(), FE_bad_data, FE_ok, flt_error_abort, FO_eyepoint_palette, get_num_eyepoints(), get_num_trackplanes(), Datagram::pad_bytes(), and writer().

Referenced by write_ancillary().

FltError FltHeader::write_flt ostream &  out  ) 
 

Definition at line 292 of file fltHeader.cxx.

References assert, FE_write_error, flt_error_abort, FltError, FltRecord::write_record_and_children(), and writer().

FltError FltHeader::write_flt Filename  filename  ) 
 

Definition at line 272 of file fltHeader.cxx.

References assert, FE_could_not_open, flt_error_abort, Filename::open_write(), and Filename::set_binary().

FltError FltHeader::write_light_source_palette FltRecordWriter writer  )  const [private]
 

Definition at line 1854 of file fltHeader.cxx.

References _light_sources, FltLightSourceDefinition::build_record(), FE_ok, FltError, and writer().

Referenced by write_ancillary().

FltError FltHeader::write_material_palette FltRecordWriter writer  )  const [private]
 

Definition at line 1776 of file fltHeader.cxx.

References FltRecord::_header, _materials, FltMaterial::build_14_record(), FltMaterial::build_record(), FE_internal, FE_ok, FltError, FO_14_material_palette, get_flt_version(), index, nassertr, PT(), and writer().

Referenced by write_ancillary().

FltError FltHeader::write_texture_palette FltRecordWriter writer  )  const [private]
 

Definition at line 1832 of file fltHeader.cxx.

References _textures, FE_ok, FltError, texture, and writer().

Referenced by write_ancillary().

FltError FltHeader::write_vertex_palette FltRecordWriter writer  )  const [private]
 

Definition at line 1692 of file fltHeader.cxx.

References _vertices, Datagram::add_be_int32(), FltVertex::build_record(), FE_ok, FltError, FO_vertex_palette, and writer().

Referenced by write_ancillary().


Member Data Documentation

AttrUpdate FltHeader::_auto_attr_update [private]
 

Definition at line 285 of file fltHeader.h.

Referenced by FltHeader(), get_auto_attr_update(), and set_auto_attr_update().

ColorNames FltHeader::_color_names [private]
 

Definition at line 275 of file fltHeader.h.

Referenced by extract_color_palette(), get_color_name(), has_color_name(), and write_color_palette().

Colors FltHeader::_colors [private]
 

Definition at line 274 of file fltHeader.h.

Referenced by extract_color_palette(), get_closest_color(), get_closest_rgb(), get_color(), get_num_color_entries(), get_num_colors(), get_rgb(), and write_color_palette().

int FltHeader::_current_vertex_offset [private]
 

Definition at line 267 of file fltHeader.h.

Referenced by extract_ancillary(), extract_vertex(), and FltHeader().

DatabaseOrigin FltHeader::_database_origin
 

Definition at line 136 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_delta_x
 

Definition at line 138 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_delta_y
 

Definition at line 138 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_delta_z
 

Definition at line 155 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

EarthModel FltHeader::_earth_model
 

Definition at line 152 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_edit_revision_level
 

Definition at line 123 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

FltEyepoint FltHeader::_eyepoints[10] [private]
 

Definition at line 297 of file fltHeader.h.

Referenced by extract_eyepoint_palette(), get_eyepoint(), and write_eyepoint_palette().

unsigned int FltHeader::_flags
 

Definition at line 132 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

Filename FltHeader::_flt_filename [private]
 

Definition at line 302 of file fltHeader.h.

Referenced by convert_path(), get_flt_filename(), read_flt(), and set_flt_filename().

int FltHeader::_format_revision_level
 

Definition at line 122 of file fltHeader.h.

Referenced by build_record(), extract_record(), FltHeader(), get_flt_version(), and set_flt_version().

bool FltHeader::_got_14_material_palette [private]
 

Definition at line 279 of file fltHeader.h.

Referenced by extract_14_material_palette(), and FltHeader().

bool FltHeader::_got_color_palette [private]
 

Definition at line 271 of file fltHeader.h.

Referenced by extract_color_palette(), and FltHeader().

bool FltHeader::_got_eyepoint_trackplane_palette [private]
 

Definition at line 296 of file fltHeader.h.

Referenced by extract_eyepoint_palette(), FltHeader(), got_eyepoint_trackplane_palette(), set_eyepoint_trackplane_palette(), and write_eyepoint_palette().

Instances FltHeader::_instances [private]
 

Definition at line 246 of file fltHeader.h.

Referenced by add_instance(), clear_instances(), get_instance(), has_instance(), and remove_instance().

double FltHeader::_lambert_lower_lat
 

Definition at line 148 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_lambert_upper_lat
 

Definition at line 148 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

string FltHeader::_last_revision
 

Definition at line 124 of file fltHeader.h.

Referenced by build_record(), and extract_record().

LightSources FltHeader::_light_sources [private]
 

Definition at line 292 of file fltHeader.h.

Referenced by add_light_source(), clear_light_sources(), get_light_source(), has_light_source(), remove_light_source(), and write_light_source_palette().

Materials FltHeader::_materials [private]
 

Definition at line 281 of file fltHeader.h.

Referenced by add_material(), clear_materials(), extract_14_material_palette(), get_material(), has_material(), remove_material(), and write_material_palette().

double FltHeader::_ne_lat
 

Definition at line 146 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_ne_long
 

Definition at line 146 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_adaptive_id
 

Definition at line 153 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_bsp_id
 

Definition at line 143 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_cat_id
 

Definition at line 151 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_clip_id
 

Definition at line 141 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_curve_id
 

Definition at line 154 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_dof_id
 

Definition at line 134 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_face_id
 

Definition at line 128 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_group_id
 

Definition at line 125 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_light_id
 

Definition at line 149 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_lod_id
 

Definition at line 126 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_mesh_id
 

Definition at line 157 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_object_id
 

Definition at line 127 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_path_id
 

Definition at line 140 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_road_id
 

Definition at line 150 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_sound_id
 

Definition at line 139 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_switch_id
 

Definition at line 144 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

int FltHeader::_next_text_id
 

Definition at line 142 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

OffsetsByVertex FltHeader::_offsets_by_vertex [private]
 

Definition at line 261 of file fltHeader.h.

Referenced by clear_vertices(), extract_vertex(), get_offset_by_vertex(), and update_vertex_lookups().

double FltHeader::_origin_lat
 

Definition at line 147 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_origin_long
 

Definition at line 147 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

ProjectionType FltHeader::_projection_type
 

Definition at line 133 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_radius
 

Definition at line 156 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_sw_lat
 

Definition at line 145 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_sw_long
 

Definition at line 145 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_sw_x
 

Definition at line 137 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

double FltHeader::_sw_y
 

Definition at line 137 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

Textures FltHeader::_textures [private]
 

Definition at line 287 of file fltHeader.h.

Referenced by add_texture(), apply_converted_filenames(), clear_textures(), get_texture(), has_texture(), remove_texture(), and write_texture_palette().

bool FltHeader::_texwhite_new
 

Definition at line 131 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

FltTrackplane FltHeader::_trackplanes[10] [private]
 

Definition at line 298 of file fltHeader.h.

Referenced by extract_eyepoint_palette(), get_trackplane(), and write_eyepoint_palette().

TypeHandle FltHeader::_type_handle [static, private]
 

Reimplemented from FltBeadID.

Definition at line 30 of file fltHeader.cxx.

Referenced by get_class_type(), and init_type().

UniqueVertices FltHeader::_unique_vertices [private]
 

Definition at line 259 of file fltHeader.h.

Referenced by add_vertex(), clear_vertices(), and extract_vertex().

int FltHeader::_unit_multiplier
 

Definition at line 129 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

bool FltHeader::_vertex_lookups_stale [private]
 

Definition at line 263 of file fltHeader.h.

Referenced by add_vertex(), clear_vertices(), FltHeader(), and update_vertex_lookups().

VertexStorageType FltHeader::_vertex_storage_type
 

Definition at line 135 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

Units FltHeader::_vertex_units
 

Definition at line 130 of file fltHeader.h.

Referenced by build_record(), extract_record(), and FltHeader().

Vertices FltHeader::_vertices [private]
 

Definition at line 258 of file fltHeader.h.

Referenced by add_vertex(), clear_vertices(), extract_vertex(), get_num_vertices(), get_vertex(), update_vertex_lookups(), and write_vertex_palette().

VerticesByOffset FltHeader::_vertices_by_offset [private]
 

Definition at line 260 of file fltHeader.h.

Referenced by clear_vertices(), extract_vertex(), get_vertex_by_offset(), and update_vertex_lookups().


The documentation for this class was generated from the following files:
Generated on Fri Apr 18 01:00:58 2003 for Panda-Tool by doxygen1.3