Panda3D
 All Classes Functions Variables Enumerations
eggToSomethingConverter.cxx
1 // Filename: eggToSomethingConverter.cxx
2 // Created by: drose (26Apr01)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 #include "eggToSomethingConverter.h"
16 
17 #include "eggData.h"
18 
19 ////////////////////////////////////////////////////////////////////
20 // Function: EggToSomethingConverter::Constructor
21 // Access: Public
22 // Description:
23 ////////////////////////////////////////////////////////////////////
24 EggToSomethingConverter::
25 EggToSomethingConverter() {
26  _egg_data = (EggData *)NULL;
27  _error = false;
28 }
29 
30 ////////////////////////////////////////////////////////////////////
31 // Function: EggToSomethingConverter::Copy Constructor
32 // Access: Public
33 // Description:
34 ////////////////////////////////////////////////////////////////////
35 EggToSomethingConverter::
36 EggToSomethingConverter(const EggToSomethingConverter &copy) {
37  _egg_data = (EggData *)NULL;
38  _error = false;
39 }
40 
41 ////////////////////////////////////////////////////////////////////
42 // Function: EggToSomethingConverter::Destructor
43 // Access: Public, Virtual
44 // Description:
45 ////////////////////////////////////////////////////////////////////
46 EggToSomethingConverter::
47 ~EggToSomethingConverter() {
49 }
50 
51 ////////////////////////////////////////////////////////////////////
52 // Function: EggToSomethingConverter::set_egg_data
53 // Access: Public
54 // Description: Sets the egg data that will be filled in when
55 // convert_file() is called. This must be called before
56 // convert_file().
57 ////////////////////////////////////////////////////////////////////
59 set_egg_data(EggData *egg_data) {
60  _egg_data = egg_data;
61 }
62 
63 ////////////////////////////////////////////////////////////////////
64 // Function: EggToSomethingConverter::get_additional_extensions
65 // Access: Public, Virtual
66 // Description: Returns a space-separated list of extension, in
67 // addition to the one returned by get_extension(), that
68 // are recognized by this converter.
69 ////////////////////////////////////////////////////////////////////
72  return string();
73 }
74 
75 ////////////////////////////////////////////////////////////////////
76 // Function: EggToSomethingConverter::supports_compressed
77 // Access: Published, Virtual
78 // Description: Returns true if this file type can transparently save
79 // compressed files (with a .pz extension), false
80 // otherwise.
81 ////////////////////////////////////////////////////////////////////
84  return false;
85 }
This is the primary interface into all the egg data, and the root of the egg file structure...
Definition: eggData.h:41
This is a base class for a family of converter classes that manage a conversion from egg format to so...
virtual bool supports_compressed() const
Returns true if this file type can transparently save compressed files (with a .pz extension)...
void set_egg_data(EggData *egg_data)
Sets the egg data that will be filled in when convert_file() is called.
virtual string get_additional_extensions() const
Returns a space-separated list of extension, in addition to the one returned by get_extension(), that are recognized by this converter.
void clear_egg_data()
Sets the EggData to NULL and makes the converter invalid.