Panda3D
Loading...
Searching...
No Matches
eggReader.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 eggReader.h
10 * @author drose
11 * @date 2000-02-14
12 */
13
14#ifndef EGGREADER_H
15#define EGGREADER_H
16
17#include "pandatoolbase.h"
18
19#include "eggSingleBase.h"
20#include "filename.h"
21
22class PNMFileType;
23
24/**
25 * This is the base class for a program that reads egg files, but doesn't
26 * write an egg file.
27 */
28class EggReader : virtual public EggSingleBase {
29public:
30 EggReader();
31
33 void add_delod_options(double default_delod = -1.0);
34
35 virtual EggReader *as_reader();
36 virtual void pre_process_egg_file();
37
38protected:
39 virtual bool handle_args(Args &args);
40 virtual bool post_command_line();
41
42 bool do_reader_options();
43
44private:
45 bool copy_textures();
46 bool do_delod(EggNode *node);
47
48protected:
49 bool _force_complete;
50
51private:
52 Filename _tex_dirname;
53 bool _got_tex_dirname;
54 std::string _tex_extension;
55 bool _got_tex_extension;
56 PNMFileType *_tex_type;
57 double _delod;
58};
59
60#endif
A base class for things that may be directly added into the egg hierarchy.
Definition eggNode.h:36
This is the base class for a program that reads egg files, but doesn't write an egg file.
Definition eggReader.h:28
virtual void pre_process_egg_file()
Performs any processing of the egg file that is appropriate after reading it in.
void add_texture_options()
Adds -td, -te, etc.
Definition eggReader.cxx:70
virtual EggReader * as_reader()
Returns this object as an EggReader pointer, if it is in fact an EggReader, or NULL if it is not.
void add_delod_options(double default_delod=-1.0)
Adds -delod as a valid option for this program.
This specialization of EggBase is intended for programs that read and/or write a single egg file.
The name of a file, such as a texture file or an Egg file.
Definition filename.h:44
This is the base class of a family of classes that represent particular image file types that PNMImag...
Definition pnmFileType.h:32
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.