mirror of
https://bitbucket.org/mfeemster/fractorium.git
synced 2025-07-17 13:45:00 -04:00
--User changes
-Users can now specify animation params on a per flame basis. --These get saved with the flame file. -Allow for rotating xforms around the world origin during animation. -Make the Clear Flame menu item be more comprehensive in how it clears a flame out. --Bug fixes -Fix an extremely rare possible memory leak when using motion during animation, which is never used in Fractorium. -Do not skip to the current flame index, or attach a prefix in the Final Render Dialog when rendering an animation sequence. --Code changes -Place all animation params in Ember.
This commit is contained in:
@ -1389,6 +1389,7 @@ bool XmlToEmber<T>::ParseEmberElementFromChaos(xmlNode* emberNode, Ember<T>& cur
|
||||
{
|
||||
finalXform.m_Weight = 0;
|
||||
finalXform.m_Animate = 0;//Do not animate final by default.
|
||||
finalXform.m_AnimateOrigin = 0;
|
||||
finalXform.m_ColorX = finalXform.m_ColorY = 0;//Chaotica does not support any kind of coloring for final xforms, opacity remains 1 though.
|
||||
finalXform.m_ColorSpeed = 0;
|
||||
currentEmber.SetFinalXform(finalXform);
|
||||
@ -1615,6 +1616,14 @@ bool XmlToEmber<T>::ParseEmberElement(xmlNode* emberNode, Ember<T>& currentEmber
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "rand_range", currentEmber.m_RandPointRange, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "soloxform", soloXform, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "new_linear", newLinear, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "stagger", currentEmber.m_Stagger, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "rotations", currentEmber.m_Rotations, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "seconds_per_rotation", currentEmber.m_SecondsPerRotation, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "rotate_xforms_cw", currentEmber.m_RotateXformsCw, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "blend_seconds", currentEmber.m_BlendSeconds, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "rotations_per_blend", currentEmber.m_RotationsPerBlend, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "blend_rotate_xforms_cw", currentEmber.m_BlendRotateXformsCw, ret)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "linear_blend", currentEmber.m_Linear, ret)) {}
|
||||
//Parse more complicated reads that have multiple possible values.
|
||||
else if (!Compare(curAtt->name, "interpolation"))
|
||||
{
|
||||
@ -1818,6 +1827,9 @@ bool XmlToEmber<T>::ParseEmberElement(xmlNode* emberNode, Ember<T>& currentEmber
|
||||
|
||||
currentEmber.m_Curves.m_Points[3] = vals;
|
||||
}
|
||||
else if (!Compare(curAtt->name, "animations"))
|
||||
{
|
||||
}
|
||||
|
||||
xmlFree(attStr);
|
||||
}
|
||||
@ -2023,6 +2035,7 @@ bool XmlToEmber<T>::ParseEmberElement(xmlNode* emberNode, Ember<T>& currentEmber
|
||||
{
|
||||
Xform<T> finalXform;
|
||||
finalXform.m_Animate = 0;//Do not animate final by default.
|
||||
finalXform.m_AnimateOrigin = 0;
|
||||
|
||||
if (!ParseXform(childNode, finalXform, false, fromEmber))
|
||||
{
|
||||
@ -2148,6 +2161,8 @@ bool XmlToEmber<T>::ParseEmberElement(xmlNode* emberNode, Ember<T>& currentEmber
|
||||
ret = ret && AttToEmberMotionFloat(att, attStr, eEmberMotionParam::FLAME_MOTION_RAND_RANGE, motion);
|
||||
else if (!Compare(curAtt->name, "vibrancy"))
|
||||
ret = ret && AttToEmberMotionFloat(att, attStr, eEmberMotionParam::FLAME_MOTION_VIBRANCY, motion);
|
||||
else if (!Compare(curAtt->name, "scale"))
|
||||
ret = ret && AttToEmberMotionFloat(att, attStr, eEmberMotionParam::FLAME_MOTION_SCALE, motion);
|
||||
else if (!Compare(curAtt->name, "background"))
|
||||
{
|
||||
double r = 0, g = 0, b = 0;
|
||||
@ -2258,6 +2273,7 @@ bool XmlToEmber<T>::ParseXform(xmlNode* childNode, Xform<T>& xform, bool motion,
|
||||
if (ParseAndAssign(curAtt->name, attStr, "weight", xform.m_Weight, success)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "color_speed", xform.m_ColorSpeed, success)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "animate", xform.m_Animate, success)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "animate_origin", xform.m_AnimateOrigin, success)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "opacity", xform.m_Opacity, success)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "var_color", xform.m_DirectColor, success)) {}
|
||||
else if (ParseAndAssign(curAtt->name, attStr, "motion_frequency", xform.m_MotionFreq, success)) {}
|
||||
@ -2275,6 +2291,7 @@ bool XmlToEmber<T>::ParseXform(xmlNode* childNode, Xform<T>& xform, bool motion,
|
||||
Aton(attStr, temp);
|
||||
xform.m_ColorSpeed = (1 - temp) / 2;
|
||||
xform.m_Animate = T(temp > 0 ? 0 : 1);
|
||||
//Ignore m_AnimateOrigin because it's new and symmetry is a legacy setting.
|
||||
}
|
||||
else if (!Compare(curAtt->name, "motion_function"))
|
||||
{
|
||||
|
Reference in New Issue
Block a user