mirror of
https://bitbucket.org/mfeemster/fractorium.git
synced 2025-06-30 21:36:33 -04:00
--User changes
-Add new variations: bubbleT3D, crob, hexaplay3D, hexcrop, hexes, hexnix3D, loonie2, loonie3, nBlur, octapol and synth. -Allow for pre/post versions of dc_bubble, dc_cylinder and dc_linear whereas before they were omitted. -When saving a file with multiple embers in it, detect if time values are all the same and if so, start them at zero and increment by 1 for each ember. -Allow for numerous quality increases to be coalesced into one. It will pick up at the end of the current render. -Show selection highlight on variations tree in response to mouse hover. This makes it easier to see for which variation or param the current mouse wheel action will apply. -Make default temporal samples be 100, whereas before it was 1000 which was overkill. -Require the shift key to be held with delete for deleting an ember to prevent it from triggering when the user enters delete in the edit box. -This wasn't otherwise fixable without writing a lot more code. --Bug fixes -EmberGenome was crashing when generating a sequence from a source file with more than 2 embers in it. -EmberGenome was improperly handling the first frame of a merge after the last frame of the loop. -These bugs were due to a previous commit. Revert parts of that commit. -Prevent a zoom value of less than 0 when reading from xml. -Slight optimization of the crescents, and mask variations, if the compiler wasn't doing it already. -Unique file naming was broken because it was looking for _# and the default names ended with -#. -Disallow renaming of an ember in the library tree to an empty string. -Severe bug that prevented some variations from being read correctly from params generated outside this program. -Severe OpenCL randomization bug. The first x coordinates of the first points in the first kernel call of the first ember of a render since the OpenCL renderer object was created were not random and were mostly -1. -Severe bug when populating xform selection distributions that could sometimes cause a crash due to roundoff error. Fix by using double. -Limit the max number of variations in a random ember to MAX_CL_VARS, which is 8. This ensures they'll look the same on CPU and GPU. -Prevent user from saving stylesheet to default.qss, it's a special reserved filename. --Code changes -Generalize using the running sum output point inside of a variation for all cases: pre, reg and post. -Allow for array variables in variations where the address of each element is stored in m_Params. -Qualify all math functions with std:: -No longer use our own Clamp() in OpenCL, instead use the standard clamp(). -Redesign how functions are used in the variations OpenCL code. -Add tests to EmberTester to verify some of the new functionality. -Place more const and override qualifiers on functions where appropriate. -Add a global rand with a lock to be used very sparingly. -Use a map instead of a vector for bad param names in Xml parsing. -Prefix affine interpolation mode defines with "AFFINE_" to make their purpose more clear. -Allow for variations that change state during iteration by sending a separate copy of the ember to each rendering thread. -Implement this same functionality with a local struct in OpenCL. It's members are the total of all variables that need to change state within an ember. -Add Contains() function to Utils.h. -EmberRender: print names of kernels being printed with --dump_kernel option. -Clean up EmberTester to handle some of the recent changes. -Fix various casts. -Replace % 2 with & 1, even though the compiler was likely doing this already. -Add new file Variations06.h to accommodate new variations. -General cleanup.
This commit is contained in:
@ -201,7 +201,7 @@ public:
|
||||
m_SubBatchSize = DEFAULT_SBS;
|
||||
m_FuseCount = 15;
|
||||
m_Supersample = 1;
|
||||
m_TemporalSamples = 1000;
|
||||
m_TemporalSamples = 100;
|
||||
m_Symmetry = 0;
|
||||
m_Quality = 100;
|
||||
m_PixelsPerUnit = 240;
|
||||
@ -226,7 +226,7 @@ public:
|
||||
m_Time = 0;
|
||||
m_Background.Reset();
|
||||
m_Interp = EMBER_INTERP_LINEAR;
|
||||
m_AffineInterp = INTERP_LOG;
|
||||
m_AffineInterp = AFFINE_INTERP_LOG;
|
||||
|
||||
//DE filter.
|
||||
m_MinRadDE = 0;
|
||||
@ -505,15 +505,15 @@ public:
|
||||
}
|
||||
else
|
||||
{
|
||||
m_CamMat[0][0] = cos(-m_CamYaw);
|
||||
m_CamMat[1][0] = -sin(-m_CamYaw);
|
||||
m_CamMat[0][0] = std::cos(-m_CamYaw);
|
||||
m_CamMat[1][0] = -std::sin(-m_CamYaw);
|
||||
m_CamMat[2][0] = 0;
|
||||
m_CamMat[0][1] = cos(m_CamPitch) * sin(-m_CamYaw);
|
||||
m_CamMat[1][1] = cos(m_CamPitch) * cos(-m_CamYaw);
|
||||
m_CamMat[2][1] = -sin(m_CamPitch);
|
||||
m_CamMat[0][2] = sin(m_CamPitch) * sin(-m_CamYaw);
|
||||
m_CamMat[1][2] = sin(m_CamPitch) * cos(-m_CamYaw);
|
||||
m_CamMat[2][2] = cos(m_CamPitch);
|
||||
m_CamMat[0][1] = std::cos(m_CamPitch) * std::sin(-m_CamYaw);
|
||||
m_CamMat[1][1] = std::cos(m_CamPitch) * std::cos(-m_CamYaw);
|
||||
m_CamMat[2][1] = -std::sin(m_CamPitch);
|
||||
m_CamMat[0][2] = std::sin(m_CamPitch) * std::sin(-m_CamYaw);
|
||||
m_CamMat[1][2] = std::sin(m_CamPitch) * std::cos(-m_CamYaw);
|
||||
m_CamMat[2][2] = std::cos(m_CamPitch);
|
||||
|
||||
if (projBits & PROJBITS_BLUR)
|
||||
{
|
||||
@ -667,10 +667,10 @@ public:
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Flatten all xforms by adding a flatten variation if none is present, and if any of the
|
||||
/// variations or parameters in the vector are present.
|
||||
/// Flatten all xforms by adding a flatten variation if none is present, and if none of the
|
||||
/// variations or parameters in the vector are not present.
|
||||
/// </summary>
|
||||
/// <param name="names">Vector of variation and parameter names</param>
|
||||
/// <param name="names">Vector of variation and parameter names that inhibit flattening</param>
|
||||
/// <returns>True if flatten was added to any of the xforms, false if it already was present or if none of the specified variations or parameters were present.</returns>
|
||||
bool Flatten(vector<string>& names)
|
||||
{
|
||||
@ -907,7 +907,7 @@ public:
|
||||
ClampRef<T>(thisXform->m_ColorSpeed, -1, 1);
|
||||
|
||||
//Interp affine and post.
|
||||
if (m_AffineInterp == INTERP_LOG)
|
||||
if (m_AffineInterp == AFFINE_INTERP_LOG)
|
||||
{
|
||||
vector<v2T> cxMag(size);
|
||||
vector<v2T> cxAng(size);
|
||||
@ -944,7 +944,7 @@ public:
|
||||
Interpolater<T>::InterpAndConvertBack(coefs, cxAng, cxMag, cxTrn, thisXform->m_Post);
|
||||
}
|
||||
}
|
||||
else if (m_AffineInterp == INTERP_LINEAR)
|
||||
else if (m_AffineInterp == AFFINE_INTERP_LINEAR)
|
||||
{
|
||||
//Interpolate pre and post affine using coefs.
|
||||
allID = true;
|
||||
@ -1057,7 +1057,7 @@ public:
|
||||
continue;
|
||||
|
||||
//Assume that if there are no variations, then it's a padding xform.
|
||||
if (m_Xforms[i].Empty() && m_AffineInterp != INTERP_LOG)
|
||||
if (m_Xforms[i].Empty() && m_AffineInterp != AFFINE_INTERP_LOG)
|
||||
continue;
|
||||
|
||||
m_Xforms[i].m_Affine.Rotate(angle);
|
||||
@ -1140,8 +1140,8 @@ public:
|
||||
m_Xforms[i].m_ColorSpeed = 0;
|
||||
m_Xforms[i].m_Animate = 0;
|
||||
m_Xforms[i].m_ColorX = m_Xforms[i].m_ColorY = (sym < 3) ? 0 : (T(k - 1) / T(sym - 2));//Added Y.
|
||||
m_Xforms[i].m_Affine.A(Round6(cos(k * a)));
|
||||
m_Xforms[i].m_Affine.D(Round6(sin(k * a)));
|
||||
m_Xforms[i].m_Affine.A(Round6(std::cos(k * a)));
|
||||
m_Xforms[i].m_Affine.D(Round6(std::sin(k * a)));
|
||||
m_Xforms[i].m_Affine.B(Round6(-m_Xforms[i].m_Affine.D()));
|
||||
m_Xforms[i].m_Affine.E(m_Xforms[i].m_Affine.A());
|
||||
m_Xforms[i].m_Affine.C(0);
|
||||
@ -1159,7 +1159,7 @@ public:
|
||||
/// Return a uint with bits set to indicate which kind of projection should be done.
|
||||
/// </summary>
|
||||
/// <param name="onlyScaleIfNewIsSmaller">A uint with bits set for each kind of projection that is needed</param>
|
||||
size_t ProjBits()
|
||||
size_t ProjBits() const
|
||||
{
|
||||
size_t val = 0;
|
||||
|
||||
@ -1410,9 +1410,9 @@ public:
|
||||
m_MinRadDE = 0;
|
||||
m_CurveDE = T(0.4);
|
||||
m_GammaThresh = T(0.01);
|
||||
m_TemporalSamples = 1000;
|
||||
m_TemporalSamples = 100;
|
||||
m_SpatialFilterType = GAUSSIAN_SPATIAL_FILTER;
|
||||
m_AffineInterp = INTERP_LOG;
|
||||
m_AffineInterp = AFFINE_INTERP_LOG;
|
||||
m_TemporalFilterType = BOX_TEMPORAL_FILTER;
|
||||
m_TemporalFilterWidth = 1;
|
||||
m_TemporalFilterExp = 0;
|
||||
@ -1443,7 +1443,7 @@ public:
|
||||
m_GammaThresh = -1;
|
||||
m_TemporalSamples = 0;
|
||||
m_SpatialFilterType = GAUSSIAN_SPATIAL_FILTER;
|
||||
m_AffineInterp = INTERP_LOG;
|
||||
m_AffineInterp = AFFINE_INTERP_LOG;
|
||||
m_TemporalFilterType = BOX_TEMPORAL_FILTER;
|
||||
m_TemporalFilterWidth = -1;
|
||||
m_TemporalFilterExp = -999;
|
||||
|
Reference in New Issue
Block a user