Panda3D
pandatool
src
fltprogs
eggToFlt.h
Go to the documentation of this file.
1
/**
2
* PANDA 3D SOFTWARE
3
* Copyright (c) Carnegie Mellon University. All rights reserved.
4
*
5
* All use of this software is subject to the terms of the revised BSD
6
* license. You should have received a copy of this license along
7
* with this source code in a file named "LICENSE."
8
*
9
* @file eggToFlt.h
10
* @author drose
11
* @date 2003-10-01
12
*/
13
14
#ifndef EGGTOFLT_H
15
#define EGGTOFLT_H
16
17
#include "
pandatoolbase.h
"
18
19
#include "
eggToSomething.h
"
20
#include "
fltHeader.h
"
21
#include "
fltGeometry.h
"
22
#include "
pointerTo.h
"
23
#include "
pmap.h
"
24
#include "
vector_string.h
"
25
26
class
EggGroup
;
27
class
EggVertex
;
28
class
EggPrimitive
;
29
class
EggTexture
;
30
class
EggTransform
;
31
class
FltVertex
;
32
class
FltBead
;
33
class
FltTexture
;
34
35
/**
36
* A program to read an egg file and write a flt file.
37
*/
38
class
EggToFlt
:
public
EggToSomething
{
39
public
:
40
EggToFlt
();
41
42
void
run();
43
44
private
:
45
static
bool
dispatch_attr(
const
std::string &opt,
const
std::string &arg,
void
*var);
46
47
void
traverse(
EggNode
*egg_node,
FltBead
*flt_node,
48
FltGeometry::BillboardType billboard);
49
void
convert_primitive(
EggPrimitive
*egg_primitive,
FltBead
*flt_node,
50
FltGeometry::BillboardType billboard);
51
void
convert_group(
EggGroup
*egg_group,
FltBead
*flt_node,
52
FltGeometry::BillboardType billboard);
53
void
apply_transform(
EggTransform
*egg_transform,
FltBead
*flt_node);
54
void
apply_egg_syntax(
const
std::string &egg_syntax,
FltRecord
*flt_record);
55
FltVertex
*get_flt_vertex(
EggVertex
*egg_vertex,
EggNode
*context);
56
FltTexture
*get_flt_texture(
EggTexture
*egg_texture);
57
58
FltHeader::AttrUpdate _auto_attr_update;
59
60
PT(
FltHeader
) _flt_header;
61
62
typedef
pmap<EggVertex *, FltVertex *>
VertexMap
;
63
typedef
pmap<const LMatrix4d *, VertexMap>
VertexMapPerFrame
;
64
VertexMapPerFrame
_vertex_map_per_frame;
65
66
typedef
pmap<Filename, FltTexture *>
TextureMap
;
67
TextureMap
_texture_map;
68
};
69
70
#endif
EggToFlt
A program to read an egg file and write a flt file.
Definition:
eggToFlt.h:38
FltTexture
Represents a single texture in the texture palette.
Definition:
fltTexture.h:27
pmap
This is our own Panda specialization on the default STL map.
Definition:
pmap.h:49
fltHeader.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
EggPrimitive
A base class for any of a number of kinds of geometry primitives: polygons, point lights,...
Definition:
eggPrimitive.h:49
EggToSomething
This is the general base class for a file-converter program that reads some model file format and gen...
Definition:
eggToSomething.h:26
pmap.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
FltHeader
This is the first bead in the file, the top of the bead hierarchy, and the primary interface to readi...
Definition:
fltHeader.h:44
fltGeometry.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
EggVertex
Any one-, two-, three-, or four-component vertex, possibly with attributes such as a normal.
Definition:
eggVertex.h:39
FltRecord
The base class for all kinds of records in a MultiGen OpenFlight file.
Definition:
fltRecord.h:36
FltVertex
Represents a single vertex in the vertex palette.
Definition:
fltVertex.h:32
vector_string.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
EggTexture
Defines a texture map that may be applied to geometry.
Definition:
eggTexture.h:30
pandatoolbase.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
eggToSomething.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
EggNode
A base class for things that may be directly added into the egg hierarchy.
Definition:
eggNode.h:35
EggGroup
The main glue of the egg hierarchy, this corresponds to the <Group>, <Instance>, and <Joint> type nod...
Definition:
eggGroup.h:34
FltBead
A base class for any of a broad family of flt records that represent particular beads in the hierarch...
Definition:
fltBead.h:29
pointerTo.h
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
EggTransform
This represents the <Transform> entry of a group or texture node: a list of component transform opera...
Definition:
eggTransform.h:29
Generated on Sun Dec 27 2020 13:23:20 for Panda3D by
1.8.20