- BufferIndex bufferIndex( Stage::GetCurrent()->GetEventBufferIndex() );
-
- switch ( custom->type )
- {
- case Property::BOOLEAN:
- {
- const AnimatableProperty<bool>* property = dynamic_cast< const AnimatableProperty<bool>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- case Property::FLOAT:
- {
- const AnimatableProperty<float>* property = dynamic_cast< const AnimatableProperty<float>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- case Property::INTEGER:
- {
- const AnimatableProperty<int>* property = dynamic_cast< const AnimatableProperty<int>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- case Property::VECTOR2:
- {
- const AnimatableProperty<Vector2>* property = dynamic_cast< const AnimatableProperty<Vector2>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- case Property::VECTOR3:
- {
- const AnimatableProperty<Vector3>* property = dynamic_cast< const AnimatableProperty<Vector3>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- case Property::VECTOR4:
- {
- const AnimatableProperty<Vector4>* property = dynamic_cast< const AnimatableProperty<Vector4>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- case Property::MATRIX:
- {
- const AnimatableProperty<Matrix>* property = dynamic_cast< const AnimatableProperty<Matrix>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- case Property::MATRIX3:
- {
- const AnimatableProperty<Matrix3>* property = dynamic_cast< const AnimatableProperty<Matrix3>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- case Property::ROTATION:
- {
- const AnimatableProperty<Quaternion>* property = dynamic_cast< const AnimatableProperty<Quaternion>* >( custom->GetSceneGraphProperty() );
- DALI_ASSERT_DEBUG( NULL != property );
-
- value = (*property)[ bufferIndex ];
- break;
- }
-
- default:
- {
- DALI_ASSERT_ALWAYS( false && "PropertyType enumeration is out of bounds" );
- break;
- }
- } // switch(type)
- } // if animatable
-
+ // get the animatable property value
+ value = GetPropertyValue( animatableProperty );
+ }
+ }
+ else if(mCustomProperties.Count() > 0)
+ {
+ CustomPropertyMetadata* custom = FindCustomProperty( index );
+ if(custom)
+ {
+ // get the custom property value
+ value = GetPropertyValue( custom );
+ }
+ else
+ {
+ DALI_LOG_ERROR("Invalid property index\n");
+ }