*/
void SetX(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].x = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].x, value))
+ {
+ mValue[bufferIndex].x = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetY(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].y = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].y, value))
+ {
+ mValue[bufferIndex].y = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetXRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].x += delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].x += delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetYRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].y += delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].y += delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void BakeX(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].x = value;
- mValue[1 - bufferIndex].x = value;
- mBaseValue.x = value;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.x, value))
+ {
+ mValue[bufferIndex].x = value;
+ mValue[1 - bufferIndex].x = value;
+ mBaseValue.x = value;
- OnBake();
+ OnBake();
+ }
}
/**
*/
void BakeY(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].y = value;
- mValue[1 - bufferIndex].y = value;
- mBaseValue.y = value;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.y, value))
+ {
+ mValue[bufferIndex].y = value;
+ mValue[1 - bufferIndex].y = value;
+ mBaseValue.y = value;
- OnBake();
+ OnBake();
+ }
}
/**
*/
void SetX(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].x = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].x, value))
+ {
+ mValue[bufferIndex].x = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetY(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].y = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].y, value))
+ {
+ mValue[bufferIndex].y = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetZ(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].z = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].z, value))
+ {
+ mValue[bufferIndex].z = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetXRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].x += delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].x += delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetYRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].y += delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].y += delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetZRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].z += delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].z += delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void BakeX(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].x = value;
- mValue[1 - bufferIndex].x = value;
- mBaseValue.x = value;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.x, value))
+ {
+ mValue[bufferIndex].x = value;
+ mValue[1 - bufferIndex].x = value;
+ mBaseValue.x = value;
- OnBake();
+ OnBake();
+ }
}
/**
*/
void BakeY(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].y = value;
- mValue[1 - bufferIndex].y = value;
- mBaseValue.y = value;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.y, value))
+ {
+ mValue[bufferIndex].y = value;
+ mValue[1 - bufferIndex].y = value;
+ mBaseValue.y = value;
- OnBake();
+ OnBake();
+ }
}
/**
*/
void BakeZ(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].z = value;
- mValue[1 - bufferIndex].z = value;
- mBaseValue.z = value;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.z, value))
+ {
+ mValue[bufferIndex].z = value;
+ mValue[1 - bufferIndex].z = value;
+ mBaseValue.z = value;
- OnBake();
+ OnBake();
+ }
}
/**
*/
void SetX(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].x = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].x, value))
+ {
+ mValue[bufferIndex].x = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetY(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].y = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].y, value))
+ {
+ mValue[bufferIndex].y = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetZ(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].z = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].z, value))
+ {
+ mValue[bufferIndex].z = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetW(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].w = value;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::Equals(mValue[bufferIndex].w, value))
+ {
+ mValue[bufferIndex].w = value;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetXRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].x = mValue[bufferIndex].x + delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].x = mValue[bufferIndex].x + delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetYRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].y = mValue[bufferIndex].y + delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].y = mValue[bufferIndex].y + delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetZRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].z = mValue[bufferIndex].z + delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].z = mValue[bufferIndex].z + delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void SetWRelative(BufferIndex bufferIndex, float delta)
{
- mValue[bufferIndex].w = mValue[bufferIndex].w + delta;
+ // check if the value actually changed to avoid dirtying nodes unnecessarily
+ if(!Dali::EqualsZero(delta))
+ {
+ mValue[bufferIndex].w = mValue[bufferIndex].w + delta;
- OnSet();
+ OnSet();
+ }
}
/**
*/
void BakeX(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].x = value;
- mValue[1 - bufferIndex].x = value;
- mBaseValue.x = mValue[bufferIndex].x;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.x, value))
+ {
+ mValue[bufferIndex].x = value;
+ mValue[1 - bufferIndex].x = value;
+ mBaseValue.x = mValue[bufferIndex].x;
- OnBake();
+ OnBake();
+ }
}
/**
*/
void BakeY(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].y = value;
- mValue[1 - bufferIndex].y = value;
- mBaseValue.y = mValue[bufferIndex].y;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.y, value))
+ {
+ mValue[bufferIndex].y = value;
+ mValue[1 - bufferIndex].y = value;
+ mBaseValue.y = mValue[bufferIndex].y;
- OnBake();
+ OnBake();
+ }
}
/**
*/
void BakeZ(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].z = value;
- mValue[1 - bufferIndex].z = value;
- mBaseValue.z = mValue[bufferIndex].z;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.z, value))
+ {
+ mValue[bufferIndex].z = value;
+ mValue[1 - bufferIndex].z = value;
+ mBaseValue.z = mValue[bufferIndex].z;
- OnBake();
+ OnBake();
+ }
}
/**
*/
void BakeW(BufferIndex bufferIndex, float value)
{
- mValue[bufferIndex].w = value;
- mValue[1 - bufferIndex].w = value;
- mBaseValue.w = mValue[bufferIndex].w;
+ // bake has to check the base value as current buffer value can be correct by constraint or something else
+ if(!Dali::Equals(mBaseValue.w, value))
+ {
+ mValue[bufferIndex].w = value;
+ mValue[1 - bufferIndex].w = value;
+ mBaseValue.w = mValue[bufferIndex].w;
- OnBake();
+ OnBake();
+ }
}
/**