Panda3D
|
Operates on a pfm file. More...
#include "pfmTrans.h"
Public Member Functions | |
void | add_transform_options () |
Adds -TS, -TT, etc. | |
bool | process_pfm (const Filename &input_filename, PfmFile &file) |
Handles a single pfm file. | |
void | run () |
Protected Member Functions | |
virtual bool | handle_args (Args &args) |
Does something with the additional arguments on the command line (after all the -options have been parsed). | |
bool | ns_dispatch_rotate_axis (const string &opt, const string &arg, void *var) |
Handles -TA, which specifies a rotate transform about an arbitrary axis. | |
bool | ns_dispatch_rotate_xyz (const string &opt, const string &arg, void *var) |
Handles -TR, which specifies a rotate transform about the three cardinal axes. | |
Static Protected Member Functions | |
static bool | dispatch_rotate_axis (ProgramBase *self, const string &opt, const string &arg, void *var) |
Handles -TA, which specifies a rotate transform about an arbitrary axis. | |
static bool | dispatch_rotate_xyz (ProgramBase *self, const string &opt, const string &arg, void *var) |
Handles -TR, which specifies a rotate transform about the three cardinal axes. | |
static bool | dispatch_scale (const string &opt, const string &arg, void *var) |
Handles -TS, which specifies a scale transform. | |
static bool | dispatch_translate (const string &opt, const string &arg, void *var) |
Handles -TT, which specifies a translate transform. |
Operates on a pfm file.
Definition at line 31 of file pfmTrans.h.
void PfmTrans::add_transform_options | ( | ) |
Adds -TS, -TT, etc.
as valid options for this program. If the user specifies one of the options on the command line, the data will be transformed when the egg file is written out.
Definition at line 191 of file pfmTrans.cxx.
References ProgramBase::add_option(), dispatch_rotate_axis(), dispatch_rotate_xyz(), dispatch_scale(), and dispatch_translate().
bool PfmTrans::dispatch_rotate_axis | ( | ProgramBase * | self, |
const string & | opt, | ||
const string & | arg, | ||
void * | var | ||
) | [static, protected] |
Handles -TA, which specifies a rotate transform about an arbitrary axis.
Var is an LMatrix4.
Definition at line 351 of file pfmTrans.cxx.
References ns_dispatch_rotate_axis().
Referenced by add_transform_options().
bool PfmTrans::dispatch_rotate_xyz | ( | ProgramBase * | self, |
const string & | opt, | ||
const string & | arg, | ||
void * | var | ||
) | [static, protected] |
Handles -TR, which specifies a rotate transform about the three cardinal axes.
Var is an LMatrix4.
Definition at line 300 of file pfmTrans.cxx.
References ns_dispatch_rotate_xyz().
Referenced by add_transform_options().
bool PfmTrans::dispatch_scale | ( | const string & | opt, |
const string & | arg, | ||
void * | var | ||
) | [static, protected] |
Handles -TS, which specifies a scale transform.
Var is an LMatrix4.
Definition at line 261 of file pfmTrans.cxx.
References LMatrix4f::scale_mat().
Referenced by add_transform_options().
bool PfmTrans::dispatch_translate | ( | const string & | opt, |
const string & | arg, | ||
void * | var | ||
) | [static, protected] |
Handles -TT, which specifies a translate transform.
Var is an LMatrix4.
Definition at line 399 of file pfmTrans.cxx.
References LMatrix4f::translate_mat().
Referenced by add_transform_options().
bool PfmTrans::handle_args | ( | ProgramBase::Args & | args | ) | [protected, virtual] |
Does something with the additional arguments on the command line (after all the -options have been parsed).
Returns true if the arguments are good, false otherwise.
Reimplemented from ProgramBase.
Definition at line 227 of file pfmTrans.cxx.
References Filename::from_os_specific().
bool PfmTrans::ns_dispatch_rotate_axis | ( | const string & | opt, |
const string & | arg, | ||
void * | var | ||
) | [protected] |
Handles -TA, which specifies a rotate transform about an arbitrary axis.
Var is an LMatrix4.
Definition at line 363 of file pfmTrans.cxx.
References LMatrix4f::rotate_mat().
Referenced by dispatch_rotate_axis().
bool PfmTrans::ns_dispatch_rotate_xyz | ( | const string & | opt, |
const string & | arg, | ||
void * | var | ||
) | [protected] |
Handles -TR, which specifies a rotate transform about the three cardinal axes.
Var is an LMatrix4.
Definition at line 312 of file pfmTrans.cxx.
References LMatrix4f::rotate_mat().
Referenced by dispatch_rotate_xyz().
bool PfmTrans::process_pfm | ( | const Filename & | input_filename, |
PfmFile & | file | ||
) |
Handles a single pfm file.
Definition at line 134 of file pfmTrans.cxx.
References PfmFile::generate_vis_mesh(), Filename::get_basename(), Filename::get_basename_wo_extension(), TexturePool::load_texture(), NodePath::reparent_to(), PfmFile::resize(), PfmFile::reverse_rows(), NodePath::set_name(), NodePath::set_texture(), NodePath::set_transparency(), PfmFile::set_vis_2d(), PfmFile::set_vis_inverse(), PfmFile::set_zero_special(), PfmFile::write(), and PfmFile::xform().