#include <paramset.h>
Public Member Functions | |
ParamSet () | |
ParamSet & | operator= (const ParamSet &p2) |
ParamSet (const ParamSet &p2) | |
ParamSet (int n, const char *pluginName, char *tokens[], char *params[]) | |
void | Add (ParamSet ¶ms) |
void | AddFloat (const string &, const float *, int nItems=1) |
void | AddInt (const string &, const int *, int nItems=1) |
void | AddBool (const string &, const bool *, int nItems=1) |
void | AddPoint (const string &, const Point *, int nItems=1) |
void | AddVector (const string &, const Vector *, int nItems=1) |
void | AddNormal (const string &, const Normal *, int nItems=1) |
void | AddRGBColor (const string &, const RGBColor *, int nItems=1) |
void | AddString (const string &, const string *, int nItems=1) |
void | AddTexture (const string &, const string &) |
bool | EraseInt (const string &) |
bool | EraseBool (const string &) |
bool | EraseFloat (const string &) |
bool | ErasePoint (const string &) |
bool | EraseVector (const string &) |
bool | EraseNormal (const string &) |
bool | EraseRGBColor (const string &) |
bool | EraseString (const string &) |
bool | EraseTexture (const string &) |
float | FindOneFloat (const string &, float d) const |
int | FindOneInt (const string &, int d) const |
bool | FindOneBool (const string &, bool d) const |
Point | FindOnePoint (const string &, const Point &d) const |
Vector | FindOneVector (const string &, const Vector &d) const |
Normal | FindOneNormal (const string &, const Normal &d) const |
RGBColor | FindOneRGBColor (const string &, const RGBColor &d) const |
string | FindOneString (const string &, const string &d) const |
string | FindTexture (const string &) const |
const float * | FindFloat (const string &, int *nItems) const |
const int * | FindInt (const string &, int *nItems) const |
const bool * | FindBool (const string &, int *nItems) const |
const Point * | FindPoint (const string &, int *nItems) const |
const Vector * | FindVector (const string &, int *nItems) const |
const Normal * | FindNormal (const string &, int *nItems) const |
const RGBColor * | FindRGBColor (const string &, int *nItems) const |
const string * | FindString (const string &, int *nItems) const |
void | ReportUnused () const |
~ParamSet () | |
void | Clear () |
string | ToString () const |
Private Member Functions | |
template<class Archive > | |
void | serialize (Archive &ar, const unsigned int version) |
Private Attributes | |
vector< ParamSetItem< int > * > | ints |
vector< ParamSetItem< bool > * > | bools |
vector< ParamSetItem< float > * > | floats |
vector< ParamSetItem< Point > * > | points |
vector< ParamSetItem< Vector > * > | vectors |
vector< ParamSetItem< Normal > * > | normals |
vector< ParamSetItem< RGBColor > * > | spectra |
vector< ParamSetItem< string > * > | strings |
vector< ParamSetItem< string > * > | textures |
Friends | |
class | boost::serialization::access |
Definition at line 62 of file paramset.h.
lux::ParamSet::ParamSet | ( | ) | [inline] |
Definition at line 67 of file paramset.h.
ParamSet::ParamSet | ( | const ParamSet & | p2 | ) |
Definition at line 33 of file paramset.cpp.
ParamSet::ParamSet | ( | int | n, | |
const char * | pluginName, | |||
char * | tokens[], | |||
char * | params[] | |||
) |
Definition at line 39 of file paramset.cpp.
References AddBool(), AddFloat(), AddInt(), AddNormal(), AddPoint(), AddRGBColor(), AddString(), AddTexture(), AddVector(), and FindOneInt().
lux::ParamSet::~ParamSet | ( | ) | [inline] |
Definition at line 127 of file paramset.h.
References Clear().
void ParamSet::Add | ( | ParamSet & | params | ) |
Definition at line 818 of file paramset.cpp.
References ADD_PARAMSETITEM_VECTOR, AddBool(), AddFloat(), AddInt(), AddNormal(), AddPoint(), AddRGBColor(), AddString(), AddTexture(), AddVector(), bools, floats, ints, normals, points, spectra, strings, textures, and vectors.
Referenced by lux::Context::film().
void ParamSet::AddBool | ( | const string & | name, | |
const bool * | data, | |||
int | nItems = 1 | |||
) |
Definition at line 851 of file paramset.cpp.
References ADD_PARAM_TYPE, bools, and EraseBool().
Referenced by Add(), lux::FlexImageFilm::CreateFilmFromFLM(), InitParamSet(), lux::Context::overrideResumeFLM(), and ParamSet().
void ParamSet::AddFloat | ( | const string & | name, | |
const float * | data, | |||
int | nItems = 1 | |||
) |
Definition at line 839 of file paramset.cpp.
References EraseFloat(), and floats.
Referenced by Add(), InitParamSet(), ParamSet(), lux::RealisticCamera::ParseLensData(), lux::PerspectiveCamera::PerspectiveCamera(), lux::NURBS::Refine(), lux::LoopSubdiv::Refine(), lux::Heightfield::Refine(), and lux::FlexImageFilm::WriteImage2().
Definition at line 847 of file paramset.cpp.
References ADD_PARAM_TYPE, EraseInt(), and ints.
Referenced by Add(), lux::FlexImageFilm::CreateFilmFromFLM(), InitParamSet(), ParamSet(), lux::NURBS::Refine(), lux::LoopSubdiv::Refine(), and lux::Heightfield::Refine().
Definition at line 863 of file paramset.cpp.
References ADD_PARAM_TYPE, EraseNormal(), and normals.
Referenced by Add(), InitParamSet(), ParamSet(), lux::NURBS::Refine(), and lux::LoopSubdiv::Refine().
Definition at line 855 of file paramset.cpp.
References ADD_PARAM_TYPE, ErasePoint(), and points.
Referenced by Add(), InitParamSet(), ParamSet(), lux::NURBS::Refine(), lux::LoopSubdiv::Refine(), and lux::Heightfield::Refine().
Definition at line 867 of file paramset.cpp.
References ADD_PARAM_TYPE, EraseRGBColor(), and spectra.
Referenced by Add(), InitParamSet(), and ParamSet().
void ParamSet::AddString | ( | const string & | name, | |
const string * | data, | |||
int | nItems = 1 | |||
) |
Definition at line 871 of file paramset.cpp.
References ADD_PARAM_TYPE, EraseString(), and strings.
Referenced by Add(), lux::FlexImageFilm::CreateFilmFromFLM(), InitParamSet(), lux::Context::overrideResumeFLM(), ParamSet(), and processFile().
void ParamSet::AddTexture | ( | const string & | name, | |
const string & | value | |||
) |
Definition at line 875 of file paramset.cpp.
References EraseTexture(), and textures.
Referenced by Add(), InitParamSet(), and ParamSet().
Definition at line 859 of file paramset.cpp.
References ADD_PARAM_TYPE, EraseVector(), and vectors.
Referenced by Add(), InitParamSet(), and ParamSet().
void ParamSet::Clear | ( | ) |
Definition at line 1042 of file paramset.cpp.
References bools, DEL_PARAMS, floats, ints, normals, points, spectra, strings, textures, and vectors.
Referenced by InitParamSet(), operator=(), and ~ParamSet().
bool ParamSet::EraseBool | ( | const string & | n | ) |
Definition at line 888 of file paramset.cpp.
References bools.
Referenced by AddBool(), and processCommandFilm().
bool ParamSet::EraseFloat | ( | const string & | n | ) |
bool ParamSet::EraseInt | ( | const string & | n | ) |
bool ParamSet::EraseNormal | ( | const string & | n | ) |
bool ParamSet::ErasePoint | ( | const string & | n | ) |
bool ParamSet::EraseRGBColor | ( | const string & | n | ) |
bool ParamSet::EraseString | ( | const string & | n | ) |
Definition at line 942 of file paramset.cpp.
References strings.
Referenced by AddString(), lux::Context::makemixmaterial(), and lux::Context::namedmaterial().
bool ParamSet::EraseTexture | ( | const string & | n | ) |
bool ParamSet::EraseVector | ( | const string & | n | ) |
const bool * ParamSet::FindBool | ( | const string & | name, | |
int * | nItems | |||
) | const |
Definition at line 983 of file paramset.cpp.
References bools, and LOOKUP_PTR.
const float * ParamSet::FindFloat | ( | const string & | name, | |
int * | nItems | |||
) | const |
Definition at line 970 of file paramset.cpp.
References floats.
Referenced by lux::PerspectiveCamera::CreateCamera(), lux::OrthoCamera::CreateCamera(), lux::EnvironmentCamera::CreateCamera(), lux::ImageFilm::CreateFilm(), lux::FlexImageFilm::CreateFilm(), lux::NURBS::CreateShape(), lux::Mesh::LoopMesh::CreateShape(), lux::Mesh::WaldMesh::CreateShape(), lux::Mesh::BaryMesh::CreateShape(), lux::Mesh::CreateShape(), lux::LoopSubdiv::CreateShape(), lux::Heightfield::CreateShape(), lux::VolumeGrid::CreateVolumeRegion(), and lux::FlexImageFilm::GetColorspaceParam().
Definition at line 980 of file paramset.cpp.
References ints, and LOOKUP_PTR.
Referenced by lux::Mesh::LoopMesh::CreateShape(), lux::Mesh::WaldMesh::CreateShape(), lux::Mesh::BaryMesh::CreateShape(), lux::Mesh::CreateShape(), CreateShape(), and lux::LoopSubdiv::CreateShape().
Definition at line 1004 of file paramset.cpp.
References LOOKUP_PTR, and normals.
Referenced by CreateShape().
bool ParamSet::FindOneBool | ( | const string & | name, | |
bool | d | |||
) | const |
Definition at line 989 of file paramset.cpp.
References bools, and LOOKUP_ONE.
Referenced by lux::GridAccel::CreateAccelerator(), lux::PerspectiveCamera::CreateCamera(), lux::OrthoCamera::CreateCamera(), lux::ImageFilm::CreateFilm(), lux::FlexImageFilm::CreateFilm(), lux::MetropolisSampler::CreateSampler(), CreateShape(), lux::LoopSubdiv::CreateShape(), lux::PhotonIntegrator::CreateSurfaceIntegrator(), lux::PathIntegrator::CreateSurfaceIntegrator(), lux::ExPhotonIntegrator::CreateSurfaceIntegrator(), lux::DistributedPath::CreateSurfaceIntegrator(), and lux::BidirIntegrator::CreateSurfaceIntegrator().
float ParamSet::FindOneFloat | ( | const string & | name, | |
float | d | |||
) | const |
Definition at line 960 of file paramset.cpp.
References floats.
Referenced by lux::UnsafeKdTreeAccel::CreateAccelerator(), lux::TaBRecKdTreeAccel::CreateAccelerator(), lux::BVHAccel::CreateAccelerator(), lux::AreaLight::CreateAreaLight(), lux::RealisticCamera::CreateCamera(), lux::PerspectiveCamera::CreateCamera(), lux::OrthoCamera::CreateCamera(), lux::EnvironmentCamera::CreateCamera(), lux::FlexImageFilm::CreateFilm(), lux::TriangleFilter::CreateFilter(), lux::LanczosSincFilter::CreateFilter(), lux::MitchellFilter::CreateFilter(), lux::GaussianFilter::CreateFilter(), lux::BoxFilter::CreateFilter(), lux::SunLight::CreateLight(), lux::SpotLight::CreateLight(), lux::SkyLight::CreateLight(), lux::ProjectionLight::CreateLight(), lux::PointLight::CreateLight(), lux::InfiniteAreaLight::CreateLight(), lux::DistantLight::CreateLight(), lux::MetropolisSampler::CreateSampler(), lux::ERPTSampler::CreateSampler(), lux::Torus::CreateShape(), lux::Sphere::CreateShape(), lux::Quad::CreateShape(), lux::Paraboloid::CreateShape(), lux::NURBS::CreateShape(), CreateShape(), lux::LoopSubdiv::CreateShape(), lux::LensComponent::CreateShape(), lux::Hyperboloid::CreateShape(), lux::Disk::CreateShape(), lux::Cylinder::CreateShape(), lux::Cone::CreateShape(), lux::PhotonIntegrator::CreateSurfaceIntegrator(), lux::PathIntegrator::CreateSurfaceIntegrator(), lux::MLTPathIntegrator::CreateSurfaceIntegrator(), lux::IrradianceCache::CreateSurfaceIntegrator(), lux::IGIIntegrator::CreateSurfaceIntegrator(), lux::ExPhotonIntegrator::CreateSurfaceIntegrator(), lux::DistributedPath::CreateSurfaceIntegrator(), lux::BidirIntegrator::CreateSurfaceIntegrator(), lux::ReinhardOp::CreateToneMap(), lux::NonLinearOp::CreateToneMap(), lux::LinearOp::CreateToneMap(), lux::ContrastOp::CreateToneMap(), lux::SingleScattering::CreateVolumeIntegrator(), lux::EmissionIntegrator::CreateVolumeIntegrator(), lux::VolumeGrid::CreateVolumeRegion(), lux::HomogeneousVolume::CreateVolumeRegion(), lux::ExponentialDensity::CreateVolumeRegion(), and lux::Cloud::CreateVolumeRegion().
Definition at line 986 of file paramset.cpp.
References ints, and LOOKUP_ONE.
Referenced by lux::UnsafeKdTreeAccel::CreateAccelerator(), lux::TaBRecKdTreeAccel::CreateAccelerator(), lux::BVHAccel::CreateAccelerator(), lux::AreaLight::CreateAreaLight(), lux::PerspectiveCamera::CreateCamera(), lux::ImageFilm::CreateFilm(), lux::FlexImageFilm::CreateFilm(), lux::SunLight::CreateLight(), lux::SkyLight::CreateLight(), lux::InfiniteAreaLightIS::CreateLight(), lux::InfiniteAreaLight::CreateLight(), lux::RandomSampler::CreateSampler(), lux::MetropolisSampler::CreateSampler(), lux::LDSampler::CreateSampler(), lux::ERPTSampler::CreateSampler(), lux::NURBS::CreateShape(), lux::Mesh::LoopMesh::CreateShape(), lux::Mesh::CreateShape(), lux::LoopSubdiv::CreateShape(), lux::Heightfield::CreateShape(), lux::WhittedIntegrator::CreateSurfaceIntegrator(), lux::PhotonIntegrator::CreateSurfaceIntegrator(), lux::PathIntegrator::CreateSurfaceIntegrator(), lux::MLTPathIntegrator::CreateSurfaceIntegrator(), lux::IrradianceCache::CreateSurfaceIntegrator(), lux::IGIIntegrator::CreateSurfaceIntegrator(), lux::ExPhotonIntegrator::CreateSurfaceIntegrator(), lux::DistributedPath::CreateSurfaceIntegrator(), lux::DirectLightingIntegrator::CreateSurfaceIntegrator(), lux::BidirIntegrator::CreateSurfaceIntegrator(), lux::VolumeGrid::CreateVolumeRegion(), lux::Cloud::CreateVolumeRegion(), and ParamSet().
Definition at line 1007 of file paramset.cpp.
References LOOKUP_ONE, and normals.
Definition at line 995 of file paramset.cpp.
References LOOKUP_ONE, and points.
Referenced by lux::SpotLight::CreateLight(), lux::PointLight::CreateLight(), lux::DistantLight::CreateLight(), lux::Hyperboloid::CreateShape(), lux::VolumeGrid::CreateVolumeRegion(), lux::HomogeneousVolume::CreateVolumeRegion(), lux::ExponentialDensity::CreateVolumeRegion(), and lux::Cloud::CreateVolumeRegion().
Definition at line 1013 of file paramset.cpp.
References LOOKUP_ONE, and spectra.
Referenced by lux::InfiniteAreaLightIS::CreateLight(), lux::InfiniteAreaLight::CreateLight(), lux::VolumeGrid::CreateVolumeRegion(), lux::HomogeneousVolume::CreateVolumeRegion(), lux::ExponentialDensity::CreateVolumeRegion(), lux::Cloud::CreateVolumeRegion(), and lux::TextureParams::GetSWCSpectrumTexture().
string ParamSet::FindOneString | ( | const string & | name, | |
const string & | d | |||
) | const |
Definition at line 1019 of file paramset.cpp.
References LOOKUP_ONE, and strings.
Referenced by lux::Context::camera(), lux::RealisticCamera::CreateCamera(), lux::PerspectiveCamera::CreateCamera(), lux::OrthoCamera::CreateCamera(), lux::EnvironmentCamera::CreateCamera(), lux::ImageFilm::CreateFilm(), lux::FlexImageFilm::CreateFilm(), lux::ProjectionLight::CreateLight(), lux::InfiniteAreaLightIS::CreateLight(), lux::InfiniteAreaLight::CreateLight(), lux::RandomSampler::CreateSampler(), lux::LDSampler::CreateSampler(), lux::ERPTSampler::CreateSampler(), lux::Mesh::LoopMesh::CreateShape(), lux::Mesh::CreateShape(), CreateShape(), lux::LoopSubdiv::CreateShape(), lux::PathIntegrator::CreateSurfaceIntegrator(), lux::ExPhotonIntegrator::CreateSurfaceIntegrator(), lux::DistributedPath::CreateSurfaceIntegrator(), lux::DirectLightingIntegrator::CreateSurfaceIntegrator(), lux::DebugIntegrator::CreateSurfaceIntegrator(), lux::BidirIntegrator::CreateSurfaceIntegrator(), lux::Context::makemixmaterial(), and processFile().
Definition at line 1001 of file paramset.cpp.
References LOOKUP_ONE, and vectors.
Referenced by lux::SunLight::CreateLight(), lux::SkyLight::CreateLight(), and lux::ExponentialDensity::CreateVolumeRegion().
Definition at line 992 of file paramset.cpp.
References LOOKUP_PTR, and points.
Referenced by lux::Quad::CreateShape(), lux::NURBS::CreateShape(), CreateShape(), and lux::LoopSubdiv::CreateShape().
Definition at line 1010 of file paramset.cpp.
References LOOKUP_PTR, and spectra.
const string * ParamSet::FindString | ( | const string & | name, | |
int * | nItems | |||
) | const |
Definition at line 1016 of file paramset.cpp.
References LOOKUP_PTR, and strings.
string ParamSet::FindTexture | ( | const string & | name | ) | const |
Definition at line 1022 of file paramset.cpp.
References LOOKUP_ONE, and textures.
Referenced by lux::TextureParams::GetFloatTexture(), and lux::TextureParams::GetSWCSpectrumTexture().
Definition at line 998 of file paramset.cpp.
References LOOKUP_PTR, and vectors.
void ParamSet::ReportUnused | ( | ) | const |
Definition at line 1026 of file paramset.cpp.
References bools, CHECK_UNUSED, floats, ints, normals, points, spectra, strings, textures, and vectors.
Referenced by lux::Context::portalShape(), and lux::Context::shape().
void lux::ParamSet::serialize | ( | Archive & | ar, | |
const unsigned int | version | |||
) | [inline, private] |
string ParamSet::ToString | ( | ) | const |
Definition at line 1054 of file paramset.cpp.
References bools, lux::Color::c, lux::ParamSetItem< T >::data, floats, ints, lux::ParamSetItem< T >::name, lux::ParamSetItem< T >::nItems, normals, points, spectra, strings, textures, vectors, lux::Normal::x, lux::Vector::x, lux::Point::x, lux::Normal::y, lux::Vector::y, lux::Point::y, lux::Normal::z, lux::Vector::z, and lux::Point::z.
friend class boost::serialization::access [friend] |
Definition at line 63 of file paramset.h.
vector<ParamSetItem<bool> *> lux::ParamSet::bools [private] |
Definition at line 137 of file paramset.h.
Referenced by Add(), AddBool(), Clear(), EraseBool(), FindBool(), FindOneBool(), operator=(), ReportUnused(), serialize(), and ToString().
vector<ParamSetItem<float> *> lux::ParamSet::floats [private] |
Definition at line 138 of file paramset.h.
Referenced by Add(), AddFloat(), Clear(), EraseFloat(), FindFloat(), FindOneFloat(), operator=(), ReportUnused(), serialize(), and ToString().
vector<ParamSetItem<int> *> lux::ParamSet::ints [private] |
Definition at line 136 of file paramset.h.
Referenced by Add(), AddInt(), Clear(), EraseInt(), FindInt(), FindOneInt(), operator=(), ReportUnused(), serialize(), and ToString().
vector<ParamSetItem<Normal> *> lux::ParamSet::normals [private] |
Definition at line 141 of file paramset.h.
Referenced by Add(), AddNormal(), Clear(), EraseNormal(), FindNormal(), FindOneNormal(), operator=(), ReportUnused(), serialize(), and ToString().
vector<ParamSetItem<Point> *> lux::ParamSet::points [private] |
Definition at line 139 of file paramset.h.
Referenced by Add(), AddPoint(), Clear(), ErasePoint(), FindOnePoint(), FindPoint(), operator=(), ReportUnused(), serialize(), and ToString().
vector<ParamSetItem<RGBColor> *> lux::ParamSet::spectra [private] |
Definition at line 142 of file paramset.h.
Referenced by Add(), AddRGBColor(), Clear(), EraseRGBColor(), FindOneRGBColor(), FindRGBColor(), operator=(), ReportUnused(), serialize(), and ToString().
vector<ParamSetItem<string> *> lux::ParamSet::strings [private] |
Definition at line 143 of file paramset.h.
Referenced by Add(), AddString(), Clear(), EraseString(), FindOneString(), FindString(), operator=(), ReportUnused(), serialize(), and ToString().
vector<ParamSetItem<string> *> lux::ParamSet::textures [private] |
Definition at line 144 of file paramset.h.
Referenced by Add(), AddTexture(), Clear(), EraseTexture(), FindTexture(), operator=(), ReportUnused(), serialize(), and ToString().
vector<ParamSetItem<Vector> *> lux::ParamSet::vectors [private] |
Definition at line 140 of file paramset.h.
Referenced by Add(), AddVector(), Clear(), EraseVector(), FindOneVector(), FindVector(), operator=(), ReportUnused(), serialize(), and ToString().