diff options
author | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
---|---|---|
committer | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
commit | 47d455dd55be855e4cc691c32f687f723d9247ee (patch) | |
tree | 52e236aaa2576bdb3840ebede26619692fed6d7d /kpovmodeler/pmphotons.h | |
download | tdegraphics-47d455dd55be855e4cc691c32f687f723d9247ee.tar.gz tdegraphics-47d455dd55be855e4cc691c32f687f723d9247ee.zip |
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kpovmodeler/pmphotons.h')
-rw-r--r-- | kpovmodeler/pmphotons.h | 160 |
1 files changed, 160 insertions, 0 deletions
diff --git a/kpovmodeler/pmphotons.h b/kpovmodeler/pmphotons.h new file mode 100644 index 00000000..14ce9f6f --- /dev/null +++ b/kpovmodeler/pmphotons.h @@ -0,0 +1,160 @@ +//-*-C++-*- +/* +************************************************************************** + description + -------------------- + copyright : (C) 2003 by Leon Pennington + email : leon@leonscape.co.uk +************************************************************************** + +************************************************************************** +* * +* This program is free software; you can redistribute it and/or modify * +* it under the terms of the GNU General Public License as published by * +* the Free Software Foundation; either version 2 of the License, or * +* (at your option) any later version. * +* * +**************************************************************************/ + + +#ifndef PMPHOTONS_H +#define PMPHOTONS_H + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "pmobject.h" + +/** + * Class for Photons settings. + */ + +class PMPhotons : public PMObject +{ + typedef PMObject Base; +public: + /** + * Creates a PMPhotons + */ + PMPhotons( PMPart* part ); + /** + * Copy constructor + */ + PMPhotons( const PMPhotons& p ); + /** + * deletes the PMPhotons + */ + virtual ~PMPhotons( ); + + /** */ + virtual PMObject* copy( ) const { return new PMPhotons( *this ); } + /** */ + virtual QString description( ) const; + + /** */ + virtual PMMetaObject* metaObject( ) const; + /** */ + virtual void cleanUp( ) const; + + /** */ + virtual void serialize( QDomElement& e, QDomDocument& doc ) const; + /** */ + virtual void readAttributes( const PMXMLHelper& h ); + + /** + * Returns a new @ref PMPhotonsEdit + */ + virtual PMDialogEditBase* editWidget( QWidget* parent ) const; + /** + * Returns the name of the pixmap that is displayed in the tree view + * and dialog view + */ + virtual QString pixmap( ) const { return QString( "pmphotons" ); } + + /** + * Returns the target flag + */ + bool target( ) const { return m_target; } + /** + * Sets the target flag + */ + void setTarget( bool t ); + + /** + * Returns the spacing multiplier + */ + double spacingMulti( ) const { return m_spacingMulti; } + /** + * Sets the spacing multipler + */ + void setSpacingMulti( double sm ); + + /** + * Returns the refraction flag + */ + bool refraction( ) const { return m_refraction; } + /** + * Sets the refraction flag + */ + void setRefraction( bool r ); + + /** + * Returns the reflection flag + */ + bool reflection( ) const { return m_reflection; } + /** + * Sets the reflection flag + */ + void setReflection( bool r ); + + /** + * Returns the collect flag + */ + bool collect( ) const { return m_collect; } + /** + * Sets the collect flag + */ + void setCollect( bool c ); + + /** + * Returns the pass through flag + */ + bool passThrough( ) const { return m_passThrough; } + /** + * Sets the pass through flag + */ + void setPassThrough( bool pt ); + + /** + * Returns the area light flag + */ + bool areaLight( ) const { return m_areaLight; } + /** + * Sets the area light flag + */ + void setAreaLight( bool al ); + + /** */ + virtual void restoreMemento( PMMemento* s ); + +private: + /** + * IDs for @ref PMMementoData + */ + enum PMPhotonsMementoID{ PMTargetID, PMSpacingMultiID, PMRefractionID, + PMReflectionID, PMCollectID, PMPassThroughID, + PMAreaLightID }; + + bool m_target; + double m_spacingMulti; + bool m_refraction; + bool m_reflection; + bool m_collect; + bool m_passThrough; + bool m_areaLight; + + static PMMetaObject* s_pMetaObject; +}; + +#endif |