diff options
author | Hamed Zaghaghi <hamed.zaghaghi@gmail.com> | 2008-07-12 14:21:37 +0400 |
---|---|---|
committer | Hamed Zaghaghi <hamed.zaghaghi@gmail.com> | 2008-07-12 14:21:37 +0400 |
commit | a49c9c458aac2a738c3cf90860fb6e942747617e (patch) | |
tree | 98882a609b085452b24c35bbe1a7cc6103d7ee91 /source/gameengine/GameLogic/SCA_2DFilterActuator.cpp | |
parent | 5f15b164c549b336e1c5ef0dff2aaede056fd6f5 (diff) |
improvement of 2d-filter custom shader,
some bugfixes,
now you can use depth buffer and luminance buffer without any settings,
also you can use object's properties in a shader
Diffstat (limited to 'source/gameengine/GameLogic/SCA_2DFilterActuator.cpp')
-rw-r--r-- | source/gameengine/GameLogic/SCA_2DFilterActuator.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/source/gameengine/GameLogic/SCA_2DFilterActuator.cpp b/source/gameengine/GameLogic/SCA_2DFilterActuator.cpp index 56249bb52ec..96a770a553f 100644 --- a/source/gameengine/GameLogic/SCA_2DFilterActuator.cpp +++ b/source/gameengine/GameLogic/SCA_2DFilterActuator.cpp @@ -7,7 +7,6 @@ #endif #include <iostream> - SCA_2DFilterActuator::~SCA_2DFilterActuator() { } @@ -18,7 +17,6 @@ SCA_2DFilterActuator::SCA_2DFilterActuator( short flag, float float_arg, int int_arg, - short texture_flag, RAS_IRasterizer* rasterizer, RAS_IRenderTools* rendertools, PyTypeObject* T) @@ -26,11 +24,15 @@ SCA_2DFilterActuator::SCA_2DFilterActuator( m_type(type), m_flag(flag), m_int_arg(int_arg), - m_texture_flag(texture_flag), m_float_arg(float_arg), m_rasterizer(rasterizer), m_rendertools(rendertools) { + m_gameObj = NULL; + if(gameobj){ + m_propNames = gameobj->GetPropertyNames(); + m_gameObj = gameobj; + } } void SCA_2DFilterActuator::SetShaderText(STR_String text) @@ -52,8 +54,6 @@ CValue* SCA_2DFilterActuator::GetReplica() bool SCA_2DFilterActuator::Update() { - bool result = false; - bool bNegativeEvent = IsNegativeEvent(); RemoveAllEvents(); @@ -74,7 +74,7 @@ bool SCA_2DFilterActuator::Update() } else if(m_type < RAS_2DFilterManager::RAS_2DFILTER_NUMBER_OF_FILTERS) { - m_rendertools->Update2DFilter(m_type, m_int_arg, m_shaderText, m_texture_flag); + m_rendertools->Update2DFilter(m_propNames, m_gameObj, m_type, m_int_arg, m_shaderText); } return true; } |