mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-17 21:11:39 +00:00
Changed: #1193 Code cleanup.
This commit is contained in:
parent
6934b285e2
commit
ffb5b2678b
141 changed files with 4702 additions and 3665 deletions
|
@ -29,7 +29,8 @@
|
||||||
|
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CAnimationDialog::CAnimationDialog(QWidget *parent)
|
CAnimationDialog::CAnimationDialog(QWidget *parent)
|
||||||
: QDockWidget(parent)
|
: QDockWidget(parent)
|
||||||
|
|
|
@ -33,7 +33,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CAnimationDialog
|
@class CAnimationDialog
|
||||||
|
|
|
@ -29,7 +29,8 @@
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
#include "entity.h"
|
#include "entity.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CAnimationSetDialog::CAnimationSetDialog(QWidget *parent)
|
CAnimationSetDialog::CAnimationSetDialog(QWidget *parent)
|
||||||
: QDockWidget(parent)
|
: QDockWidget(parent)
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
/**
|
/**
|
||||||
@class CAnimationSetDialog
|
@class CAnimationSetDialog
|
||||||
@brief Dialog - Animations control, loading animation, weight for skeleton and playlist composition.
|
@brief Dialog - Animations control, loading animation, weight for skeleton and playlist composition.
|
||||||
|
|
|
@ -40,7 +40,8 @@
|
||||||
#include "spinner_dialog.h"
|
#include "spinner_dialog.h"
|
||||||
#include "follow_path_dialog.h"
|
#include "follow_path_dialog.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CAttribWidget::CAttribWidget(QWidget *parent)
|
CAttribWidget::CAttribWidget(QWidget *parent)
|
||||||
: QGroupBox(parent),
|
: QGroupBox(parent),
|
||||||
|
|
|
@ -38,7 +38,8 @@
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
/**
|
/**
|
||||||
@class CAttribWidget
|
@class CAttribWidget
|
||||||
@brief Base attrib maker edition dialog.
|
@brief Base attrib maker edition dialog.
|
||||||
|
@ -70,9 +71,15 @@ public:
|
||||||
virtual void setSchemeNbCycles(float nbCycles) = 0;
|
virtual void setSchemeNbCycles(float nbCycles) = 0;
|
||||||
|
|
||||||
/// Enable the srcInput
|
/// Enable the srcInput
|
||||||
void enableSrcInput(bool enable = true) { _SrcInputEnabled = enable; }
|
void enableSrcInput(bool enable = true)
|
||||||
|
{
|
||||||
|
_SrcInputEnabled = enable;
|
||||||
|
}
|
||||||
|
|
||||||
bool isSrcInputEnabled() const { return _SrcInputEnabled; }
|
bool isSrcInputEnabled() const
|
||||||
|
{
|
||||||
|
return _SrcInputEnabled;
|
||||||
|
}
|
||||||
|
|
||||||
/// Disable the possibility to choose a scheme that has memory. (for example, a scheme for lifetime of a located has no sense
|
/// Disable the possibility to choose a scheme that has memory. (for example, a scheme for lifetime of a located has no sense
|
||||||
/// because located have already some memory to store it)
|
/// because located have already some memory to store it)
|
||||||
|
@ -80,11 +87,20 @@ public:
|
||||||
|
|
||||||
/// Tells wether memory schemes are enables
|
/// Tells wether memory schemes are enables
|
||||||
/// @see enableMemoryScheme()
|
/// @see enableMemoryScheme()
|
||||||
bool isMemorySchemeEnabled() const { return !_DisableMemoryScheme; }
|
bool isMemorySchemeEnabled() const
|
||||||
|
{
|
||||||
|
return !_DisableMemoryScheme;
|
||||||
|
}
|
||||||
|
|
||||||
/// Enable Nb Cycle tuning
|
/// Enable Nb Cycle tuning
|
||||||
void enableNbCycles(bool enabled) { _NbCycleEnabled = enabled; }
|
void enableNbCycles(bool enabled)
|
||||||
bool isNbCycleEnabled() const { return _NbCycleEnabled; }
|
{
|
||||||
|
_NbCycleEnabled = enabled;
|
||||||
|
}
|
||||||
|
bool isNbCycleEnabled() const
|
||||||
|
{
|
||||||
|
return _NbCycleEnabled;
|
||||||
|
}
|
||||||
|
|
||||||
private Q_SLOTS:
|
private Q_SLOTS:
|
||||||
virtual void clickedEdit();
|
virtual void clickedEdit();
|
||||||
|
@ -160,8 +176,14 @@ protected:
|
||||||
struct CNbCyclesWrapper : public IPSWrapperFloat
|
struct CNbCyclesWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
CAttribWidget *widget;
|
CAttribWidget *widget;
|
||||||
float get(void) const { return widget->getSchemeNbCycles(); }
|
float get(void) const
|
||||||
void set(const float &v) { widget->setSchemeNbCycles(v); }
|
{
|
||||||
|
return widget->getSchemeNbCycles();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
widget->setSchemeNbCycles(v);
|
||||||
|
}
|
||||||
} _NbCyclesWrapper;
|
} _NbCyclesWrapper;
|
||||||
|
|
||||||
CWorkspaceNode *_Node;
|
CWorkspaceNode *_Node;
|
||||||
|
@ -184,7 +206,11 @@ public:
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
virtual void setWrapper(IPSWrapper<T> *wrapper) = 0;
|
virtual void setWrapper(IPSWrapper<T> *wrapper) = 0;
|
||||||
void setSchemeWrapper(IPSSchemeWrapper<T> *schemeWrapper) { nlassert(schemeWrapper); _SchemeWrapper = schemeWrapper; }
|
void setSchemeWrapper(IPSSchemeWrapper<T> *schemeWrapper)
|
||||||
|
{
|
||||||
|
nlassert(schemeWrapper);
|
||||||
|
_SchemeWrapper = schemeWrapper;
|
||||||
|
}
|
||||||
|
|
||||||
// Inherited from CAttribWidget
|
// Inherited from CAttribWidget
|
||||||
virtual QDialog *editScheme(void) = 0;
|
virtual QDialog *editScheme(void) = 0;
|
||||||
|
@ -196,22 +222,51 @@ public:
|
||||||
_Wrapper->setAndUpdateModifiedFlag(_Wrapper->get()); // reuse current color
|
_Wrapper->setAndUpdateModifiedFlag(_Wrapper->get()); // reuse current color
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual bool hasSchemeCustomInput(void) const { return _SchemeWrapper->getScheme()->hasCustomInput(); }
|
virtual bool hasSchemeCustomInput(void) const
|
||||||
virtual NL3D::CPSInputType getSchemeInput(void) const { return _SchemeWrapper->getScheme()->getInput(); }
|
{
|
||||||
virtual void setSchemeInput(const NL3D::CPSInputType &input) { _SchemeWrapper->getScheme()->setInput(input); }
|
return _SchemeWrapper->getScheme()->hasCustomInput();
|
||||||
|
}
|
||||||
|
virtual NL3D::CPSInputType getSchemeInput(void) const
|
||||||
|
{
|
||||||
|
return _SchemeWrapper->getScheme()->getInput();
|
||||||
|
}
|
||||||
|
virtual void setSchemeInput(const NL3D::CPSInputType &input)
|
||||||
|
{
|
||||||
|
_SchemeWrapper->getScheme()->setInput(input);
|
||||||
|
}
|
||||||
|
|
||||||
virtual void setWorkspaceNode(CWorkspaceNode *node)
|
virtual void setWorkspaceNode(CWorkspaceNode *node)
|
||||||
{
|
{
|
||||||
_Node = node; if (_Wrapper != NULL) _Wrapper->OwnerNode = _Node; if (_SchemeWrapper != NULL) _SchemeWrapper->OwnerNode = _Node;
|
_Node = node;
|
||||||
|
if (_Wrapper != NULL) _Wrapper->OwnerNode = _Node;
|
||||||
|
if (_SchemeWrapper != NULL) _SchemeWrapper->OwnerNode = _Node;
|
||||||
};
|
};
|
||||||
|
|
||||||
virtual float getSchemeNbCycles(void) const { return _SchemeWrapper->getScheme()->getNbCycles(); }
|
virtual float getSchemeNbCycles(void) const
|
||||||
virtual void setSchemeNbCycles(float nbCycles) { _SchemeWrapper->getScheme()->setNbCycles(nbCycles); }
|
{
|
||||||
|
return _SchemeWrapper->getScheme()->getNbCycles();
|
||||||
|
}
|
||||||
|
virtual void setSchemeNbCycles(float nbCycles)
|
||||||
|
{
|
||||||
|
_SchemeWrapper->getScheme()->setNbCycles(nbCycles);
|
||||||
|
}
|
||||||
|
|
||||||
virtual bool isSchemeClamped(void) const { return _SchemeWrapper->getScheme()->getClamping(); }
|
virtual bool isSchemeClamped(void) const
|
||||||
virtual void clampScheme(bool clamped = true) { _SchemeWrapper->getScheme()->setClamping(clamped); }
|
{
|
||||||
virtual bool isClampingSupported(void) const { return _SchemeWrapper->getScheme()->isClampingSupported(); };
|
return _SchemeWrapper->getScheme()->getClamping();
|
||||||
virtual NL3D::CPSAttribMakerBase *getCurrentSchemePtr(void) const { return _SchemeWrapper->getScheme(); }
|
}
|
||||||
|
virtual void clampScheme(bool clamped = true)
|
||||||
|
{
|
||||||
|
_SchemeWrapper->getScheme()->setClamping(clamped);
|
||||||
|
}
|
||||||
|
virtual bool isClampingSupported(void) const
|
||||||
|
{
|
||||||
|
return _SchemeWrapper->getScheme()->isClampingSupported();
|
||||||
|
};
|
||||||
|
virtual NL3D::CPSAttribMakerBase *getCurrentSchemePtr(void) const
|
||||||
|
{
|
||||||
|
return _SchemeWrapper->getScheme();
|
||||||
|
}
|
||||||
virtual void setCurrentSchemePtr(NL3D::CPSAttribMakerBase *s)
|
virtual void setCurrentSchemePtr(NL3D::CPSAttribMakerBase *s)
|
||||||
{
|
{
|
||||||
_SchemeWrapper->setSchemeAndUpdateModifiedFlag(NLMISC::safe_cast<NL3D::CPSAttribMaker<T> *>(s));
|
_SchemeWrapper->setSchemeAndUpdateModifiedFlag(NLMISC::safe_cast<NL3D::CPSAttribMaker<T> *>(s));
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CAutoLODDialog::CAutoLODDialog(CWorkspaceNode *ownerNode, NL3D::CParticleSystem *ps, QWidget *parent)
|
CAutoLODDialog::CAutoLODDialog(CWorkspaceNode *ownerNode, NL3D::CParticleSystem *ps, QWidget *parent)
|
||||||
: QDialog(parent), _Node(ownerNode), _PS(ps)
|
: QDialog(parent), _Node(ownerNode), _PS(ps)
|
||||||
|
|
|
@ -32,7 +32,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CAutoLODDialog: public QDialog
|
class CAutoLODDialog: public QDialog
|
||||||
{
|
{
|
||||||
|
@ -54,15 +55,27 @@ private:
|
||||||
struct CDistRatioWrapper : IPSWrapperFloat
|
struct CDistRatioWrapper : IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CParticleSystem *PS;
|
NL3D::CParticleSystem *PS;
|
||||||
virtual float get() const { return PS->getAutoLODStartDistPercent(); }
|
virtual float get() const
|
||||||
virtual void set(const float &v) { PS->setupAutoLOD(v, PS->getAutoLODDegradationExponent()); }
|
{
|
||||||
|
return PS->getAutoLODStartDistPercent();
|
||||||
|
}
|
||||||
|
virtual void set(const float &v)
|
||||||
|
{
|
||||||
|
PS->setupAutoLOD(v, PS->getAutoLODDegradationExponent());
|
||||||
|
}
|
||||||
} _DistRatioWrapper;
|
} _DistRatioWrapper;
|
||||||
|
|
||||||
struct CMaxDistLODBiasWrapper : IPSWrapperFloat
|
struct CMaxDistLODBiasWrapper : IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CParticleSystem *PS;
|
NL3D::CParticleSystem *PS;
|
||||||
virtual float get() const { return PS->getMaxDistLODBias(); }
|
virtual float get() const
|
||||||
virtual void set(const float &v) { PS->setMaxDistLODBias(v); }
|
{
|
||||||
|
return PS->getMaxDistLODBias();
|
||||||
|
}
|
||||||
|
virtual void set(const float &v)
|
||||||
|
{
|
||||||
|
PS->setMaxDistLODBias(v);
|
||||||
|
}
|
||||||
} _MaxDistLODBiasWrapper;
|
} _MaxDistLODBiasWrapper;
|
||||||
|
|
||||||
Ui::CAutoLODDialog _ui;
|
Ui::CAutoLODDialog _ui;
|
||||||
|
|
|
@ -26,7 +26,8 @@
|
||||||
#include "nel/misc/matrix.h"
|
#include "nel/misc/matrix.h"
|
||||||
#include "nel/misc/vector.h"
|
#include "nel/misc/vector.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
// build an euler matrix
|
// build an euler matrix
|
||||||
|
@ -53,7 +54,9 @@ NLMISC::CVector GetEulerAngles(const NLMISC::CMatrix &mat)
|
||||||
mat.getRot(v[0], v[1], v[2]);
|
mat.getRot(v[0], v[1], v[2]);
|
||||||
for (uint l = 0; l < 3; ++l)
|
for (uint l = 0; l < 3; ++l)
|
||||||
{
|
{
|
||||||
m[0][l] = v[l].x; m[1][l] = v[l].y; m[2][l] = v[l].z;
|
m[0][l] = v[l].x;
|
||||||
|
m[1][l] = v[l].y;
|
||||||
|
m[2][l] = v[l].z;
|
||||||
}
|
}
|
||||||
|
|
||||||
// there are eight triplet that may satisfy the equation
|
// there are eight triplet that may satisfy the equation
|
||||||
|
|
|
@ -31,7 +31,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CBasicEditWidget: public QWidget
|
class CBasicEditWidget: public QWidget
|
||||||
{
|
{
|
||||||
|
|
|
@ -20,7 +20,8 @@
|
||||||
#include "stdpch.h"
|
#include "stdpch.h"
|
||||||
#include "bin_op_dialog.h"
|
#include "bin_op_dialog.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CBinOpDialog::CBinOpDialog(QWidget *widget1, QWidget *widget2, QWidget *parent)
|
CBinOpDialog::CBinOpDialog(QWidget *widget1, QWidget *widget2, QWidget *parent)
|
||||||
: QDialog(parent)
|
: QDialog(parent)
|
||||||
|
|
|
@ -38,7 +38,8 @@
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
#include "attrib_widget.h"
|
#include "attrib_widget.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CBinOpDialog : public QDialog
|
class CBinOpDialog : public QDialog
|
||||||
{
|
{
|
||||||
|
@ -140,15 +141,28 @@ protected:
|
||||||
{
|
{
|
||||||
NL3D::CPSAttribMakerBinOp<T> *S ;
|
NL3D::CPSAttribMakerBinOp<T> *S ;
|
||||||
uint Index ;
|
uint Index ;
|
||||||
virtual NL3D::CPSAttribMaker<T> *getScheme(void) const { return S->getArg(Index) ; }
|
virtual NL3D::CPSAttribMaker<T> *getScheme(void) const
|
||||||
virtual void setScheme(NL3D::CPSAttribMaker<T> *s) { S->setArg(Index, s) ; } ;
|
{
|
||||||
|
return S->getArg(Index) ;
|
||||||
|
}
|
||||||
|
virtual void setScheme(NL3D::CPSAttribMaker<T> *s)
|
||||||
|
{
|
||||||
|
S->setArg(Index, s) ;
|
||||||
|
} ;
|
||||||
} _SchemeWrapper[2] ;
|
} _SchemeWrapper[2] ;
|
||||||
|
|
||||||
/// a dummy wrapper for constant value. This shouldn't be called , however
|
/// a dummy wrapper for constant value. This shouldn't be called , however
|
||||||
struct CDummyWrapper : public IPSWrapper<T>
|
struct CDummyWrapper : public IPSWrapper<T>
|
||||||
{
|
{
|
||||||
T get(void) const { nlassert(false) ; return T() ; }
|
T get(void) const
|
||||||
void set(const T &) { nlassert(false) ; }
|
{
|
||||||
|
nlassert(false) ;
|
||||||
|
return T() ;
|
||||||
|
}
|
||||||
|
void set(const T &)
|
||||||
|
{
|
||||||
|
nlassert(false) ;
|
||||||
|
}
|
||||||
} _DummyWrapper ;
|
} _DummyWrapper ;
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,8 @@
|
||||||
#include "stdpch.h"
|
#include "stdpch.h"
|
||||||
#include "callback.h"
|
#include "callback.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
} /* namespace NLQT */
|
} /* namespace NLQT */
|
||||||
|
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
#define NLQT_CALLBACK_TEMPLATE \
|
#define NLQT_CALLBACK_TEMPLATE \
|
||||||
/** \
|
/** \
|
||||||
|
|
|
@ -27,7 +27,8 @@
|
||||||
// Nel includes
|
// Nel includes
|
||||||
#include <nel/misc/rgba.h>
|
#include <nel/misc/rgba.h>
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CColorEditWidget::CColorEditWidget(QWidget *parent)
|
CColorEditWidget::CColorEditWidget(QWidget *parent)
|
||||||
: QWidget(parent), _Wrapper(NULL), _emit(true)
|
: QWidget(parent), _Wrapper(NULL), _emit(true)
|
||||||
|
|
|
@ -27,7 +27,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CColorEditWidget
|
@class CColorEditWidget
|
||||||
|
|
|
@ -31,7 +31,8 @@
|
||||||
using namespace std;
|
using namespace std;
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CConfiguration::CConfiguration()
|
CConfiguration::CConfiguration()
|
||||||
{
|
{
|
||||||
|
|
|
@ -35,7 +35,8 @@
|
||||||
|
|
||||||
#define NLQT_CONFIG_FILE "object_viewer.cfg"
|
#define NLQT_CONFIG_FILE "object_viewer.cfg"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
typedef CCallback<void, NLMISC::CConfigFile::CVar &> CConfigCallback;
|
typedef CCallback<void, NLMISC::CConfigFile::CVar &> CConfigCallback;
|
||||||
|
|
||||||
|
@ -73,7 +74,10 @@ public:
|
||||||
NLMISC::CRGBA getValue(const std::string &varName, const NLMISC::CRGBA &defaultValue);
|
NLMISC::CRGBA getValue(const std::string &varName, const NLMISC::CRGBA &defaultValue);
|
||||||
NLMISC::CRGBA getValue(const NLMISC::CConfigFile::CVar &var, const NLMISC::CRGBA &defaultValue);
|
NLMISC::CRGBA getValue(const NLMISC::CConfigFile::CVar &var, const NLMISC::CRGBA &defaultValue);
|
||||||
|
|
||||||
inline NLMISC::CConfigFile &getConfigFile() { return ConfigFile; }
|
inline NLMISC::CConfigFile &getConfigFile()
|
||||||
|
{
|
||||||
|
return ConfigFile;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
static void cbConfigCallback(NLMISC::CConfigFile::CVar &var);
|
static void cbConfigCallback(NLMISC::CConfigFile::CVar &var);
|
||||||
|
|
|
@ -23,7 +23,8 @@
|
||||||
// NeL includes
|
// NeL includes
|
||||||
#include "nel/3d/ps_mesh.h"
|
#include "nel/3d/ps_mesh.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CConstraintMeshWidget::CConstraintMeshWidget(QWidget *parent )
|
CConstraintMeshWidget::CConstraintMeshWidget(QWidget *parent )
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -31,11 +31,13 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NL3D {
|
namespace NL3D
|
||||||
|
{
|
||||||
class CPSConstraintMesh;
|
class CPSConstraintMesh;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CConstraintMeshWidget
|
@class CConstraintMeshWidget
|
||||||
|
|
|
@ -23,7 +23,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CurveEditDialog::CurveEditDialog(NL3D::CPSFloatCurveFunctor *curve, CWorkspaceNode *ownerNode, QWidget *parent)
|
CurveEditDialog::CurveEditDialog(NL3D::CPSFloatCurveFunctor *curve, CWorkspaceNode *ownerNode, QWidget *parent)
|
||||||
: QDialog(parent) , _Curve(curve), _scale(1.0), _pos(0.0), _Node(ownerNode)
|
: QDialog(parent) , _Curve(curve), _scale(1.0), _pos(0.0), _Node(ownerNode)
|
||||||
|
|
|
@ -36,7 +36,8 @@
|
||||||
#include "hoverpoints.h"
|
#include "hoverpoints.h"
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
/**
|
/**
|
||||||
@class CurveEditDialog
|
@class CurveEditDialog
|
||||||
@brief Dialogue editing graphics curve.
|
@brief Dialogue editing graphics curve.
|
||||||
|
|
|
@ -26,7 +26,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CDayNightDialog::CDayNightDialog(QWidget *parent)
|
CDayNightDialog::CDayNightDialog(QWidget *parent)
|
||||||
: QDockWidget(parent)
|
: QDockWidget(parent)
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CDayNightDialog
|
@class CDayNightDialog
|
||||||
|
|
|
@ -26,7 +26,8 @@
|
||||||
// NeL includes
|
// NeL includes
|
||||||
#include <nel/misc/vector.h>
|
#include <nel/misc/vector.h>
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CDirectionWidget::CDirectionWidget(QWidget *parent)
|
CDirectionWidget::CDirectionWidget(QWidget *parent)
|
||||||
: QWidget(parent), _globalName("")
|
: QWidget(parent), _globalName("")
|
||||||
|
|
|
@ -29,7 +29,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CDirectionWidget
|
@class CDirectionWidget
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
using namespace NL3D;
|
using namespace NL3D;
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
const int max_range = 9999;
|
const int max_range = 9999;
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CEditRangeUIntWidget
|
@class CEditRangeUIntWidget
|
||||||
|
|
|
@ -29,7 +29,8 @@
|
||||||
#include "edit_range_widget.h"
|
#include "edit_range_widget.h"
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
CEmitterPage::CEmitterPage(QWidget *parent)
|
CEmitterPage::CEmitterPage(QWidget *parent)
|
||||||
|
|
|
@ -33,7 +33,8 @@
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CEmitterPage
|
@class CEmitterPage
|
||||||
|
@ -80,9 +81,15 @@ private:
|
||||||
{
|
{
|
||||||
CWorkspaceNode *Node;
|
CWorkspaceNode *Node;
|
||||||
NL3D::CPSEmitter *E;
|
NL3D::CPSEmitter *E;
|
||||||
float get(void) const { return E->getPeriod(); }
|
float get(void) const
|
||||||
|
{
|
||||||
|
return E->getPeriod();
|
||||||
|
}
|
||||||
void set(const float &v);
|
void set(const float &v);
|
||||||
scheme_type *getScheme(void) const { return E->getPeriodScheme(); }
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return E->getPeriodScheme();
|
||||||
|
}
|
||||||
void setScheme(scheme_type *s);
|
void setScheme(scheme_type *s);
|
||||||
} _PeriodWrapper;
|
} _PeriodWrapper;
|
||||||
|
|
||||||
|
@ -91,9 +98,15 @@ private:
|
||||||
{
|
{
|
||||||
CWorkspaceNode *Node;
|
CWorkspaceNode *Node;
|
||||||
NL3D::CPSEmitter *E;
|
NL3D::CPSEmitter *E;
|
||||||
uint32 get(void) const { return E->getGenNb(); }
|
uint32 get(void) const
|
||||||
|
{
|
||||||
|
return E->getGenNb();
|
||||||
|
}
|
||||||
void set(const uint32 &v);
|
void set(const uint32 &v);
|
||||||
scheme_type *getScheme(void) const { return E->getGenNbScheme(); }
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return E->getGenNbScheme();
|
||||||
|
}
|
||||||
void setScheme(scheme_type *s);
|
void setScheme(scheme_type *s);
|
||||||
} _GenNbWrapper;
|
} _GenNbWrapper;
|
||||||
|
|
||||||
|
@ -101,10 +114,22 @@ private:
|
||||||
struct CModulateStrenghtWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CModulateStrenghtWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSModulatedEmitter *E;
|
NL3D::CPSModulatedEmitter *E;
|
||||||
float get(void) const { return E->getEmitteeSpeed(); }
|
float get(void) const
|
||||||
void set(const float &v) { E->setEmitteeSpeed(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return E->getEmitteeSpeedScheme(); }
|
return E->getEmitteeSpeed();
|
||||||
void setScheme(scheme_type *s) { E->setEmitteeSpeedScheme(s); }
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
E->setEmitteeSpeed(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return E->getEmitteeSpeedScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
E->setEmitteeSpeedScheme(s);
|
||||||
|
}
|
||||||
} _ModulatedStrenghtWrapper;
|
} _ModulatedStrenghtWrapper;
|
||||||
|
|
||||||
// the emitter being edited
|
// the emitter being edited
|
||||||
|
@ -117,7 +142,10 @@ private:
|
||||||
|
|
||||||
void updatePeriodWidget();
|
void updatePeriodWidget();
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
CWorkspaceNode *_Node;
|
CWorkspaceNode *_Node;
|
||||||
|
|
||||||
|
|
|
@ -40,7 +40,8 @@
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
using namespace NL3D;
|
using namespace NL3D;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CSlotInfo& CSlotInfo::operator=(const CSlotInfo & slotInfo)
|
CSlotInfo& CSlotInfo::operator=(const CSlotInfo & slotInfo)
|
||||||
{
|
{
|
||||||
|
|
|
@ -36,12 +36,14 @@
|
||||||
#include <nel/3d/u_skeleton.h>
|
#include <nel/3d/u_skeleton.h>
|
||||||
#include <nel/3d/channel_mixer.h>
|
#include <nel/3d/channel_mixer.h>
|
||||||
|
|
||||||
namespace NL3D {
|
namespace NL3D
|
||||||
|
{
|
||||||
class UPlayList;
|
class UPlayList;
|
||||||
class UAnimationSet;
|
class UAnimationSet;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CSlotInfo
|
class CSlotInfo
|
||||||
{
|
{
|
||||||
|
@ -145,53 +147,98 @@ public:
|
||||||
float getAnimLength(std::string name);
|
float getAnimLength(std::string name);
|
||||||
|
|
||||||
/// Get slot infomation
|
/// Get slot infomation
|
||||||
void setSlotInfo(uint num, CSlotInfo& slotInfo) { _SlotInfo[num] = slotInfo; }
|
void setSlotInfo(uint num, CSlotInfo& slotInfo)
|
||||||
|
{
|
||||||
|
_SlotInfo[num] = slotInfo;
|
||||||
|
}
|
||||||
|
|
||||||
/// Set use mode playlist or mixer
|
/// Set use mode playlist or mixer
|
||||||
void setMode(int mode) { _AnimationStatus.Mode = mode; }
|
void setMode(int mode)
|
||||||
|
{
|
||||||
|
_AnimationStatus.Mode = mode;
|
||||||
|
}
|
||||||
|
|
||||||
/// Set in place mode animation
|
/// Set in place mode animation
|
||||||
void setInPlace(bool enabled) { _inPlace = enabled; }
|
void setInPlace(bool enabled)
|
||||||
|
{
|
||||||
|
_inPlace = enabled;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get in place mode
|
/// Get in place mode
|
||||||
bool getInPlace() { return _inPlace; }
|
bool getInPlace()
|
||||||
|
{
|
||||||
|
return _inPlace;
|
||||||
|
}
|
||||||
|
|
||||||
/// Set inc position
|
/// Set inc position
|
||||||
void setIncPos(bool enabled) { _incPos = enabled; }
|
void setIncPos(bool enabled)
|
||||||
|
{
|
||||||
|
_incPos = enabled;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get inc position
|
/// Get inc position
|
||||||
bool getIncPos() { return _incPos; }
|
bool getIncPos()
|
||||||
|
{
|
||||||
|
return _incPos;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get information about the current status of playing a playlist
|
/// Get information about the current status of playing a playlist
|
||||||
/// @return struct containing current information playback
|
/// @return struct containing current information playback
|
||||||
SAnimationStatus getStatus() { return _AnimationStatus; }
|
SAnimationStatus getStatus()
|
||||||
|
{
|
||||||
|
return _AnimationStatus;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get name entity
|
/// Get name entity
|
||||||
/// @return name entity
|
/// @return name entity
|
||||||
std::string getName() { return _Name; }
|
std::string getName()
|
||||||
|
{
|
||||||
|
return _Name;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get file name shape
|
/// Get file name shape
|
||||||
/// @return file name shape
|
/// @return file name shape
|
||||||
std::string getFileNameShape() { return _FileNameShape; }
|
std::string getFileNameShape()
|
||||||
|
{
|
||||||
|
return _FileNameShape;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get file name skeleton
|
/// Get file name skeleton
|
||||||
/// @return file name skeleton
|
/// @return file name skeleton
|
||||||
std::string getFileNameSkeleton() { return _FileNameSkeleton; }
|
std::string getFileNameSkeleton()
|
||||||
|
{
|
||||||
|
return _FileNameSkeleton;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get slot information
|
/// Get slot information
|
||||||
CSlotInfo getSlotInfo(uint num) { return _SlotInfo[num]; }
|
CSlotInfo getSlotInfo(uint num)
|
||||||
|
{
|
||||||
|
return _SlotInfo[num];
|
||||||
|
}
|
||||||
|
|
||||||
/// Get list loaded animations files
|
/// Get list loaded animations files
|
||||||
std::vector<std::string>& getAnimationList() { return _AnimationList; }
|
std::vector<std::string>& getAnimationList()
|
||||||
|
{
|
||||||
|
return _AnimationList;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get playlist animations
|
/// Get playlist animations
|
||||||
std::vector<std::string>& getPlayListAnimation() { return _PlayListAnimation; }
|
std::vector<std::string>& getPlayListAnimation()
|
||||||
|
{
|
||||||
|
return _PlayListAnimation;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get list loaded skeleton weight template files
|
/// Get list loaded skeleton weight template files
|
||||||
std::vector<std::string>& getSWTList() { return _SWTList; }
|
std::vector<std::string>& getSWTList()
|
||||||
|
{
|
||||||
|
return _SWTList;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get game interface for manipulating Skeleton.
|
/// Get game interface for manipulating Skeleton.
|
||||||
NL3D::USkeleton getSkeleton() const { return _Skeleton; }
|
NL3D::USkeleton getSkeleton() const
|
||||||
|
{
|
||||||
|
return _Skeleton;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Constructor
|
/// Constructor
|
||||||
|
|
|
@ -26,7 +26,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CFollowPathDialog::CFollowPathDialog(NL3D::CPSPlaneBasisFollowSpeed *pbfs, CWorkspaceNode *ownerNode, QWidget *parent)
|
CFollowPathDialog::CFollowPathDialog(NL3D::CPSPlaneBasisFollowSpeed *pbfs, CWorkspaceNode *ownerNode, QWidget *parent)
|
||||||
: QDialog(parent), _FollowPath(pbfs), _Node(ownerNode)
|
: QDialog(parent), _FollowPath(pbfs), _Node(ownerNode)
|
||||||
|
|
|
@ -32,7 +32,8 @@ namespace NL3D
|
||||||
class CPSPlaneBasisFollowSpeed;
|
class CPSPlaneBasisFollowSpeed;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CWorkspaceNode;
|
class CWorkspaceNode;
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,8 @@
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
#include <nel/3d/u_scene.h>
|
#include <nel/3d/u_scene.h>
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CGlobalWindDialog::CGlobalWindDialog(QWidget *parent)
|
CGlobalWindDialog::CGlobalWindDialog(QWidget *parent)
|
||||||
: QDockWidget(parent)
|
: QDockWidget(parent)
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CGlobalWindDialog: public QDockWidget
|
class CGlobalWindDialog: public QDockWidget
|
||||||
{
|
{
|
||||||
|
|
|
@ -27,7 +27,8 @@
|
||||||
|
|
||||||
// STL includes
|
// STL includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
const int directionSize = 35;
|
const int directionSize = 35;
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
struct Mode
|
struct Mode
|
||||||
{
|
{
|
||||||
|
|
|
@ -43,7 +43,8 @@
|
||||||
using namespace std;
|
using namespace std;
|
||||||
using namespace NL3D;
|
using namespace NL3D;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CGraphicsViewport::CGraphicsViewport(QWidget *parent)
|
CGraphicsViewport::CGraphicsViewport(QWidget *parent)
|
||||||
: QNLWidget(parent)
|
: QNLWidget(parent)
|
||||||
|
|
|
@ -44,7 +44,8 @@ typedef QGLWidget QNLWidget;
|
||||||
|
|
||||||
class QAction;
|
class QAction;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CGraphicsViewport
|
@class CGraphicsViewport
|
||||||
|
@ -58,7 +59,10 @@ public:
|
||||||
CGraphicsViewport(QWidget *parent);
|
CGraphicsViewport(QWidget *parent);
|
||||||
virtual ~CGraphicsViewport();
|
virtual ~CGraphicsViewport();
|
||||||
|
|
||||||
virtual QPaintEngine* paintEngine() const { return NULL; }
|
virtual QPaintEngine* paintEngine() const
|
||||||
|
{
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
void init();
|
void init();
|
||||||
void release();
|
void release();
|
||||||
|
|
|
@ -72,7 +72,8 @@ HoverPoints::HoverPoints(QWidget *widget, PointShape shape)
|
||||||
|
|
||||||
void HoverPoints::setEnabled(bool enabled)
|
void HoverPoints::setEnabled(bool enabled)
|
||||||
{
|
{
|
||||||
if (m_enabled != enabled) {
|
if (m_enabled != enabled)
|
||||||
|
{
|
||||||
m_enabled = enabled;
|
m_enabled = enabled;
|
||||||
m_widget->update();
|
m_widget->update();
|
||||||
}
|
}
|
||||||
|
@ -81,8 +82,10 @@ void HoverPoints::setEnabled(bool enabled)
|
||||||
|
|
||||||
bool HoverPoints::eventFilter(QObject *object, QEvent *event)
|
bool HoverPoints::eventFilter(QObject *object, QEvent *event)
|
||||||
{
|
{
|
||||||
if (object == m_widget && m_enabled) {
|
if (object == m_widget && m_enabled)
|
||||||
switch (event->type()) {
|
{
|
||||||
|
switch (event->type())
|
||||||
|
{
|
||||||
|
|
||||||
case QEvent::MouseButtonPress:
|
case QEvent::MouseButtonPress:
|
||||||
{
|
{
|
||||||
|
@ -92,34 +95,43 @@ bool HoverPoints::eventFilter(QObject *object, QEvent *event)
|
||||||
|
|
||||||
QPointF clickPos = me->pos();
|
QPointF clickPos = me->pos();
|
||||||
int index = -1;
|
int index = -1;
|
||||||
for (int i=0; i<m_points.size(); ++i) {
|
for (int i=0; i<m_points.size(); ++i)
|
||||||
|
{
|
||||||
QPainterPath path;
|
QPainterPath path;
|
||||||
if (m_shape == CircleShape)
|
if (m_shape == CircleShape)
|
||||||
path.addEllipse(pointBoundingRect(i));
|
path.addEllipse(pointBoundingRect(i));
|
||||||
else
|
else
|
||||||
path.addRect(pointBoundingRect(i));
|
path.addRect(pointBoundingRect(i));
|
||||||
|
|
||||||
if (path.contains(clickPos)) {
|
if (path.contains(clickPos))
|
||||||
|
{
|
||||||
index = i;
|
index = i;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (me->button() == Qt::LeftButton) {
|
if (me->button() == Qt::LeftButton)
|
||||||
if (index == -1) {
|
{
|
||||||
|
if (index == -1)
|
||||||
|
{
|
||||||
if (!m_editable)
|
if (!m_editable)
|
||||||
return false;
|
return false;
|
||||||
int pos = 0;
|
int pos = 0;
|
||||||
// Insert sort for x or y
|
// Insert sort for x or y
|
||||||
if (m_sortType == XSort) {
|
if (m_sortType == XSort)
|
||||||
|
{
|
||||||
for (int i=0; i<m_points.size(); ++i)
|
for (int i=0; i<m_points.size(); ++i)
|
||||||
if (m_points.at(i).x() > clickPos.x()) {
|
if (m_points.at(i).x() > clickPos.x())
|
||||||
|
{
|
||||||
pos = i;
|
pos = i;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
} else if (m_sortType == YSort) {
|
}
|
||||||
|
else if (m_sortType == YSort)
|
||||||
|
{
|
||||||
for (int i=0; i<m_points.size(); ++i)
|
for (int i=0; i<m_points.size(); ++i)
|
||||||
if (m_points.at(i).y() > clickPos.y()) {
|
if (m_points.at(i).y() > clickPos.y())
|
||||||
|
{
|
||||||
pos = i;
|
pos = i;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -130,16 +142,22 @@ bool HoverPoints::eventFilter(QObject *object, QEvent *event)
|
||||||
m_currentIndex = pos;
|
m_currentIndex = pos;
|
||||||
firePointChange();
|
firePointChange();
|
||||||
|
|
||||||
} else {
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
m_currentIndex = index;
|
m_currentIndex = index;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
} else if (me->button() == Qt::RightButton) {
|
}
|
||||||
if (index >= 0 && m_editable) {
|
else if (me->button() == Qt::RightButton)
|
||||||
|
{
|
||||||
|
if (index >= 0 && m_editable)
|
||||||
|
{
|
||||||
if ((m_points.size() - 1) < m_minCountPoints)
|
if ((m_points.size() - 1) < m_minCountPoints)
|
||||||
return true;
|
return true;
|
||||||
if (m_locks[index] == 0) {
|
if (m_locks[index] == 0)
|
||||||
|
{
|
||||||
m_locks.remove(index);
|
m_locks.remove(index);
|
||||||
m_points.remove(index);
|
m_points.remove(index);
|
||||||
}
|
}
|
||||||
|
@ -169,9 +187,11 @@ bool HoverPoints::eventFilter(QObject *object, QEvent *event)
|
||||||
const QTouchEvent *const touchEvent = static_cast<const QTouchEvent*>(event);
|
const QTouchEvent *const touchEvent = static_cast<const QTouchEvent*>(event);
|
||||||
const QList<QTouchEvent::TouchPoint> points = touchEvent->touchPoints();
|
const QList<QTouchEvent::TouchPoint> points = touchEvent->touchPoints();
|
||||||
const qreal pointSize = qMax(m_pointSize.width(), m_pointSize.height());
|
const qreal pointSize = qMax(m_pointSize.width(), m_pointSize.height());
|
||||||
Q_FOREACH (const QTouchEvent::TouchPoint &touchPoint, points) {
|
Q_FOREACH (const QTouchEvent::TouchPoint &touchPoint, points)
|
||||||
|
{
|
||||||
const int id = touchPoint.id();
|
const int id = touchPoint.id();
|
||||||
switch (touchPoint.state()) {
|
switch (touchPoint.state())
|
||||||
|
{
|
||||||
case Qt::TouchPointPressed:
|
case Qt::TouchPointPressed:
|
||||||
{
|
{
|
||||||
// find the point, move it
|
// find the point, move it
|
||||||
|
@ -180,22 +200,28 @@ bool HoverPoints::eventFilter(QObject *object, QEvent *event)
|
||||||
qreal distance = -1;
|
qreal distance = -1;
|
||||||
const int pointsCount = m_points.size();
|
const int pointsCount = m_points.size();
|
||||||
const int activePointCount = activePoints.size();
|
const int activePointCount = activePoints.size();
|
||||||
if (pointsCount == 2 && activePointCount == 1) { // only two points
|
if (pointsCount == 2 && activePointCount == 1) // only two points
|
||||||
|
{
|
||||||
activePoint = activePoints.contains(0) ? 1 : 0;
|
activePoint = activePoints.contains(0) ? 1 : 0;
|
||||||
} else {
|
}
|
||||||
for (int i=0; i<pointsCount; ++i) {
|
else
|
||||||
|
{
|
||||||
|
for (int i=0; i<pointsCount; ++i)
|
||||||
|
{
|
||||||
if (activePoints.contains(i))
|
if (activePoints.contains(i))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
qreal d = QLineF(touchPoint.pos(), m_points.at(i)).length();
|
qreal d = QLineF(touchPoint.pos(), m_points.at(i)).length();
|
||||||
if ((distance < 0 && d < 12 * pointSize) || d < distance) {
|
if ((distance < 0 && d < 12 * pointSize) || d < distance)
|
||||||
|
{
|
||||||
distance = d;
|
distance = d;
|
||||||
activePoint = i;
|
activePoint = i;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (activePoint != -1) {
|
if (activePoint != -1)
|
||||||
|
{
|
||||||
m_fingerPointMapping.insert(touchPoint.id(), activePoint);
|
m_fingerPointMapping.insert(touchPoint.id(), activePoint);
|
||||||
movePoint(activePoint, touchPoint.pos());
|
movePoint(activePoint, touchPoint.pos());
|
||||||
}
|
}
|
||||||
|
@ -221,16 +247,20 @@ bool HoverPoints::eventFilter(QObject *object, QEvent *event)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (m_fingerPointMapping.isEmpty()) {
|
if (m_fingerPointMapping.isEmpty())
|
||||||
|
{
|
||||||
event->ignore();
|
event->ignore();
|
||||||
return false;
|
return false;
|
||||||
} else {
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case QEvent::TouchEnd:
|
case QEvent::TouchEnd:
|
||||||
if (m_fingerPointMapping.isEmpty()) {
|
if (m_fingerPointMapping.isEmpty())
|
||||||
|
{
|
||||||
event->ignore();
|
event->ignore();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -244,7 +274,8 @@ bool HoverPoints::eventFilter(QObject *object, QEvent *event)
|
||||||
break;
|
break;
|
||||||
qreal stretch_x = e->size().width() / qreal(e->oldSize().width());
|
qreal stretch_x = e->size().width() / qreal(e->oldSize().width());
|
||||||
qreal stretch_y = e->size().height() / qreal(e->oldSize().height());
|
qreal stretch_y = e->size().height() / qreal(e->oldSize().height());
|
||||||
for (int i=0; i<m_points.size(); ++i) {
|
for (int i=0; i<m_points.size(); ++i)
|
||||||
|
{
|
||||||
QPointF p = m_points[i];
|
QPointF p = m_points[i];
|
||||||
movePoint(i, QPointF(p.x() * stretch_x, p.y() * stretch_y), false);
|
movePoint(i, QPointF(p.x() * stretch_x, p.y() * stretch_y), false);
|
||||||
}
|
}
|
||||||
|
@ -283,13 +314,16 @@ void HoverPoints::paintPoints()
|
||||||
|
|
||||||
p.setBrush(QBrush());
|
p.setBrush(QBrush());
|
||||||
|
|
||||||
if (m_connectionPen.style() != Qt::NoPen && m_connectionType != NoConnection) {
|
if (m_connectionPen.style() != Qt::NoPen && m_connectionType != NoConnection)
|
||||||
|
{
|
||||||
p.setPen(m_connectionPen);
|
p.setPen(m_connectionPen);
|
||||||
|
|
||||||
if (m_connectionType == CurveConnection) {
|
if (m_connectionType == CurveConnection)
|
||||||
|
{
|
||||||
QPainterPath path;
|
QPainterPath path;
|
||||||
path.moveTo(m_points.at(0));
|
path.moveTo(m_points.at(0));
|
||||||
for (int i=1; i<m_points.size(); ++i) {
|
for (int i=1; i<m_points.size(); ++i)
|
||||||
|
{
|
||||||
QPointF p1 = m_points.at(i-1);
|
QPointF p1 = m_points.at(i-1);
|
||||||
QPointF p2 = m_points.at(i);
|
QPointF p2 = m_points.at(i);
|
||||||
qreal distance = p2.x() - p1.x();
|
qreal distance = p2.x() - p1.x();
|
||||||
|
@ -299,7 +333,9 @@ void HoverPoints::paintPoints()
|
||||||
p2.x(), p2.y());
|
p2.x(), p2.y());
|
||||||
}
|
}
|
||||||
p.drawPath(path);
|
p.drawPath(path);
|
||||||
} else {
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
p.drawPolyline(m_points);
|
p.drawPolyline(m_points);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -307,7 +343,8 @@ void HoverPoints::paintPoints()
|
||||||
p.setPen(m_pointPen);
|
p.setPen(m_pointPen);
|
||||||
p.setBrush(m_pointBrush);
|
p.setBrush(m_pointBrush);
|
||||||
|
|
||||||
for (int i=0; i<m_points.size(); ++i) {
|
for (int i=0; i<m_points.size(); ++i)
|
||||||
|
{
|
||||||
QRectF bounds = pointBoundingRect(i);
|
QRectF bounds = pointBoundingRect(i);
|
||||||
if (m_shape == CircleShape)
|
if (m_shape == CircleShape)
|
||||||
p.drawEllipse(bounds);
|
p.drawEllipse(bounds);
|
||||||
|
@ -344,7 +381,8 @@ void HoverPoints::setPoints(const QPolygonF &points)
|
||||||
m_points << bound_point(points.at(i), boundingRect(), 0);
|
m_points << bound_point(points.at(i), boundingRect(), 0);
|
||||||
|
|
||||||
m_locks.clear();
|
m_locks.clear();
|
||||||
if (m_points.size() > 0) {
|
if (m_points.size() > 0)
|
||||||
|
{
|
||||||
m_locks.resize(m_points.size());
|
m_locks.resize(m_points.size());
|
||||||
|
|
||||||
m_locks.fill(0);
|
m_locks.fill(0);
|
||||||
|
@ -382,10 +420,12 @@ inline static bool y_less_than(const QPointF &p1, const QPointF &p2)
|
||||||
|
|
||||||
void HoverPoints::firePointChange()
|
void HoverPoints::firePointChange()
|
||||||
{
|
{
|
||||||
if (m_sortType != NoSort) {
|
if (m_sortType != NoSort)
|
||||||
|
{
|
||||||
|
|
||||||
QPointF oldCurrent;
|
QPointF oldCurrent;
|
||||||
if (m_currentIndex != -1) {
|
if (m_currentIndex != -1)
|
||||||
|
{
|
||||||
oldCurrent = m_points[m_currentIndex];
|
oldCurrent = m_points[m_currentIndex];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -395,9 +435,12 @@ void HoverPoints::firePointChange()
|
||||||
qSort(m_points.begin(), m_points.end(), y_less_than);
|
qSort(m_points.begin(), m_points.end(), y_less_than);
|
||||||
|
|
||||||
// Compensate for changed order...
|
// Compensate for changed order...
|
||||||
if (m_currentIndex != -1) {
|
if (m_currentIndex != -1)
|
||||||
for (int i=0; i<m_points.size(); ++i) {
|
{
|
||||||
if (m_points[i] == oldCurrent) {
|
for (int i=0; i<m_points.size(); ++i)
|
||||||
|
{
|
||||||
|
if (m_points[i] == oldCurrent)
|
||||||
|
{
|
||||||
m_currentIndex = i;
|
m_currentIndex = i;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,25 +50,29 @@ class HoverPoints : public QObject
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
enum PointShape {
|
enum PointShape
|
||||||
|
{
|
||||||
CircleShape,
|
CircleShape,
|
||||||
RectangleShape
|
RectangleShape
|
||||||
};
|
};
|
||||||
|
|
||||||
enum LockType {
|
enum LockType
|
||||||
|
{
|
||||||
LockToLeft = 0x01,
|
LockToLeft = 0x01,
|
||||||
LockToRight = 0x02,
|
LockToRight = 0x02,
|
||||||
LockToTop = 0x04,
|
LockToTop = 0x04,
|
||||||
LockToBottom = 0x08
|
LockToBottom = 0x08
|
||||||
};
|
};
|
||||||
|
|
||||||
enum SortType {
|
enum SortType
|
||||||
|
{
|
||||||
NoSort,
|
NoSort,
|
||||||
XSort,
|
XSort,
|
||||||
YSort
|
YSort
|
||||||
};
|
};
|
||||||
|
|
||||||
enum ConnectionType {
|
enum ConnectionType
|
||||||
|
{
|
||||||
NoConnection,
|
NoConnection,
|
||||||
LineConnection,
|
LineConnection,
|
||||||
CurveConnection
|
CurveConnection
|
||||||
|
@ -81,32 +85,77 @@ public:
|
||||||
void paintPoints();
|
void paintPoints();
|
||||||
|
|
||||||
inline QRectF boundingRect() const;
|
inline QRectF boundingRect() const;
|
||||||
void setBoundingRect(const QRectF &boundingRect) { m_bounds = boundingRect; }
|
void setBoundingRect(const QRectF &boundingRect)
|
||||||
|
{
|
||||||
|
m_bounds = boundingRect;
|
||||||
|
}
|
||||||
|
|
||||||
QPolygonF points() const { return m_points; }
|
QPolygonF points() const
|
||||||
|
{
|
||||||
|
return m_points;
|
||||||
|
}
|
||||||
void setPoints(const QPolygonF &points);
|
void setPoints(const QPolygonF &points);
|
||||||
|
|
||||||
QSizeF pointSize() const { return m_pointSize; }
|
QSizeF pointSize() const
|
||||||
void setPointSize(const QSizeF &size) { m_pointSize = size; }
|
{
|
||||||
|
return m_pointSize;
|
||||||
|
}
|
||||||
|
void setPointSize(const QSizeF &size)
|
||||||
|
{
|
||||||
|
m_pointSize = size;
|
||||||
|
}
|
||||||
|
|
||||||
SortType sortType() const { return m_sortType; }
|
SortType sortType() const
|
||||||
void setSortType(SortType sortType) { m_sortType = sortType; }
|
{
|
||||||
|
return m_sortType;
|
||||||
|
}
|
||||||
|
void setSortType(SortType sortType)
|
||||||
|
{
|
||||||
|
m_sortType = sortType;
|
||||||
|
}
|
||||||
|
|
||||||
ConnectionType connectionType() const { return m_connectionType; }
|
ConnectionType connectionType() const
|
||||||
void setConnectionType(ConnectionType connectionType) { m_connectionType = connectionType; }
|
{
|
||||||
|
return m_connectionType;
|
||||||
|
}
|
||||||
|
void setConnectionType(ConnectionType connectionType)
|
||||||
|
{
|
||||||
|
m_connectionType = connectionType;
|
||||||
|
}
|
||||||
|
|
||||||
void setConnectionPen(const QPen &pen) { m_connectionPen = pen; }
|
void setConnectionPen(const QPen &pen)
|
||||||
void setShapePen(const QPen &pen) { m_pointPen = pen; }
|
{
|
||||||
void setShapeBrush(const QBrush &brush) { m_pointBrush = brush; }
|
m_connectionPen = pen;
|
||||||
|
}
|
||||||
|
void setShapePen(const QPen &pen)
|
||||||
|
{
|
||||||
|
m_pointPen = pen;
|
||||||
|
}
|
||||||
|
void setShapeBrush(const QBrush &brush)
|
||||||
|
{
|
||||||
|
m_pointBrush = brush;
|
||||||
|
}
|
||||||
|
|
||||||
void setPointLock(int pos, LockType lock) { m_locks[pos] = lock; }
|
void setPointLock(int pos, LockType lock)
|
||||||
|
{
|
||||||
|
m_locks[pos] = lock;
|
||||||
|
}
|
||||||
|
|
||||||
void setEditable(bool editable) { m_editable = editable; }
|
void setEditable(bool editable)
|
||||||
bool editable() const { return m_editable; }
|
{
|
||||||
|
m_editable = editable;
|
||||||
|
}
|
||||||
|
bool editable() const
|
||||||
|
{
|
||||||
|
return m_editable;
|
||||||
|
}
|
||||||
|
|
||||||
public Q_SLOTS:
|
public Q_SLOTS:
|
||||||
void setEnabled(bool enabled);
|
void setEnabled(bool enabled);
|
||||||
void setDisabled(bool disabled) { setEnabled(!disabled); }
|
void setDisabled(bool disabled)
|
||||||
|
{
|
||||||
|
setEnabled(!disabled);
|
||||||
|
}
|
||||||
|
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
void pointsChanged(const QPolygonF &points);
|
void pointsChanged(const QPolygonF &points);
|
||||||
|
|
|
@ -29,7 +29,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CLocatedBindablePage::CLocatedBindablePage(QWidget *parent)
|
CLocatedBindablePage::CLocatedBindablePage(QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -37,7 +37,8 @@
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CLocatedBindablePage
|
@class CLocatedBindablePage
|
||||||
|
@ -80,166 +81,313 @@ private:
|
||||||
struct CSizeWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CSizeWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSSizedParticle *S;
|
NL3D::CPSSizedParticle *S;
|
||||||
float get(void) const { return S->getSize(); }
|
float get(void) const
|
||||||
void set(const float &v) { S->setSize(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return S->getSizeScheme(); }
|
return S->getSize();
|
||||||
void setScheme(scheme_type *s) { S->setSizeScheme(s); }
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
S->setSize(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return S->getSizeScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
S->setSizeScheme(s);
|
||||||
|
}
|
||||||
} _SizeWrapper;
|
} _SizeWrapper;
|
||||||
|
|
||||||
/// Color
|
/// Color
|
||||||
struct CColorWrapper : public IPSWrapperRGBA, IPSSchemeWrapperRGBA
|
struct CColorWrapper : public IPSWrapperRGBA, IPSSchemeWrapperRGBA
|
||||||
{
|
{
|
||||||
NL3D::CPSColoredParticle *S;
|
NL3D::CPSColoredParticle *S;
|
||||||
NLMISC::CRGBA get(void) const { return S->getColor(); }
|
NLMISC::CRGBA get(void) const
|
||||||
void set(const NLMISC::CRGBA &v) { S->setColor(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return S->getColorScheme(); }
|
return S->getColor();
|
||||||
void setScheme(scheme_type *s) { S->setColorScheme(s); }
|
}
|
||||||
|
void set(const NLMISC::CRGBA &v)
|
||||||
|
{
|
||||||
|
S->setColor(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return S->getColorScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
S->setColorScheme(s);
|
||||||
|
}
|
||||||
} _ColorWrapper;
|
} _ColorWrapper;
|
||||||
|
|
||||||
/// Angle 2D
|
/// Angle 2D
|
||||||
struct CAngle2DWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CAngle2DWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSRotated2DParticle *S;
|
NL3D::CPSRotated2DParticle *S;
|
||||||
float get(void) const { return S->getAngle2D(); }
|
float get(void) const
|
||||||
void set(const float &v) { S->setAngle2D(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return S->getAngle2DScheme(); }
|
return S->getAngle2D();
|
||||||
void setScheme(scheme_type *s) { S->setAngle2DScheme(s); }
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
S->setAngle2D(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return S->getAngle2DScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
S->setAngle2DScheme(s);
|
||||||
|
}
|
||||||
} _Angle2DWrapper;
|
} _Angle2DWrapper;
|
||||||
|
|
||||||
/// Plane basis
|
/// Plane basis
|
||||||
struct CPlaneBasisWrapper : public IPSWrapper<NL3D::CPlaneBasis>, IPSSchemeWrapper<NL3D::CPlaneBasis>
|
struct CPlaneBasisWrapper : public IPSWrapper<NL3D::CPlaneBasis>, IPSSchemeWrapper<NL3D::CPlaneBasis>
|
||||||
{
|
{
|
||||||
NL3D::CPSRotated3DPlaneParticle *S;
|
NL3D::CPSRotated3DPlaneParticle *S;
|
||||||
NL3D::CPlaneBasis get(void) const { return S->getPlaneBasis(); }
|
NL3D::CPlaneBasis get(void) const
|
||||||
void set(const NL3D::CPlaneBasis &p) { S->setPlaneBasis(p); }
|
{
|
||||||
scheme_type *getScheme(void) const { return S->getPlaneBasisScheme(); }
|
return S->getPlaneBasis();
|
||||||
void setScheme(scheme_type *s) { S->setPlaneBasisScheme(s); }
|
}
|
||||||
|
void set(const NL3D::CPlaneBasis &p)
|
||||||
|
{
|
||||||
|
S->setPlaneBasis(p);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return S->getPlaneBasisScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
S->setPlaneBasisScheme(s);
|
||||||
|
}
|
||||||
} _PlaneBasisWrapper;
|
} _PlaneBasisWrapper;
|
||||||
|
|
||||||
/// Motion blur coeff
|
/// Motion blur coeff
|
||||||
struct CMotionBlurCoeffWrapper : public IPSWrapperFloat
|
struct CMotionBlurCoeffWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSFaceLookAt *P;
|
NL3D::CPSFaceLookAt *P;
|
||||||
float get(void) const { return P->getMotionBlurCoeff(); }
|
float get(void) const
|
||||||
void set(const float &v) { P->setMotionBlurCoeff(v); }
|
{
|
||||||
|
return P->getMotionBlurCoeff();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
P->setMotionBlurCoeff(v);
|
||||||
|
}
|
||||||
} _MotionBlurCoeffWrapper;
|
} _MotionBlurCoeffWrapper;
|
||||||
struct CMotionBlurThresholdWrapper : public IPSWrapperFloat
|
struct CMotionBlurThresholdWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSFaceLookAt *P;
|
NL3D::CPSFaceLookAt *P;
|
||||||
float get(void) const { return P->getMotionBlurThreshold(); }
|
float get(void) const
|
||||||
void set(const float &v) { P->setMotionBlurThreshold(v); }
|
{
|
||||||
|
return P->getMotionBlurThreshold();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
P->setMotionBlurThreshold(v);
|
||||||
|
}
|
||||||
} _MotionBlurThresholdWrapper;
|
} _MotionBlurThresholdWrapper;
|
||||||
|
|
||||||
/// Fanlight
|
/// Fanlight
|
||||||
struct CFanLightWrapper : public IPSWrapperUInt
|
struct CFanLightWrapper : public IPSWrapperUInt
|
||||||
{
|
{
|
||||||
NL3D::CPSFanLight *P;
|
NL3D::CPSFanLight *P;
|
||||||
uint32 get(void) const { return P->getNbFans(); }
|
uint32 get(void) const
|
||||||
void set(const uint32 &v) { P->setNbFans(v); }
|
{
|
||||||
|
return P->getNbFans();
|
||||||
|
}
|
||||||
|
void set(const uint32 &v)
|
||||||
|
{
|
||||||
|
P->setNbFans(v);
|
||||||
|
}
|
||||||
} _FanLightWrapper;
|
} _FanLightWrapper;
|
||||||
|
|
||||||
struct CFanLightSmoothnessWrapper : public IPSWrapperUInt
|
struct CFanLightSmoothnessWrapper : public IPSWrapperUInt
|
||||||
{
|
{
|
||||||
NL3D::CPSFanLight *P;
|
NL3D::CPSFanLight *P;
|
||||||
uint32 get(void) const { return P->getPhaseSmoothness(); }
|
uint32 get(void) const
|
||||||
void set(const uint32 &v) { P->setPhaseSmoothness(v); }
|
{
|
||||||
|
return P->getPhaseSmoothness();
|
||||||
|
}
|
||||||
|
void set(const uint32 &v)
|
||||||
|
{
|
||||||
|
P->setPhaseSmoothness(v);
|
||||||
|
}
|
||||||
} _FanLightSmoothnessWrapper;
|
} _FanLightSmoothnessWrapper;
|
||||||
|
|
||||||
struct CFanLightPhase : public IPSWrapperFloat
|
struct CFanLightPhase : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSFanLight *P;
|
NL3D::CPSFanLight *P;
|
||||||
float get(void) const { return P->getPhaseSpeed(); }
|
float get(void) const
|
||||||
void set(const float &v) { P->setPhaseSpeed(v); }
|
{
|
||||||
|
return P->getPhaseSpeed();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
P->setPhaseSpeed(v);
|
||||||
|
}
|
||||||
} _FanLightPhaseWrapper;
|
} _FanLightPhaseWrapper;
|
||||||
|
|
||||||
struct CFanLightIntensityWrapper : public IPSWrapperFloat
|
struct CFanLightIntensityWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSFanLight *P;
|
NL3D::CPSFanLight *P;
|
||||||
float get(void) const { return P->getMoveIntensity(); }
|
float get(void) const
|
||||||
void set(const float &v) { P->setMoveIntensity(v); }
|
{
|
||||||
|
return P->getMoveIntensity();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
P->setMoveIntensity(v);
|
||||||
|
}
|
||||||
} _FanLightIntensityWrapper;
|
} _FanLightIntensityWrapper;
|
||||||
|
|
||||||
/// Ribbon / tail dot
|
/// Ribbon / tail dot
|
||||||
struct CTailParticleWrapper : public IPSWrapperUInt
|
struct CTailParticleWrapper : public IPSWrapperUInt
|
||||||
{
|
{
|
||||||
NL3D::CPSTailParticle *P;
|
NL3D::CPSTailParticle *P;
|
||||||
uint32 get(void) const { return P->getTailNbSeg(); }
|
uint32 get(void) const
|
||||||
void set(const uint32 &v) { P->setTailNbSeg(v); }
|
{
|
||||||
|
return P->getTailNbSeg();
|
||||||
|
}
|
||||||
|
void set(const uint32 &v)
|
||||||
|
{
|
||||||
|
P->setTailNbSeg(v);
|
||||||
|
}
|
||||||
} _TailParticleWrapper;
|
} _TailParticleWrapper;
|
||||||
|
|
||||||
/// Duration of segment for a ribbon
|
/// Duration of segment for a ribbon
|
||||||
struct CSegDurationWrapper : public IPSWrapperFloat
|
struct CSegDurationWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSRibbonBase *R;
|
NL3D::CPSRibbonBase *R;
|
||||||
float get(void) const { return R->getSegDuration(); }
|
float get(void) const
|
||||||
void set(const float &v) { R->setSegDuration(v); }
|
{
|
||||||
|
return R->getSegDuration();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
R->setSegDuration(v);
|
||||||
|
}
|
||||||
} _SegDurationWrapper;
|
} _SegDurationWrapper;
|
||||||
|
|
||||||
/// Shockwave
|
/// Shockwave
|
||||||
struct CRadiusCutWrapper : public IPSWrapperFloat
|
struct CRadiusCutWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSShockWave *S;
|
NL3D::CPSShockWave *S;
|
||||||
float get(void) const { return S->getRadiusCut(); }
|
float get(void) const
|
||||||
void set(const float &v) { S->setRadiusCut(v); }
|
{
|
||||||
|
return S->getRadiusCut();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
S->setRadiusCut(v);
|
||||||
|
}
|
||||||
} _RadiusCutWrapper;
|
} _RadiusCutWrapper;
|
||||||
|
|
||||||
struct CShockWaveNbSegWrapper : public IPSWrapperUInt
|
struct CShockWaveNbSegWrapper : public IPSWrapperUInt
|
||||||
{
|
{
|
||||||
NL3D::CPSShockWave *S;
|
NL3D::CPSShockWave *S;
|
||||||
uint32 get(void) const { return S->getNbSegs(); }
|
uint32 get(void) const
|
||||||
void set(const uint32 &v) { S->setNbSegs(v); }
|
{
|
||||||
|
return S->getNbSegs();
|
||||||
|
}
|
||||||
|
void set(const uint32 &v)
|
||||||
|
{
|
||||||
|
S->setNbSegs(v);
|
||||||
|
}
|
||||||
} _ShockWaveNbSegWrapper;
|
} _ShockWaveNbSegWrapper;
|
||||||
|
|
||||||
struct CShockWaveUFactorWrapper : public IPSWrapperFloat
|
struct CShockWaveUFactorWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSShockWave *S;
|
NL3D::CPSShockWave *S;
|
||||||
float get(void) const { return S->getUFactor(); }
|
float get(void) const
|
||||||
void set(const float &v) { S->setUFactor(v); }
|
{
|
||||||
|
return S->getUFactor();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
S->setUFactor(v);
|
||||||
|
}
|
||||||
} _ShockWaveUFactorWrapper;
|
} _ShockWaveUFactorWrapper;
|
||||||
|
|
||||||
/// Unanimated texture
|
/// Unanimated texture
|
||||||
struct CTextureNoAnimWrapper : public IPSWrapperTexture
|
struct CTextureNoAnimWrapper : public IPSWrapperTexture
|
||||||
{
|
{
|
||||||
NL3D::CPSTexturedParticleNoAnim *TP;
|
NL3D::CPSTexturedParticleNoAnim *TP;
|
||||||
virtual NL3D::ITexture *get(void) { return TP->getTexture(); }
|
virtual NL3D::ITexture *get(void)
|
||||||
virtual void set(NL3D::ITexture *t) { TP->setTexture(t); }
|
{
|
||||||
|
return TP->getTexture();
|
||||||
|
}
|
||||||
|
virtual void set(NL3D::ITexture *t)
|
||||||
|
{
|
||||||
|
TP->setTexture(t);
|
||||||
|
}
|
||||||
} _TextureNoAnimWrapper;
|
} _TextureNoAnimWrapper;
|
||||||
|
|
||||||
/// u / v factors for ribbon
|
/// u / v factors for ribbon
|
||||||
struct CRibbonUFactorWrapper : public IPSWrapperFloat
|
struct CRibbonUFactorWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSRibbon *R;
|
NL3D::CPSRibbon *R;
|
||||||
float get(void) const { return R->getUFactor(); }
|
float get(void) const
|
||||||
void set(const float &u) { R->setTexFactor(u, R->getVFactor()); }
|
{
|
||||||
|
return R->getUFactor();
|
||||||
|
}
|
||||||
|
void set(const float &u)
|
||||||
|
{
|
||||||
|
R->setTexFactor(u, R->getVFactor());
|
||||||
|
}
|
||||||
} _RibbonUFactorWrapper;
|
} _RibbonUFactorWrapper;
|
||||||
|
|
||||||
struct CRibbonVFactorWrapper : public IPSWrapperFloat
|
struct CRibbonVFactorWrapper : public IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSRibbon *R;
|
NL3D::CPSRibbon *R;
|
||||||
float get(void) const { return R->getVFactor(); }
|
float get(void) const
|
||||||
void set(const float &v) { R->setTexFactor(R->getUFactor(), v); }
|
{
|
||||||
|
return R->getVFactor();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
R->setTexFactor(R->getUFactor(), v);
|
||||||
|
}
|
||||||
} _RibbonVFactorWrapper;
|
} _RibbonVFactorWrapper;
|
||||||
|
|
||||||
struct CRibbonLengthWrapper : IPSWrapperFloat
|
struct CRibbonLengthWrapper : IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSRibbonBase *R;
|
NL3D::CPSRibbonBase *R;
|
||||||
float get() const { return R->getRibbonLength(); }
|
float get() const
|
||||||
void set(const float &v) { R->setRibbonLength(v); }
|
{
|
||||||
|
return R->getRibbonLength();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
R->setRibbonLength(v);
|
||||||
|
}
|
||||||
} _RibbonLengthWrapper;
|
} _RibbonLengthWrapper;
|
||||||
|
|
||||||
|
|
||||||
struct CLODDegradationWrapper : IPSWrapperFloat
|
struct CLODDegradationWrapper : IPSWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSRibbonBase *R;
|
NL3D::CPSRibbonBase *R;
|
||||||
float get() const { return R->getLODDegradation(); }
|
float get() const
|
||||||
void set(const float &v) { R->setLODDegradation(v); }
|
{
|
||||||
|
return R->getLODDegradation();
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
R->setLODDegradation(v);
|
||||||
|
}
|
||||||
} _LODDegradationWrapper;
|
} _LODDegradationWrapper;
|
||||||
|
|
||||||
void updateValidWidgetForAlignOnMotion(bool align);
|
void updateValidWidgetForAlignOnMotion(bool align);
|
||||||
|
|
||||||
void updateSizeControl();
|
void updateSizeControl();
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
void hideAllWidget();
|
void hideAllWidget();
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CLocatedPage::CLocatedPage(QWidget *parent)
|
CLocatedPage::CLocatedPage(QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -36,7 +36,8 @@ namespace NL3D
|
||||||
class CPSLocated;
|
class CPSLocated;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CLocatedPage
|
@class CLocatedPage
|
||||||
|
@ -71,19 +72,37 @@ private:
|
||||||
struct CMassWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CMassWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSLocated *Located;
|
NL3D::CPSLocated *Located;
|
||||||
float get(void) const { return Located->getInitialMass(); }
|
float get(void) const
|
||||||
void set(const float &v) { Located->setInitialMass(v); }
|
{
|
||||||
virtual scheme_type *getScheme(void) const { return Located->getMassScheme(); }
|
return Located->getInitialMass();
|
||||||
virtual void setScheme(scheme_type *s) { Located->setMassScheme(s); }
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
Located->setInitialMass(v);
|
||||||
|
}
|
||||||
|
virtual scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return Located->getMassScheme();
|
||||||
|
}
|
||||||
|
virtual void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
Located->setMassScheme(s);
|
||||||
|
}
|
||||||
} _MassWrapper;
|
} _MassWrapper;
|
||||||
|
|
||||||
struct CLifeWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CLifeWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSLocated *Located;
|
NL3D::CPSLocated *Located;
|
||||||
CWorkspaceNode *Node;
|
CWorkspaceNode *Node;
|
||||||
float get(void) const { return Located->getInitialLife(); }
|
float get(void) const
|
||||||
|
{
|
||||||
|
return Located->getInitialLife();
|
||||||
|
}
|
||||||
void set(const float &v);
|
void set(const float &v);
|
||||||
virtual scheme_type *getScheme(void) const { return Located->getLifeScheme(); }
|
virtual scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return Located->getLifeScheme();
|
||||||
|
}
|
||||||
virtual void setScheme(scheme_type *s);
|
virtual void setScheme(scheme_type *s);
|
||||||
} _LifeWrapper;
|
} _LifeWrapper;
|
||||||
|
|
||||||
|
@ -98,7 +117,10 @@ private:
|
||||||
/// update the 'trigger on death' control
|
/// update the 'trigger on death' control
|
||||||
void updateTriggerOnDeath(void);
|
void updateTriggerOnDeath(void);
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
Ui::CLocatedPage _ui;
|
Ui::CLocatedPage _ui;
|
||||||
}; /* class CLocatedPage */
|
}; /* class CLocatedPage */
|
||||||
|
|
|
@ -32,9 +32,11 @@
|
||||||
using namespace std;
|
using namespace std;
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
namespace {
|
namespace
|
||||||
|
{
|
||||||
|
|
||||||
CFileDisplayer *s_FileDisplayer = NULL;
|
CFileDisplayer *s_FileDisplayer = NULL;
|
||||||
|
|
||||||
|
|
|
@ -49,7 +49,8 @@
|
||||||
using namespace std;
|
using namespace std;
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CMainWindow::CMainWindow(QWidget *parent)
|
CMainWindow::CMainWindow(QWidget *parent)
|
||||||
: QMainWindow(parent),
|
: QMainWindow(parent),
|
||||||
|
@ -298,7 +299,8 @@ void CMainWindow::updateInitialization(bool visible)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
} while (!done);
|
}
|
||||||
|
while (!done);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CMainWindow::createActions()
|
void CMainWindow::createActions()
|
||||||
|
|
|
@ -30,11 +30,13 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLMISC {
|
namespace NLMISC
|
||||||
|
{
|
||||||
class CConfigFile;
|
class CConfigFile;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CGraphicsViewport;
|
class CGraphicsViewport;
|
||||||
class CAnimationDialog;
|
class CAnimationDialog;
|
||||||
|
@ -63,7 +65,9 @@ public:
|
||||||
|
|
||||||
int getFrameRate();
|
int getFrameRate();
|
||||||
CSkeletonTreeModel *getSkeletonModel() const
|
CSkeletonTreeModel *getSkeletonModel() const
|
||||||
{ return _SkeletonTreeModel; }
|
{
|
||||||
|
return _SkeletonTreeModel;
|
||||||
|
}
|
||||||
|
|
||||||
private Q_SLOTS:
|
private Q_SLOTS:
|
||||||
void open();
|
void open();
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
#include "mesh_widget.h"
|
#include "mesh_widget.h"
|
||||||
#include "morph_mesh_dialog.h"
|
#include "morph_mesh_dialog.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CMeshWidget::CMeshWidget(QWidget *parent)
|
CMeshWidget::CMeshWidget(QWidget *parent)
|
||||||
: QGroupBox(parent)
|
: QGroupBox(parent)
|
||||||
|
@ -185,9 +186,12 @@ QString CMeshWidget::getShapeErrorString(sint errorCode)
|
||||||
{
|
{
|
||||||
switch(errorCode)
|
switch(errorCode)
|
||||||
{
|
{
|
||||||
case NL3D::CPSConstraintMesh::ShapeFileIsNotAMesh: return tr("Not a mesh");
|
case NL3D::CPSConstraintMesh::ShapeFileIsNotAMesh:
|
||||||
case NL3D::CPSConstraintMesh::ShapeFileNotLoaded: return tr("Shape not loaded");
|
return tr("Not a mesh");
|
||||||
case NL3D::CPSConstraintMesh::ShapeHasTooMuchVertices: return tr("Too much vertices");
|
case NL3D::CPSConstraintMesh::ShapeFileNotLoaded:
|
||||||
|
return tr("Shape not loaded");
|
||||||
|
case NL3D::CPSConstraintMesh::ShapeHasTooMuchVertices:
|
||||||
|
return tr("Too much vertices");
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
};
|
};
|
||||||
|
|
|
@ -36,7 +36,8 @@ namespace NL3D
|
||||||
struct CPSShapeParticle;
|
struct CPSShapeParticle;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CMeshWidget: public QGroupBox
|
class CMeshWidget: public QGroupBox
|
||||||
{
|
{
|
||||||
|
@ -64,7 +65,10 @@ private:
|
||||||
|
|
||||||
void updateMeshErrorString();
|
void updateMeshErrorString();
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
void touchPSState();
|
void touchPSState();
|
||||||
|
|
||||||
|
|
|
@ -41,12 +41,18 @@ void Modules::init()
|
||||||
|
|
||||||
void Modules::release()
|
void Modules::release()
|
||||||
{
|
{
|
||||||
delete _mainWindow; _mainWindow = NULL;
|
delete _mainWindow;
|
||||||
delete _particleEditor; _particleEditor = NULL;
|
_mainWindow = NULL;
|
||||||
delete _vegetableEditor; _vegetableEditor = NULL;
|
delete _particleEditor;
|
||||||
delete _soundSystem; _soundSystem = NULL;
|
_particleEditor = NULL;
|
||||||
delete _objectViewer; _objectViewer = NULL;
|
delete _vegetableEditor;
|
||||||
|
_vegetableEditor = NULL;
|
||||||
|
delete _soundSystem;
|
||||||
|
_soundSystem = NULL;
|
||||||
|
delete _objectViewer;
|
||||||
|
_objectViewer = NULL;
|
||||||
|
|
||||||
config().release();
|
config().release();
|
||||||
delete _configuration; _configuration = NULL;
|
delete _configuration;
|
||||||
|
_configuration = NULL;
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,12 +37,30 @@ public:
|
||||||
static void init();
|
static void init();
|
||||||
static void release();
|
static void release();
|
||||||
|
|
||||||
static NLQT::CConfiguration &config() { return *_configuration; }
|
static NLQT::CConfiguration &config()
|
||||||
static NLQT::CObjectViewer &objView() { return *_objectViewer; }
|
{
|
||||||
static NLQT::CMainWindow &mainWin() { return *_mainWindow; }
|
return *_configuration;
|
||||||
static NLQT::CParticleEditor &psEdit() { return *_particleEditor; }
|
}
|
||||||
static NLQT::CSoundSystem &sound() { return *_soundSystem; }
|
static NLQT::CObjectViewer &objView()
|
||||||
static NLQT::CVegetableEditor &veget() { return *_vegetableEditor; }
|
{
|
||||||
|
return *_objectViewer;
|
||||||
|
}
|
||||||
|
static NLQT::CMainWindow &mainWin()
|
||||||
|
{
|
||||||
|
return *_mainWindow;
|
||||||
|
}
|
||||||
|
static NLQT::CParticleEditor &psEdit()
|
||||||
|
{
|
||||||
|
return *_particleEditor;
|
||||||
|
}
|
||||||
|
static NLQT::CSoundSystem &sound()
|
||||||
|
{
|
||||||
|
return *_soundSystem;
|
||||||
|
}
|
||||||
|
static NLQT::CVegetableEditor &veget()
|
||||||
|
{
|
||||||
|
return *_vegetableEditor;
|
||||||
|
}
|
||||||
private:
|
private:
|
||||||
static NLQT::CConfiguration *_configuration;
|
static NLQT::CConfiguration *_configuration;
|
||||||
static NLQT::CObjectViewer *_objectViewer;
|
static NLQT::CObjectViewer *_objectViewer;
|
||||||
|
|
|
@ -30,7 +30,8 @@
|
||||||
// Projects includes
|
// Projects includes
|
||||||
#include "mesh_widget.h"
|
#include "mesh_widget.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CMorphMeshDialog::CMorphMeshDialog(CWorkspaceNode *ownerNode, NL3D::CPSConstraintMesh *cm, QWidget *parent)
|
CMorphMeshDialog::CMorphMeshDialog(CWorkspaceNode *ownerNode, NL3D::CPSConstraintMesh *cm, QWidget *parent)
|
||||||
: QDialog(parent), _Node(ownerNode), _CM(cm)
|
: QDialog(parent), _Node(ownerNode), _CM(cm)
|
||||||
|
|
|
@ -36,7 +36,8 @@ namespace NL3D
|
||||||
class CPSConstraintMesh;
|
class CPSConstraintMesh;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CMorphMeshDialog: public QDialog
|
class CMorphMeshDialog: public QDialog
|
||||||
{
|
{
|
||||||
|
|
|
@ -27,7 +27,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CMultiTexDialog::CMultiTexDialog(CWorkspaceNode *ownerNode, NL3D::CPSMultiTexturedParticle *mtp, QWidget *parent)
|
CMultiTexDialog::CMultiTexDialog(CWorkspaceNode *ownerNode, NL3D::CPSMultiTexturedParticle *mtp, QWidget *parent)
|
||||||
: QDialog(parent), _Node(ownerNode), _MTP(mtp)
|
: QDialog(parent), _Node(ownerNode), _MTP(mtp)
|
||||||
|
|
|
@ -37,7 +37,8 @@ namespace NL3D
|
||||||
class CPSMultiTexturedParticle;
|
class CPSMultiTexturedParticle;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CWorkspaceNode;
|
class CWorkspaceNode;
|
||||||
|
|
||||||
|
@ -79,7 +80,10 @@ private:
|
||||||
NL3D::CPSMultiTexturedParticle *_MTP;
|
NL3D::CPSMultiTexturedParticle *_MTP;
|
||||||
|
|
||||||
void readValues();
|
void readValues();
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
Ui::CMultiTexDialog _ui;
|
Ui::CMultiTexDialog _ui;
|
||||||
}; /* class CMultiTexDialog */
|
}; /* class CMultiTexDialog */
|
||||||
|
|
|
@ -50,7 +50,8 @@ using namespace std;
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
using namespace NL3D;
|
using namespace NL3D;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CObjectViewer::CObjectViewer()
|
CObjectViewer::CObjectViewer()
|
||||||
: _Driver(NULL), _TextContext(NULL),
|
: _Driver(NULL), _TextContext(NULL),
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "entity.h"
|
#include "entity.h"
|
||||||
|
|
||||||
namespace NL3D {
|
namespace NL3D
|
||||||
|
{
|
||||||
class UDriver;
|
class UDriver;
|
||||||
class UScene;
|
class UScene;
|
||||||
class ULight;
|
class ULight;
|
||||||
|
@ -46,7 +47,8 @@ namespace NL3D {
|
||||||
class U3dMouseListener;
|
class U3dMouseListener;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CObjectViewer
|
@class CObjectViewer
|
||||||
|
@ -132,7 +134,10 @@ public:
|
||||||
/// @param h - height window.
|
/// @param h - height window.
|
||||||
void setSizeViewport(uint16 w, uint16 h);
|
void setSizeViewport(uint16 w, uint16 h);
|
||||||
|
|
||||||
void setBloomEffect(bool enabled) { _BloomEffect = enabled; }
|
void setBloomEffect(bool enabled)
|
||||||
|
{
|
||||||
|
_BloomEffect = enabled;
|
||||||
|
}
|
||||||
|
|
||||||
/// Select instance from the scene
|
/// Select instance from the scene
|
||||||
/// @param name - name instance, "" if no instance edited
|
/// @param name - name instance, "" if no instance edited
|
||||||
|
@ -140,7 +145,10 @@ public:
|
||||||
|
|
||||||
/// Get current instance from the scene
|
/// Get current instance from the scene
|
||||||
/// @return name current instance, "" if no instance edited
|
/// @return name current instance, "" if no instance edited
|
||||||
const std::string& getCurrentObject() { return _CurrentInstance; }
|
const std::string& getCurrentObject()
|
||||||
|
{
|
||||||
|
return _CurrentInstance;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get entity from the scene
|
/// Get entity from the scene
|
||||||
/// @return ref Entity
|
/// @return ref Entity
|
||||||
|
@ -152,33 +160,57 @@ public:
|
||||||
|
|
||||||
/// Get value background color.
|
/// Get value background color.
|
||||||
/// @return background color.
|
/// @return background color.
|
||||||
inline NLMISC::CRGBA getBackgroundColor() const { return _BackgroundColor; }
|
inline NLMISC::CRGBA getBackgroundColor() const
|
||||||
|
{
|
||||||
|
return _BackgroundColor;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get type driver.
|
/// Get type driver.
|
||||||
/// @return true if have used Direct3D driver, false OpenGL driver.
|
/// @return true if have used Direct3D driver, false OpenGL driver.
|
||||||
inline bool getDirect3D() const { return _Direct3D; }
|
inline bool getDirect3D() const
|
||||||
|
{
|
||||||
|
return _Direct3D;
|
||||||
|
}
|
||||||
|
|
||||||
inline bool getBloomEffect() const { return _BloomEffect; }
|
inline bool getBloomEffect() const
|
||||||
|
{
|
||||||
|
return _BloomEffect;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get a game interface for window driver.
|
/// Get a game interface for window driver.
|
||||||
/// @return pointer to the driver.
|
/// @return pointer to the driver.
|
||||||
inline NL3D::UDriver *getDriver() const { return _Driver; }
|
inline NL3D::UDriver *getDriver() const
|
||||||
|
{
|
||||||
|
return _Driver;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get a game interface for scene.
|
/// Get a game interface for scene.
|
||||||
/// @return pointer to the scene.
|
/// @return pointer to the scene.
|
||||||
inline NL3D::UScene *getScene() const { return _Scene; }
|
inline NL3D::UScene *getScene() const
|
||||||
|
{
|
||||||
|
return _Scene;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get a manager of playlist
|
/// Get a manager of playlist
|
||||||
/// @return pointer to the UPlayListManager
|
/// @return pointer to the UPlayListManager
|
||||||
inline NL3D::UPlayListManager *getPlayListManager() const { return _PlayListManager; }
|
inline NL3D::UPlayListManager *getPlayListManager() const
|
||||||
|
{
|
||||||
|
return _PlayListManager;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get a game interface to render string
|
/// Get a game interface to render string
|
||||||
/// @return pointer to the UPlayListManager
|
/// @return pointer to the UPlayListManager
|
||||||
inline NL3D::UTextContext *getTextContext() const { return _TextContext; }
|
inline NL3D::UTextContext *getTextContext() const
|
||||||
|
{
|
||||||
|
return _TextContext;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get a 3d mouse listener
|
/// Get a 3d mouse listener
|
||||||
/// @return pointer to the U3dMouseListener
|
/// @return pointer to the U3dMouseListener
|
||||||
inline NL3D::U3dMouseListener *get3dMouseListener() const { return _MouseListener; }
|
inline NL3D::U3dMouseListener *get3dMouseListener() const
|
||||||
|
{
|
||||||
|
return _MouseListener;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void loadConfig();
|
void loadConfig();
|
||||||
|
|
|
@ -32,7 +32,8 @@
|
||||||
#include "particle_link_skeleton_dialog.h"
|
#include "particle_link_skeleton_dialog.h"
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CParticleControlDialog::CParticleControlDialog(CSkeletonTreeModel *model, QWidget *parent)
|
CParticleControlDialog::CParticleControlDialog(CSkeletonTreeModel *model, QWidget *parent)
|
||||||
: QDockWidget(parent)
|
: QDockWidget(parent)
|
||||||
|
|
|
@ -25,7 +25,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CSkeletonTreeModel;
|
class CSkeletonTreeModel;
|
||||||
class CParticleLinkDialog;
|
class CParticleLinkDialog;
|
||||||
|
|
|
@ -31,7 +31,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CParticleEditor::CParticleEditor(void):
|
CParticleEditor::CParticleEditor(void):
|
||||||
_ActiveNode(NULL), _State(State::Stopped), _Speed(1.0f),
|
_ActiveNode(NULL), _State(State::Stopped), _Speed(1.0f),
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
// Projects includes
|
// Projects includes
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NL3D {
|
namespace NL3D
|
||||||
|
{
|
||||||
class CParticleSystem;
|
class CParticleSystem;
|
||||||
class CParticleSystemModel;
|
class CParticleSystemModel;
|
||||||
class CShapeBank;
|
class CShapeBank;
|
||||||
|
@ -44,7 +45,8 @@ namespace NL3D {
|
||||||
class CFontGenerator;
|
class CFontGenerator;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
/**
|
/**
|
||||||
@class CParticleEditor
|
@class CParticleEditor
|
||||||
@brief The main class of the particles editor.
|
@brief The main class of the particles editor.
|
||||||
|
@ -84,10 +86,16 @@ public:
|
||||||
void setActiveNode(CWorkspaceNode *node);
|
void setActiveNode(CWorkspaceNode *node);
|
||||||
|
|
||||||
/// Get the node of the workspace that is currently active
|
/// Get the node of the workspace that is currently active
|
||||||
CWorkspaceNode *getActiveNode() const { return _ActiveNode; }
|
CWorkspaceNode *getActiveNode() const
|
||||||
|
{
|
||||||
|
return _ActiveNode;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get the particle system model that is currently active
|
/// Get the particle system model that is currently active
|
||||||
NL3D::CParticleSystemModel *getActivePSM() const { return _ActiveNode ? _ActiveNode->getPSModel() : NULL; }
|
NL3D::CParticleSystemModel *getActivePSM() const
|
||||||
|
{
|
||||||
|
return _ActiveNode ? _ActiveNode->getPSModel() : NULL;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get a model from a ps pointer. The ps must belong to the workspace
|
/// Get a model from a ps pointer. The ps must belong to the workspace
|
||||||
NL3D::CParticleSystemModel *getModelFromPS(NL3D::CParticleSystem *ps) const;
|
NL3D::CParticleSystemModel *getModelFromPS(NL3D::CParticleSystem *ps) const;
|
||||||
|
@ -126,14 +134,26 @@ public:
|
||||||
|
|
||||||
void setDisplayBBox(bool enable);
|
void setDisplayBBox(bool enable);
|
||||||
|
|
||||||
void setDisplayHelpers(bool enable) { _DisplayHelpers = enable; }
|
void setDisplayHelpers(bool enable)
|
||||||
|
{
|
||||||
|
_DisplayHelpers = enable;
|
||||||
|
}
|
||||||
|
|
||||||
void setAutoRepeat(bool enable) { _AutoRepeat = enable; }
|
void setAutoRepeat(bool enable)
|
||||||
|
{
|
||||||
|
_AutoRepeat = enable;
|
||||||
|
}
|
||||||
|
|
||||||
/// Auto bbox for fx
|
/// Auto bbox for fx
|
||||||
void setAutoBBox(bool enable) { _AutoUpdateBBox = enable; }
|
void setAutoBBox(bool enable)
|
||||||
|
{
|
||||||
|
_AutoUpdateBBox = enable;
|
||||||
|
}
|
||||||
|
|
||||||
bool getAutoBBox() const { return _AutoUpdateBBox; }
|
bool getAutoBBox() const
|
||||||
|
{
|
||||||
|
return _AutoUpdateBBox;
|
||||||
|
}
|
||||||
|
|
||||||
/// Enable / disbale auto-count
|
/// Enable / disbale auto-count
|
||||||
void enableAutoCount(bool enable);
|
void enableAutoCount(bool enable);
|
||||||
|
@ -142,13 +162,22 @@ public:
|
||||||
void resetAutoCount(CWorkspaceNode *node, bool reset = true);
|
void resetAutoCount(CWorkspaceNode *node, bool reset = true);
|
||||||
|
|
||||||
/// Reset the auto compute bbox
|
/// Reset the auto compute bbox
|
||||||
void resetAutoBBox() { _EmptyBBox = true; }
|
void resetAutoBBox()
|
||||||
|
{
|
||||||
|
_EmptyBBox = true;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get current state
|
/// Get current state
|
||||||
int getState() const { return _State; }
|
int getState() const
|
||||||
|
{
|
||||||
|
return _State;
|
||||||
|
}
|
||||||
|
|
||||||
/// Return true if one or several system are being played
|
/// Return true if one or several system are being played
|
||||||
bool isRunning() const { return _State == State::RunningSingle || _State == State::RunningMultiple; }
|
bool isRunning() const
|
||||||
|
{
|
||||||
|
return _State == State::RunningSingle || _State == State::RunningMultiple;
|
||||||
|
}
|
||||||
|
|
||||||
/// Return true if a system is paused.
|
/// Return true if a system is paused.
|
||||||
/// Must call only if running
|
/// Must call only if running
|
||||||
|
@ -157,17 +186,32 @@ public:
|
||||||
return _State == State::PausedSingle || _State == State::PausedMultiple;
|
return _State == State::PausedSingle || _State == State::PausedMultiple;
|
||||||
}
|
}
|
||||||
|
|
||||||
CParticleWorkspace *getParticleWorkspace() const { return _PW; }
|
CParticleWorkspace *getParticleWorkspace() const
|
||||||
|
{
|
||||||
|
return _PW;
|
||||||
|
}
|
||||||
|
|
||||||
NL3D::IDriver *getDriver() const { return _Driver; }
|
NL3D::IDriver *getDriver() const
|
||||||
|
{
|
||||||
|
return _Driver;
|
||||||
|
}
|
||||||
|
|
||||||
NL3D::CScene *getScene() const { return _Scene; }
|
NL3D::CScene *getScene() const
|
||||||
|
{
|
||||||
|
return _Scene;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get the fontManager
|
/// Get the fontManager
|
||||||
NL3D::CFontManager *getFontManager() const {return _FontManager;}
|
NL3D::CFontManager *getFontManager() const
|
||||||
|
{
|
||||||
|
return _FontManager;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get the fontGenerator
|
/// Get the fontGenerator
|
||||||
NL3D::CFontGenerator *getFontGenerator () const { return _FontGen; }
|
NL3D::CFontGenerator *getFontGenerator () const
|
||||||
|
{
|
||||||
|
return _FontGen;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
// Check if a node is inserted in the running list (it may be paused)
|
// Check if a node is inserted in the running list (it may be paused)
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CForcePage::CForcePage(QWidget *parent)
|
CForcePage::CForcePage(QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -33,7 +33,8 @@
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CLocatedItem
|
@class CLocatedItem
|
||||||
|
@ -45,8 +46,14 @@ public:
|
||||||
CLocatedItem ( const QString & text, QListWidget * parent = 0, int type = UserType ):
|
CLocatedItem ( const QString & text, QListWidget * parent = 0, int type = UserType ):
|
||||||
QListWidgetItem(text, parent, type), _loc(NULL) {}
|
QListWidgetItem(text, parent, type), _loc(NULL) {}
|
||||||
|
|
||||||
void setUserData(NL3D::CPSLocated *loc) { _loc = loc;}
|
void setUserData(NL3D::CPSLocated *loc)
|
||||||
NL3D::CPSLocated *getUserData() const { return _loc;}
|
{
|
||||||
|
_loc = loc;
|
||||||
|
}
|
||||||
|
NL3D::CPSLocated *getUserData() const
|
||||||
|
{
|
||||||
|
return _loc;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
|
@ -84,17 +91,32 @@ private:
|
||||||
struct CForceIntensityWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CForceIntensityWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSForceIntensity *F;
|
NL3D::CPSForceIntensity *F;
|
||||||
float get(void) const { return F->getIntensity(); }
|
float get(void) const
|
||||||
void set(const float &value) {F->setIntensity(value); }
|
{
|
||||||
scheme_type *getScheme(void) const { return F->getIntensityScheme(); }
|
return F->getIntensity();
|
||||||
void setScheme(scheme_type *s) {F->setIntensityScheme(s); }
|
}
|
||||||
|
void set(const float &value)
|
||||||
|
{
|
||||||
|
F->setIntensity(value);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return F->getIntensityScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
F->setIntensityScheme(s);
|
||||||
|
}
|
||||||
} _ForceIntensityWrapper;
|
} _ForceIntensityWrapper;
|
||||||
|
|
||||||
void hideAdditionalWidget();
|
void hideAdditionalWidget();
|
||||||
|
|
||||||
void updateTargets();
|
void updateTargets();
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
// the target we're focusing on
|
// the target we're focusing on
|
||||||
NL3D::CPSTargetLocatedBindable *_LBTarget;
|
NL3D::CPSTargetLocatedBindable *_LBTarget;
|
||||||
|
|
|
@ -27,7 +27,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CLightPage::CLightPage(QWidget *parent)
|
CLightPage::CLightPage(QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -32,7 +32,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CLightPage
|
@class CLightPage
|
||||||
|
@ -56,30 +57,66 @@ private:
|
||||||
struct CColorWrapper : public IPSWrapperRGBA, IPSSchemeWrapperRGBA
|
struct CColorWrapper : public IPSWrapperRGBA, IPSSchemeWrapperRGBA
|
||||||
{
|
{
|
||||||
NL3D::CPSLight *L;
|
NL3D::CPSLight *L;
|
||||||
NLMISC::CRGBA get(void) const { return L->getColor(); }
|
NLMISC::CRGBA get(void) const
|
||||||
void set(const NLMISC::CRGBA &v) { L->setColor(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return L->getColorScheme(); }
|
return L->getColor();
|
||||||
void setScheme(scheme_type *s) { L->setColorScheme(s); }
|
}
|
||||||
|
void set(const NLMISC::CRGBA &v)
|
||||||
|
{
|
||||||
|
L->setColor(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return L->getColorScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
L->setColorScheme(s);
|
||||||
|
}
|
||||||
} _ColorWrapper;
|
} _ColorWrapper;
|
||||||
|
|
||||||
/// wrapper to set start atten radius
|
/// wrapper to set start atten radius
|
||||||
struct CAttenStartWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CAttenStartWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSLight *L;
|
NL3D::CPSLight *L;
|
||||||
float get(void) const { return L->getAttenStart(); }
|
float get(void) const
|
||||||
void set(const float &v) { L->setAttenStart(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return L->getAttenStartScheme(); }
|
return L->getAttenStart();
|
||||||
void setScheme(scheme_type *s) { L->setAttenStartScheme(s); }
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
L->setAttenStart(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return L->getAttenStartScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
L->setAttenStartScheme(s);
|
||||||
|
}
|
||||||
} _AttenStartWrapper;
|
} _AttenStartWrapper;
|
||||||
|
|
||||||
/// wrapper to set end atten radius
|
/// wrapper to set end atten radius
|
||||||
struct CAttenEndWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CAttenEndWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSLight *L;
|
NL3D::CPSLight *L;
|
||||||
float get(void) const { return L->getAttenEnd(); }
|
float get(void) const
|
||||||
void set(const float &v) { L->setAttenEnd(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return L->getAttenEndScheme(); }
|
return L->getAttenEnd();
|
||||||
void setScheme(scheme_type *s) { L->setAttenEndScheme(s); }
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
L->setAttenEnd(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return L->getAttenEndScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
L->setAttenEndScheme(s);
|
||||||
|
}
|
||||||
} _AttenEndWrapper;
|
} _AttenEndWrapper;
|
||||||
|
|
||||||
NL3D::CPSLight *_Light;
|
NL3D::CPSLight *_Light;
|
||||||
|
|
|
@ -27,7 +27,8 @@
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CParticleLinkDialog::CParticleLinkDialog(CSkeletonTreeModel *model, QWidget *parent)
|
CParticleLinkDialog::CParticleLinkDialog(CSkeletonTreeModel *model, QWidget *parent)
|
||||||
: QDockWidget(parent)
|
: QDockWidget(parent)
|
||||||
|
|
|
@ -29,7 +29,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "skeleton_tree_model.h"
|
#include "skeleton_tree_model.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CParticleLinkDialog: public QDockWidget
|
class CParticleLinkDialog: public QDockWidget
|
||||||
{
|
{
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
using namespace NL3D;
|
using namespace NL3D;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CWorkspaceNode::CWorkspaceNode()
|
CWorkspaceNode::CWorkspaceNode()
|
||||||
{
|
{
|
||||||
|
|
|
@ -32,13 +32,15 @@
|
||||||
#include "ps_initial_pos.h"
|
#include "ps_initial_pos.h"
|
||||||
|
|
||||||
|
|
||||||
namespace NL3D {
|
namespace NL3D
|
||||||
|
{
|
||||||
class CParticleSystem;
|
class CParticleSystem;
|
||||||
class CParticleSystemModel;
|
class CParticleSystemModel;
|
||||||
class CShapeBank;
|
class CShapeBank;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CParticleWorkspace;
|
class CParticleWorkspace;
|
||||||
|
|
||||||
|
@ -62,11 +64,17 @@ public:
|
||||||
|
|
||||||
void setRelativePath(const std::string &relativePath);
|
void setRelativePath(const std::string &relativePath);
|
||||||
|
|
||||||
const std::string &getRelativePath() const { return _RelativePath; }
|
const std::string &getRelativePath() const
|
||||||
|
{
|
||||||
|
return _RelativePath;
|
||||||
|
}
|
||||||
|
|
||||||
std::string getFullPath() const;
|
std::string getFullPath() const;
|
||||||
|
|
||||||
std::string getFilename() const { return NLMISC::CFile::getFilename(_RelativePath); }
|
std::string getFilename() const
|
||||||
|
{
|
||||||
|
return NLMISC::CFile::getFilename(_RelativePath);
|
||||||
|
}
|
||||||
|
|
||||||
/// Serial node information into workspace stream. This does not save the particle system shape, only a reference to its file
|
/// Serial node information into workspace stream. This does not save the particle system shape, only a reference to its file
|
||||||
void serial(NLMISC::IStream &f);
|
void serial(NLMISC::IStream &f);
|
||||||
|
@ -89,17 +97,32 @@ public:
|
||||||
|
|
||||||
/// Helper flag to know if a ps has been modified
|
/// Helper flag to know if a ps has been modified
|
||||||
/// @{
|
/// @{
|
||||||
bool isModified() const { return _Modified; }
|
bool isModified() const
|
||||||
|
{
|
||||||
|
return _Modified;
|
||||||
|
}
|
||||||
void setModified(bool modified);
|
void setModified(bool modified);
|
||||||
/// @}
|
/// @}
|
||||||
NL3D::CParticleSystem *getPSPointer() const { return _PS; }
|
NL3D::CParticleSystem *getPSPointer() const
|
||||||
NL3D::CParticleSystemModel *getPSModel() const { return _PSM; }
|
{
|
||||||
|
return _PS;
|
||||||
|
}
|
||||||
|
NL3D::CParticleSystemModel *getPSModel() const
|
||||||
|
{
|
||||||
|
return _PSM;
|
||||||
|
}
|
||||||
|
|
||||||
/// See if this node ps has been loaded
|
/// See if this node ps has been loaded
|
||||||
bool isLoaded() const { return _PS != NULL; }
|
bool isLoaded() const
|
||||||
|
{
|
||||||
|
return _PS != NULL;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get the workspace in which this node is inserted
|
/// Get the workspace in which this node is inserted
|
||||||
CParticleWorkspace *getWorkspace() const { return _WS; }
|
CParticleWorkspace *getWorkspace() const
|
||||||
|
{
|
||||||
|
return _WS;
|
||||||
|
}
|
||||||
|
|
||||||
/// Memorize current position of object in the system. Useful to play the system because instances can be created / deleted
|
/// Memorize current position of object in the system. Useful to play the system because instances can be created / deleted
|
||||||
void memorizeState();
|
void memorizeState();
|
||||||
|
@ -117,13 +140,25 @@ public:
|
||||||
void removeLocatedBindable(NL3D::CPSLocatedBindable *lb);
|
void removeLocatedBindable(NL3D::CPSLocatedBindable *lb);
|
||||||
|
|
||||||
/// Returns the skeleton to which the ps is currently sticked
|
/// Returns the skeleton to which the ps is currently sticked
|
||||||
NL3D::CSkeletonModel *getParentSkel() const { return _ParentSkel; }
|
NL3D::CSkeletonModel *getParentSkel() const
|
||||||
|
{
|
||||||
|
return _ParentSkel;
|
||||||
|
}
|
||||||
|
|
||||||
const std::string &getParentSkelName() const { return _ParentSkelName; }
|
const std::string &getParentSkelName() const
|
||||||
|
{
|
||||||
|
return _ParentSkelName;
|
||||||
|
}
|
||||||
|
|
||||||
const std::string &getParentBoneName() const { return _ParentBoneName; }
|
const std::string &getParentBoneName() const
|
||||||
|
{
|
||||||
|
return _ParentBoneName;
|
||||||
|
}
|
||||||
|
|
||||||
std::string getTriggerAnim() { return _TriggerAnim; }
|
std::string getTriggerAnim()
|
||||||
|
{
|
||||||
|
return _TriggerAnim;
|
||||||
|
}
|
||||||
|
|
||||||
void setTriggerAnim(const std::string &anim);
|
void setTriggerAnim(const std::string &anim);
|
||||||
|
|
||||||
|
@ -152,8 +187,14 @@ private:
|
||||||
private:
|
private:
|
||||||
void setup(NL3D::CParticleSystemModel &psm);
|
void setup(NL3D::CParticleSystemModel &psm);
|
||||||
public:
|
public:
|
||||||
bool getResetAutoCountFlag() const { return _ResetAutoCount; }
|
bool getResetAutoCountFlag() const
|
||||||
void setResetAutoCountFlag(bool reset) { _ResetAutoCount = reset; }
|
{
|
||||||
|
return _ResetAutoCount;
|
||||||
|
}
|
||||||
|
void setResetAutoCountFlag(bool reset)
|
||||||
|
{
|
||||||
|
_ResetAutoCount = reset;
|
||||||
|
}
|
||||||
|
|
||||||
/// Stick to a skeleton
|
/// Stick to a skeleton
|
||||||
void stickPSToSkeleton(NL3D::CSkeletonModel *skel,
|
void stickPSToSkeleton(NL3D::CSkeletonModel *skel,
|
||||||
|
@ -209,18 +250,27 @@ public:
|
||||||
/// Set a new file name for the workspace
|
/// Set a new file name for the workspace
|
||||||
void setFileName(const std::string &fileName);
|
void setFileName(const std::string &fileName);
|
||||||
|
|
||||||
std::string getName() const { return _Name; }
|
std::string getName() const
|
||||||
|
{
|
||||||
|
return _Name;
|
||||||
|
}
|
||||||
|
|
||||||
/// Get the path in which workpsace is located with a trailing slash
|
/// Get the path in which workpsace is located with a trailing slash
|
||||||
std::string getPath() const;
|
std::string getPath() const;
|
||||||
std::string getFilename() const;
|
std::string getFilename() const;
|
||||||
|
|
||||||
/// Get Number of nodes in the workspace
|
/// Get Number of nodes in the workspace
|
||||||
uint getNumNode() const { return (uint)_Nodes.size(); }
|
uint getNumNode() const
|
||||||
|
{
|
||||||
|
return (uint)_Nodes.size();
|
||||||
|
}
|
||||||
|
|
||||||
/// Get a node in workspace
|
/// Get a node in workspace
|
||||||
/// Can keep pointer safely as long as the node is not deleted
|
/// Can keep pointer safely as long as the node is not deleted
|
||||||
CWorkspaceNode *getNode(uint index) const { return _Nodes[index]; }
|
CWorkspaceNode *getNode(uint index) const
|
||||||
|
{
|
||||||
|
return _Nodes[index];
|
||||||
|
}
|
||||||
|
|
||||||
/// Get a node from a pointer on a particle system
|
/// Get a node from a pointer on a particle system
|
||||||
CWorkspaceNode *getNodeFromPS(NL3D::CParticleSystem *ps) const;
|
CWorkspaceNode *getNodeFromPS(NL3D::CParticleSystem *ps) const;
|
||||||
|
@ -253,21 +303,39 @@ public:
|
||||||
void load() throw(NLMISC::EStream);
|
void load() throw(NLMISC::EStream);
|
||||||
|
|
||||||
/// Test whether the structure of the workspace has been modified (does not test if ps inside the workspace have been modified)
|
/// Test whether the structure of the workspace has been modified (does not test if ps inside the workspace have been modified)
|
||||||
bool isModified() const { return _Modified; }
|
bool isModified() const
|
||||||
|
{
|
||||||
|
return _Modified;
|
||||||
|
}
|
||||||
|
|
||||||
/// Test whether the content of the workspace has ben modified
|
/// Test whether the content of the workspace has ben modified
|
||||||
bool isContentModified() const;
|
bool isContentModified() const;
|
||||||
void touch() { setModifiedFlag(true); }
|
void touch()
|
||||||
void clearModifiedFlag() { setModifiedFlag(false); }
|
{
|
||||||
|
setModifiedFlag(true);
|
||||||
|
}
|
||||||
|
void clearModifiedFlag()
|
||||||
|
{
|
||||||
|
setModifiedFlag(false);
|
||||||
|
}
|
||||||
|
|
||||||
/// Set a callback to know when a node is modified
|
/// Set a callback to know when a node is modified
|
||||||
void setModificationCallback(IModificationCallback *cb) { _ModificationCallback = cb; }
|
void setModificationCallback(IModificationCallback *cb)
|
||||||
IModificationCallback *getModificationCallback() const { return _ModificationCallback; }
|
{
|
||||||
|
_ModificationCallback = cb;
|
||||||
|
}
|
||||||
|
IModificationCallback *getModificationCallback() const
|
||||||
|
{
|
||||||
|
return _ModificationCallback;
|
||||||
|
}
|
||||||
|
|
||||||
/// Restick all objects, useful after loading
|
/// Restick all objects, useful after loading
|
||||||
void restickAllObjects();
|
void restickAllObjects();
|
||||||
|
|
||||||
TNodeVect& getNodeList() { return _Nodes; }
|
TNodeVect& getNodeList()
|
||||||
|
{
|
||||||
|
return _Nodes;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
// use smart ptr to avoir prb wih resize
|
// use smart ptr to avoir prb wih resize
|
||||||
|
|
|
@ -25,7 +25,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CPropertyDialog::CPropertyDialog(CParticleTreeModel *treeModel, QWidget *parent)
|
CPropertyDialog::CPropertyDialog(CParticleTreeModel *treeModel, QWidget *parent)
|
||||||
: QDockWidget(parent)
|
: QDockWidget(parent)
|
||||||
|
|
|
@ -44,7 +44,8 @@
|
||||||
#include "particle_tree_model.h"
|
#include "particle_tree_model.h"
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CPropertyDialog: public QDockWidget
|
class CPropertyDialog: public QDockWidget
|
||||||
{
|
{
|
||||||
|
@ -55,8 +56,14 @@ public:
|
||||||
|
|
||||||
void setCurrentEditedElement(CParticleTreeItem *editedItem);
|
void setCurrentEditedElement(CParticleTreeItem *editedItem);
|
||||||
|
|
||||||
CLocatedPage *getLocatedPage() const { return _locatedPage; };
|
CLocatedPage *getLocatedPage() const
|
||||||
CPSMoverPage *getMoverPage() const { return _psMoverPage; };
|
{
|
||||||
|
return _locatedPage;
|
||||||
|
};
|
||||||
|
CPSMoverPage *getMoverPage() const
|
||||||
|
{
|
||||||
|
return _psMoverPage;
|
||||||
|
};
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void setupUi();
|
void setupUi();
|
||||||
|
|
|
@ -32,7 +32,8 @@
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
#include "sound_system.h"
|
#include "sound_system.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CSoundPage::CSoundPage(QWidget *parent)
|
CSoundPage::CSoundPage(QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -38,7 +38,8 @@ namespace NLSOUND
|
||||||
class UAudioMixer;
|
class UAudioMixer;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CSoundPage
|
@class CSoundPage
|
||||||
|
@ -70,23 +71,50 @@ private:
|
||||||
struct CGainWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CGainWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSSound *S;
|
NL3D::CPSSound *S;
|
||||||
float get(void) const { return S->getGain(); }
|
float get(void) const
|
||||||
void set(const float &v) { S->setGain(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return S->getGainScheme(); }
|
return S->getGain();
|
||||||
void setScheme(scheme_type *s) { S->setGainScheme(s); }
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
S->setGain(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return S->getGainScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
S->setGainScheme(s);
|
||||||
|
}
|
||||||
} _GainWrapper;
|
} _GainWrapper;
|
||||||
|
|
||||||
/// wrapper to set the pitch of sounds
|
/// wrapper to set the pitch of sounds
|
||||||
struct CPitchWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
struct CPitchWrapper : public IPSWrapperFloat, IPSSchemeWrapperFloat
|
||||||
{
|
{
|
||||||
NL3D::CPSSound *S;
|
NL3D::CPSSound *S;
|
||||||
float get(void) const { return S->getPitch(); }
|
float get(void) const
|
||||||
void set(const float &v) { S->setPitch(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return S->getPitchScheme(); }
|
return S->getPitch();
|
||||||
void setScheme(scheme_type *s) { S->setPitchScheme(s); }
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
S->setPitch(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return S->getPitchScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
S->setPitchScheme(s);
|
||||||
|
}
|
||||||
} _PitchWrapper;
|
} _PitchWrapper;
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
/// the sound being edited
|
/// the sound being edited
|
||||||
NL3D::CPSSound *_Sound;
|
NL3D::CPSSound *_Sound;
|
||||||
|
|
|
@ -38,7 +38,8 @@
|
||||||
using namespace NL3D;
|
using namespace NL3D;
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
static void chooseGlobalUserParam(uint userParam, NL3D::CParticleSystem *ps, QWidget *parent)
|
static void chooseGlobalUserParam(uint userParam, NL3D::CParticleSystem *ps, QWidget *parent)
|
||||||
{
|
{
|
||||||
|
|
|
@ -33,7 +33,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "edit_range_widget.h"
|
#include "edit_range_widget.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
/**
|
/**
|
||||||
@class CParticleSystemPage
|
@class CParticleSystemPage
|
||||||
@brief Page for QStackWidget, to edit workspace node in a particle system
|
@brief Page for QStackWidget, to edit workspace node in a particle system
|
||||||
|
@ -110,7 +111,10 @@ private:
|
||||||
|
|
||||||
bool enabledModifiedFlag;
|
bool enabledModifiedFlag;
|
||||||
|
|
||||||
void updateModifiedFlag() { if ((_Node) && (enabledModifiedFlag)) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if ((_Node) && (enabledModifiedFlag)) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
CWorkspaceNode *_Node;
|
CWorkspaceNode *_Node;
|
||||||
|
|
||||||
|
|
|
@ -31,7 +31,8 @@
|
||||||
#include "value_gradient_dialog.h"
|
#include "value_gradient_dialog.h"
|
||||||
#include "multi_tex_dialog.h"
|
#include "multi_tex_dialog.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CParticleTextureAnimWidget::CParticleTextureAnimWidget(QWidget *parent)
|
CParticleTextureAnimWidget::CParticleTextureAnimWidget(QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -38,7 +38,8 @@ namespace NL3D
|
||||||
class CPSMultiTexturedParticle;
|
class CPSMultiTexturedParticle;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CParticleTextureAnimWidget: public QWidget
|
class CParticleTextureAnimWidget: public QWidget
|
||||||
{
|
{
|
||||||
|
@ -63,21 +64,42 @@ private:
|
||||||
struct CTextureWrapper : public IPSWrapperTexture
|
struct CTextureWrapper : public IPSWrapperTexture
|
||||||
{
|
{
|
||||||
NL3D::CPSTexturedParticle *P;
|
NL3D::CPSTexturedParticle *P;
|
||||||
NL3D::ITexture *get(void) { return P->getTexture(); }
|
NL3D::ITexture *get(void)
|
||||||
void set(NL3D::ITexture *t) { P->setTexture(t); }
|
{
|
||||||
|
return P->getTexture();
|
||||||
|
}
|
||||||
|
void set(NL3D::ITexture *t)
|
||||||
|
{
|
||||||
|
P->setTexture(t);
|
||||||
|
}
|
||||||
} _TextureWrapper;
|
} _TextureWrapper;
|
||||||
|
|
||||||
/// Wrapper for texture anim sequence
|
/// Wrapper for texture anim sequence
|
||||||
struct CTextureIndexWrapper : public IPSWrapper<sint32>, IPSSchemeWrapper<sint32>
|
struct CTextureIndexWrapper : public IPSWrapper<sint32>, IPSSchemeWrapper<sint32>
|
||||||
{
|
{
|
||||||
NL3D::CPSTexturedParticle *P;
|
NL3D::CPSTexturedParticle *P;
|
||||||
sint32 get(void) const { return P->getTextureIndex(); }
|
sint32 get(void) const
|
||||||
void set(const sint32 &v) { P->setTextureIndex(v); }
|
{
|
||||||
scheme_type *getScheme(void) const { return P->getTextureIndexScheme(); }
|
return P->getTextureIndex();
|
||||||
void setScheme(scheme_type *s) { P->setTextureIndexScheme(s); }
|
}
|
||||||
|
void set(const sint32 &v)
|
||||||
|
{
|
||||||
|
P->setTextureIndex(v);
|
||||||
|
}
|
||||||
|
scheme_type *getScheme(void) const
|
||||||
|
{
|
||||||
|
return P->getTextureIndexScheme();
|
||||||
|
}
|
||||||
|
void setScheme(scheme_type *s)
|
||||||
|
{
|
||||||
|
P->setTextureIndexScheme(s);
|
||||||
|
}
|
||||||
} _TextureIndexWrapper;
|
} _TextureIndexWrapper;
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
NL3D::CPSTexturedParticle *_EditedParticle;
|
NL3D::CPSTexturedParticle *_EditedParticle;
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,8 @@
|
||||||
#include "nel/3d/ps_particle_basic.h"
|
#include "nel/3d/ps_particle_basic.h"
|
||||||
#include "nel/misc/path.h"
|
#include "nel/misc/path.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CParticleTextureWidget::CParticleTextureWidget(QWidget *parent)
|
CParticleTextureWidget::CParticleTextureWidget(QWidget *parent)
|
||||||
: QWidget(parent), _Wrapper(NULL)
|
: QWidget(parent), _Wrapper(NULL)
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CParticleTextureWidget: public QWidget
|
class CParticleTextureWidget: public QWidget
|
||||||
{
|
{
|
||||||
|
@ -47,9 +48,15 @@ public:
|
||||||
void updateUi();
|
void updateUi();
|
||||||
|
|
||||||
// set a wrapper to get the datas, called before setCurrentTextureNoAnim
|
// set a wrapper to get the datas, called before setCurrentTextureNoAnim
|
||||||
void setWrapper(IPSWrapperTexture *wrapper) { _Wrapper = wrapper ; }
|
void setWrapper(IPSWrapperTexture *wrapper)
|
||||||
|
{
|
||||||
|
_Wrapper = wrapper ;
|
||||||
|
}
|
||||||
|
|
||||||
void enableRemoveButton(bool enabled) { _ui.removePushButton->setVisible(enabled); }
|
void enableRemoveButton(bool enabled)
|
||||||
|
{
|
||||||
|
_ui.removePushButton->setVisible(enabled);
|
||||||
|
}
|
||||||
|
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
void textureChanged(const QString &texName);
|
void textureChanged(const QString &texName);
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CParticleTreeItem::CParticleTreeItem(const QList<QVariant> &data, const int typeItem, CParticleTreeItem *parent):
|
CParticleTreeItem::CParticleTreeItem(const QList<QVariant> &data, const int typeItem, CParticleTreeItem *parent):
|
||||||
_itemData(data), _itemIconType(typeItem), _parentItem(parent)
|
_itemData(data), _itemIconType(typeItem), _parentItem(parent)
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
// Projects includes
|
// Projects includes
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
struct ItemType
|
struct ItemType
|
||||||
{
|
{
|
||||||
|
|
|
@ -42,9 +42,11 @@
|
||||||
#include "dup_ps.h"
|
#include "dup_ps.h"
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
static const char * const LocatedBindable[] = {
|
static const char * const LocatedBindable[] =
|
||||||
|
{
|
||||||
QT_TR_NOOP("Point"),
|
QT_TR_NOOP("Point"),
|
||||||
QT_TR_NOOP("LookAt"),
|
QT_TR_NOOP("LookAt"),
|
||||||
QT_TR_NOOP("FanLight"),
|
QT_TR_NOOP("FanLight"),
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
#include "particle_tree_model.h"
|
#include "particle_tree_model.h"
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class ParticleWorkspaceDialog
|
@class ParticleWorkspaceDialog
|
||||||
|
@ -48,7 +49,10 @@ public:
|
||||||
~CParticleWorkspaceDialog();
|
~CParticleWorkspaceDialog();
|
||||||
|
|
||||||
void touchPSState(CParticleTreeItem *item);
|
void touchPSState(CParticleTreeItem *item);
|
||||||
CPropertyDialog *getPropertyDialog() const { return _PropertyDialog; }
|
CPropertyDialog *getPropertyDialog() const
|
||||||
|
{
|
||||||
|
return _PropertyDialog;
|
||||||
|
}
|
||||||
|
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
/// Emits change active particle system node.
|
/// Emits change active particle system node.
|
||||||
|
|
|
@ -30,7 +30,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CWorkspacePage::CWorkspacePage(CParticleTreeModel *treeModel, QWidget *parent)
|
CWorkspacePage::CWorkspacePage(CParticleTreeModel *treeModel, QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -31,7 +31,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "particle_tree_model.h"
|
#include "particle_tree_model.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CWorkspacePage
|
@class CWorkspacePage
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
#include "particle_force_page.h"
|
#include "particle_force_page.h"
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CZonePage::CZonePage(QWidget *parent)
|
CZonePage::CZonePage(QWidget *parent)
|
||||||
: QWidget(parent)
|
: QWidget(parent)
|
||||||
|
|
|
@ -31,7 +31,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
class CZonePage: public QWidget
|
class CZonePage: public QWidget
|
||||||
{
|
{
|
||||||
|
@ -53,7 +54,10 @@ private Q_SLOTS:
|
||||||
private:
|
private:
|
||||||
void updateTargets();
|
void updateTargets();
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
/// the target we're focusing on
|
/// the target we're focusing on
|
||||||
NL3D::CPSTargetLocatedBindable *_LBTarget;
|
NL3D::CPSTargetLocatedBindable *_LBTarget;
|
||||||
|
|
|
@ -23,7 +23,8 @@
|
||||||
#include "nel/3d/ps_edit.h"
|
#include "nel/3d/ps_edit.h"
|
||||||
#include "nel/3d/ps_emitter.h"
|
#include "nel/3d/ps_emitter.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
void CPSInitialPos::reset()
|
void CPSInitialPos::reset()
|
||||||
{
|
{
|
||||||
|
@ -87,19 +88,28 @@ struct CRemoveLocatedPred
|
||||||
// private : predicate to remove located from a CPSInitialPos::TInitialLocatedSizeVect vector
|
// private : predicate to remove located from a CPSInitialPos::TInitialLocatedSizeVect vector
|
||||||
struct CRemoveLocatedFromLocatedSizePred : public CRemoveLocatedPred
|
struct CRemoveLocatedFromLocatedSizePred : public CRemoveLocatedPred
|
||||||
{
|
{
|
||||||
bool operator()(const std::pair<NL3D::CPSLocated *, uint32> &value) { return Loc == value.first; }
|
bool operator()(const std::pair<NL3D::CPSLocated *, uint32> &value)
|
||||||
|
{
|
||||||
|
return Loc == value.first;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// private : predicate to remove located from a PSInitialPos::CInitPSInstanceInfo vector
|
// private : predicate to remove located from a PSInitialPos::CInitPSInstanceInfo vector
|
||||||
struct CRemoveLocatedFromInitPSInstanceInfoVectPred : public CRemoveLocatedPred
|
struct CRemoveLocatedFromInitPSInstanceInfoVectPred : public CRemoveLocatedPred
|
||||||
{
|
{
|
||||||
bool operator()(const CPSInitialPos::CInitPSInstanceInfo &value) { return value.Loc == Loc; }
|
bool operator()(const CPSInitialPos::CInitPSInstanceInfo &value)
|
||||||
|
{
|
||||||
|
return value.Loc == Loc;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// private : predicate to remove located from a PSInitialPos::CRotScaleInfo vector
|
// private : predicate to remove located from a PSInitialPos::CRotScaleInfo vector
|
||||||
struct CRemoveLocatedFromRotScaleInfoVectPred : public CRemoveLocatedPred
|
struct CRemoveLocatedFromRotScaleInfoVectPred : public CRemoveLocatedPred
|
||||||
{
|
{
|
||||||
bool operator()(const CPSInitialPos::CRotScaleInfo &value) { return value.Loc == Loc; }
|
bool operator()(const CPSInitialPos::CRotScaleInfo &value)
|
||||||
|
{
|
||||||
|
return value.Loc == Loc;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// private : predicate to remove located bindable pointers in a TRotScaleInfoVect vect
|
// private : predicate to remove located bindable pointers in a TRotScaleInfoVect vect
|
||||||
|
@ -107,7 +117,10 @@ struct CRemoveLocatedBindableFromRotScaleInfoVectPred
|
||||||
{
|
{
|
||||||
// the located bindable taht has been removed
|
// the located bindable taht has been removed
|
||||||
NL3D::CPSLocatedBindable *LB;
|
NL3D::CPSLocatedBindable *LB;
|
||||||
bool operator()(const CPSInitialPos::CRotScaleInfo &value) { return value.LB == LB; }
|
bool operator()(const CPSInitialPos::CRotScaleInfo &value)
|
||||||
|
{
|
||||||
|
return value.LB == LB;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
void CPSInitialPos::removeLocated(NL3D::CPSLocated *loc)
|
void CPSInitialPos::removeLocated(NL3D::CPSLocated *loc)
|
||||||
|
|
|
@ -30,7 +30,8 @@ namespace NL3D
|
||||||
struct IPSMover;
|
struct IPSMover;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
/**
|
/**
|
||||||
@class CPSInitialPos
|
@class CPSInitialPos
|
||||||
This class helps to copy the position of initial instances in a particle
|
This class helps to copy the position of initial instances in a particle
|
||||||
|
@ -77,9 +78,18 @@ public:
|
||||||
NLMISC::CMatrix Rot;
|
NLMISC::CMatrix Rot;
|
||||||
NLMISC::CVector Scale;
|
NLMISC::CVector Scale;
|
||||||
};
|
};
|
||||||
NL3D::CParticleSystem *getPS() { return _PS; }
|
NL3D::CParticleSystem *getPS()
|
||||||
const NL3D::CParticleSystem *getPS() const { return _PS; }
|
{
|
||||||
bool isStateMemorized() const { return _PS != NULL; }
|
return _PS;
|
||||||
|
}
|
||||||
|
const NL3D::CParticleSystem *getPS() const
|
||||||
|
{
|
||||||
|
return _PS;
|
||||||
|
}
|
||||||
|
bool isStateMemorized() const
|
||||||
|
{
|
||||||
|
return _PS != NULL;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
typedef std::vector<CInitPSInstanceInfo> TInitInfoVect;
|
typedef std::vector<CInitPSInstanceInfo> TInitInfoVect;
|
||||||
|
|
|
@ -27,7 +27,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
const float epsilon = 10E-3f;
|
const float epsilon = 10E-3f;
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "ps_wrapper.h"
|
#include "ps_wrapper.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CLocatedBindableItem
|
@class CLocatedBindableItem
|
||||||
|
@ -47,8 +48,14 @@ public:
|
||||||
CLocatedBindableItem ( const QString & text, QListWidget * parent = 0, int type = UserType ):
|
CLocatedBindableItem ( const QString & text, QListWidget * parent = 0, int type = UserType ):
|
||||||
QListWidgetItem(text, parent, type), _lb(NULL) {}
|
QListWidgetItem(text, parent, type), _lb(NULL) {}
|
||||||
|
|
||||||
void setUserData(NL3D::CPSLocatedBindable *loc) { _lb = loc;}
|
void setUserData(NL3D::CPSLocatedBindable *loc)
|
||||||
NL3D::CPSLocatedBindable *getUserData() const { return _lb;}
|
{
|
||||||
|
_lb = loc;
|
||||||
|
}
|
||||||
|
NL3D::CPSLocatedBindable *getUserData() const
|
||||||
|
{
|
||||||
|
return _lb;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
|
@ -77,11 +84,20 @@ public:
|
||||||
NL3D::IPSMover *getMoverInterface(void) ;
|
NL3D::IPSMover *getMoverInterface(void) ;
|
||||||
|
|
||||||
/// get the located being edited
|
/// get the located being edited
|
||||||
NL3D::CPSLocated *getLocated(void) { return _EditedLocated ; }
|
NL3D::CPSLocated *getLocated(void)
|
||||||
const NL3D::CPSLocated *getLocated(void) const { return _EditedLocated ; }
|
{
|
||||||
|
return _EditedLocated ;
|
||||||
|
}
|
||||||
|
const NL3D::CPSLocated *getLocated(void) const
|
||||||
|
{
|
||||||
|
return _EditedLocated ;
|
||||||
|
}
|
||||||
|
|
||||||
/// get the index of the current edited item
|
/// get the index of the current edited item
|
||||||
uint32 getLocatedIndex(void) const { return _EditedLocatedIndex ; }
|
uint32 getLocatedIndex(void) const
|
||||||
|
{
|
||||||
|
return _EditedLocatedIndex ;
|
||||||
|
}
|
||||||
|
|
||||||
/// ghet the current located bindable being edited, or null
|
/// ghet the current located bindable being edited, or null
|
||||||
NL3D::CPSLocatedBindable *getLocatedBindable(void) ;
|
NL3D::CPSLocatedBindable *getLocatedBindable(void) ;
|
||||||
|
@ -101,8 +117,14 @@ private:
|
||||||
{
|
{
|
||||||
uint32 Index ;
|
uint32 Index ;
|
||||||
NL3D::IPSMover *M ;
|
NL3D::IPSMover *M ;
|
||||||
float get(void) const { return M->getScale(Index).x ; }
|
float get(void) const
|
||||||
void set(const float &v) { M->setScale(Index, v) ; }
|
{
|
||||||
|
return M->getScale(Index).x ;
|
||||||
|
}
|
||||||
|
void set(const float &v)
|
||||||
|
{
|
||||||
|
M->setScale(Index, v) ;
|
||||||
|
}
|
||||||
} _UniformScaleWrapper ;
|
} _UniformScaleWrapper ;
|
||||||
|
|
||||||
/// wrapper to scale the X coordinate
|
/// wrapper to scale the X coordinate
|
||||||
|
@ -110,7 +132,10 @@ private:
|
||||||
{
|
{
|
||||||
uint32 Index ;
|
uint32 Index ;
|
||||||
NL3D::IPSMover *M ;
|
NL3D::IPSMover *M ;
|
||||||
float get(void) const { return M->getScale(Index).x ; }
|
float get(void) const
|
||||||
|
{
|
||||||
|
return M->getScale(Index).x ;
|
||||||
|
}
|
||||||
void set(const float &s)
|
void set(const float &s)
|
||||||
{
|
{
|
||||||
NLMISC::CVector v = M->getScale(Index) ;
|
NLMISC::CVector v = M->getScale(Index) ;
|
||||||
|
@ -123,7 +148,10 @@ private:
|
||||||
{
|
{
|
||||||
uint32 Index ;
|
uint32 Index ;
|
||||||
NL3D::IPSMover *M ;
|
NL3D::IPSMover *M ;
|
||||||
float get(void) const { return M->getScale(Index).y ; }
|
float get(void) const
|
||||||
|
{
|
||||||
|
return M->getScale(Index).y ;
|
||||||
|
}
|
||||||
void set(const float &s)
|
void set(const float &s)
|
||||||
{
|
{
|
||||||
NLMISC::CVector v = M->getScale(Index) ;
|
NLMISC::CVector v = M->getScale(Index) ;
|
||||||
|
@ -136,7 +164,10 @@ private:
|
||||||
{
|
{
|
||||||
uint32 Index ;
|
uint32 Index ;
|
||||||
NL3D::IPSMover *M ;
|
NL3D::IPSMover *M ;
|
||||||
float get(void) const { return M->getScale(Index).z ; }
|
float get(void) const
|
||||||
|
{
|
||||||
|
return M->getScale(Index).z ;
|
||||||
|
}
|
||||||
void set(const float &s)
|
void set(const float &s)
|
||||||
{
|
{
|
||||||
NLMISC::CVector v = M->getScale(Index) ;
|
NLMISC::CVector v = M->getScale(Index) ;
|
||||||
|
@ -146,7 +177,10 @@ private:
|
||||||
|
|
||||||
void hideAdditionalWidget();
|
void hideAdditionalWidget();
|
||||||
|
|
||||||
void updateModifiedFlag() { if (_Node) _Node->setModified(true); }
|
void updateModifiedFlag()
|
||||||
|
{
|
||||||
|
if (_Node) _Node->setModified(true);
|
||||||
|
}
|
||||||
|
|
||||||
/// update the mouse listener position when the user entered a value with the keyboard
|
/// update the mouse listener position when the user entered a value with the keyboard
|
||||||
void updateListener(void) ;
|
void updateListener(void) ;
|
||||||
|
|
|
@ -30,7 +30,8 @@
|
||||||
//
|
//
|
||||||
#include "particle_node.h"
|
#include "particle_node.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/// Wrapper to read/write a value of type T
|
/// Wrapper to read/write a value of type T
|
||||||
template <class T> class IPSWrapper
|
template <class T> class IPSWrapper
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
|
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CSettingsDialog::CSettingsDialog(QWidget *parent)
|
CSettingsDialog::CSettingsDialog(QWidget *parent)
|
||||||
: QDialog(parent)
|
: QDialog(parent)
|
||||||
|
|
|
@ -30,7 +30,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CSettingsDialog
|
@class CSettingsDialog
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
using namespace NL3D;
|
using namespace NL3D;
|
||||||
using namespace NLMISC;
|
using namespace NLMISC;
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
CSetupFog::CSetupFog(QWidget *parent)
|
CSetupFog::CSetupFog(QWidget *parent)
|
||||||
: QDockWidget(parent)
|
: QDockWidget(parent)
|
||||||
|
|
|
@ -31,7 +31,8 @@
|
||||||
|
|
||||||
// Project includes
|
// Project includes
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@class CSetupFog
|
@class CSetupFog
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
#include "modules.h"
|
#include "modules.h"
|
||||||
#include "skeleton_tree_model.h"
|
#include "skeleton_tree_model.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
const int ssd_scale_precision = 1000;
|
const int ssd_scale_precision = 1000;
|
||||||
|
|
||||||
|
@ -432,12 +433,24 @@ void CSkeletonScaleDialog::applyScaleSlider(int scale, int idSelect)
|
||||||
{
|
{
|
||||||
switch(idSelect)
|
switch(idSelect)
|
||||||
{
|
{
|
||||||
case SidBoneX: _Bones[i].BoneScale.x = _BkupBones[i].BoneScale.x * factor; break;
|
case SidBoneX:
|
||||||
case SidBoneY: _Bones[i].BoneScale.y = _BkupBones[i].BoneScale.y * factor; break;
|
_Bones[i].BoneScale.x = _BkupBones[i].BoneScale.x * factor;
|
||||||
case SidBoneZ: _Bones[i].BoneScale.z = _BkupBones[i].BoneScale.z * factor; break;
|
break;
|
||||||
case SidSkinX: _Bones[i].SkinScale.x = _BkupBones[i].SkinScale.x * factor; break;
|
case SidBoneY:
|
||||||
case SidSkinY: _Bones[i].SkinScale.y = _BkupBones[i].SkinScale.y * factor; break;
|
_Bones[i].BoneScale.y = _BkupBones[i].BoneScale.y * factor;
|
||||||
case SidSkinZ: _Bones[i].SkinScale.z = _BkupBones[i].SkinScale.z * factor; break;
|
break;
|
||||||
|
case SidBoneZ:
|
||||||
|
_Bones[i].BoneScale.z = _BkupBones[i].BoneScale.z * factor;
|
||||||
|
break;
|
||||||
|
case SidSkinX:
|
||||||
|
_Bones[i].SkinScale.x = _BkupBones[i].SkinScale.x * factor;
|
||||||
|
break;
|
||||||
|
case SidSkinY:
|
||||||
|
_Bones[i].SkinScale.y = _BkupBones[i].SkinScale.y * factor;
|
||||||
|
break;
|
||||||
|
case SidSkinZ:
|
||||||
|
_Bones[i].SkinScale.z = _BkupBones[i].SkinScale.z * factor;
|
||||||
|
break;
|
||||||
};
|
};
|
||||||
roundClampScale(_Bones[i].BoneScale);
|
roundClampScale(_Bones[i].BoneScale);
|
||||||
roundClampScale(_Bones[i].SkinScale);
|
roundClampScale(_Bones[i].SkinScale);
|
||||||
|
|
|
@ -34,7 +34,8 @@
|
||||||
// Project includes
|
// Project includes
|
||||||
#include "skeleton_tree_model.h"
|
#include "skeleton_tree_model.h"
|
||||||
|
|
||||||
namespace NLQT {
|
namespace NLQT
|
||||||
|
{
|
||||||
|
|
||||||
/// A mirror to the list of bone
|
/// A mirror to the list of bone
|
||||||
struct CBoneMirror
|
struct CBoneMirror
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue