mirror of
https://bitbucket.org/mfeemster/fractorium.git
synced 2025-02-01 10:30:08 -05:00
--Bug fixes
-Long standing animation looping but that goes all the way back to flam3. -Build failure in hexes variation.
This commit is contained in:
parent
0b05f1a394
commit
c94c1eba66
@ -4735,7 +4735,7 @@ public:
|
||||
else
|
||||
helper.Out.y = m_Weight * (helper.In.y - m_Y);
|
||||
|
||||
helper.Out.z = m_Weight * helper.In.z;
|
||||
helper.Out.z = m_Weight * helper.In.z;//Original does *not* have this. search through all for this and sync.//TODO!
|
||||
}
|
||||
|
||||
virtual string OpenCLString() const override
|
||||
|
@ -239,7 +239,7 @@ public:
|
||||
|
||||
virtual vector<string> OpenCLGlobalFuncNames() const override
|
||||
{
|
||||
return vector<string> { "Zeps", "Sqr", "Vratio", "Closest", "Vratio" };
|
||||
return vector<string> { "Zeps", "Sqr", "Vratio", "Voronoi", "Closest" };
|
||||
}
|
||||
|
||||
virtual string OpenCLFuncsString() const override
|
||||
|
@ -348,7 +348,7 @@ public:
|
||||
INITUINTOPTION(Time, Eou(eOptionUse::OPT_ANIM_GENOME, eOptionIDs::OPT_TIME, _T("--time"), 0, SO_REQ_SEP, "\t--time=<val> Time of first and last frame (ie do one frame).\n"));
|
||||
INITUINTOPTION(Frame, Eou(eOptionUse::OPT_ANIM_GENOME, eOptionIDs::OPT_FRAME, _T("--frame"), 0, SO_REQ_SEP, "\t--frame=<val> Synonym for \"time\".\n"));
|
||||
INITUINTOPTION(Dtime, Eou(eOptionUse::OPT_USE_ANIMATE, eOptionIDs::OPT_DTIME, _T("--dtime"), 1, SO_REQ_SEP, "\t--dtime=<val> Time between frames [default: 1].\n"));
|
||||
INITUINTOPTION(Frames, Eou(eOptionUse::OPT_USE_GENOME, eOptionIDs::OPT_NFRAMES, _T("--nframes"), 20, SO_REQ_SEP, "\t--nframes=<val> Number of frames for each stage of the animation [default: 20].\n"));
|
||||
INITUINTOPTION(Frames, Eou(eOptionUse::OPT_USE_GENOME, eOptionIDs::OPT_NFRAMES, _T("--nframes"), 20, SO_REQ_SEP, "\t--nframes=<val> Number of frames per loop and per interpolation in the animation [default: 20].\n"));
|
||||
INITUINTOPTION(Repeat, Eou(eOptionUse::OPT_USE_GENOME, eOptionIDs::OPT_REPEAT, _T("--repeat"), 1, SO_REQ_SEP, "\t--repeat=<val> Number of new flames to create. Ignored if sequence, inter or rotate were specified [default: 1].\n"));
|
||||
INITUINTOPTION(Tries, Eou(eOptionUse::OPT_USE_GENOME, eOptionIDs::OPT_TRIES, _T("--tries"), 10, SO_REQ_SEP, "\t--tries=<val> Number times to try creating a flame that meets the specified constraints. Ignored if sequence, inter or rotate were specified [default: 10].\n"));
|
||||
INITUINTOPTION(MaxXforms, Eou(eOptionUse::OPT_USE_GENOME, eOptionIDs::OPT_MAX_XFORMS, _T("--maxxforms"), UINT_MAX, SO_REQ_SEP, "\t--maxxforms=<val> The maximum number of xforms allowed in the final output.\n"));
|
||||
|
@ -386,16 +386,26 @@ bool EmberGenome(EmberOptions& opt)
|
||||
{
|
||||
if (opt.Loops() > 0)
|
||||
{
|
||||
for (frame = 0; frame < round(T(opt.Frames()) * opt.Loops()); frame++)
|
||||
for (frame = 0; frame < std::round(opt.Frames() * opt.Loops()); frame++)
|
||||
{
|
||||
blend = T(frame) / T(opt.Frames());
|
||||
tools.Spin(embers[i], pTemplate, result, frameCount++, blend);//Result is cleared and reassigned each time inside of Spin().
|
||||
cout << emberToXml.ToString(result, opt.Extras(), opt.PrintEditDepth(), !opt.NoEdits(), false, opt.HexPalette());
|
||||
}
|
||||
|
||||
//The loop above will have rotated just shy of a complete rotation.
|
||||
//Rotate the next step and save in result, but do not print.
|
||||
//result will be the starting point for the interp phase below.
|
||||
frame = size_t(std::round(opt.Frames() * opt.Loops()));
|
||||
blend = T(frame) / T(opt.Frames());
|
||||
tools.Spin(embers[i], pTemplate, result, frameCount, blend);//Do not increment frameCount here.
|
||||
}
|
||||
|
||||
if (i < embers.size() - 1)
|
||||
{
|
||||
if (opt.Loops() > 0)//Store the last result as the flame to interpolate from. This applies for whole or fractional values of opt.Loops().
|
||||
embers[i] = result;
|
||||
|
||||
for (frame = 0; frame < opt.Frames(); frame++)
|
||||
{
|
||||
seqFlag = (frame == 0 || frame == opt.Frames() - 1);
|
||||
|
Loading…
Reference in New Issue
Block a user