mirror of
https://bitbucket.org/mfeemster/fractorium.git
synced 2025-07-17 13:45:00 -04:00
--User changes
-Add variations changes to the list of functionality that can be applied to all xforms using the Select tab. -Allow for graphical affine adjustments to apply to multiple selected xforms. -Slight optimization of the pie variation. -Undo state is only saved when the render completes and the mouse buttons are released. This helps avoid intermediate steps for quickly completing renders while dragging. -Add some keyboard shortcuts for toolbar and menu items. -Make info tab tree always expanded. --Bug fixes -Make precalcs for all hypertile variations safer by using Zeps() for denominators. -Changing the current xform with more than one selected would set all xform's color index value that of the current one. -Use hard found palette path information for randoms as well. -OpenCL build and assignment errors for Z value in epispiral variation. -Unitialized local variables in hexaplay3D, crob, pRose3D. --Code changes -Change static member variables from m_ to s_. -Get rid of excessive endl and replace with "\n". -Remove old IMAGEGL2D define from before Nvidia supported OpenCL 1.2. -Remove old CriticalSection code and use std::recursive_mutex. -Make Affine2D Rotate() and RotateTrans() take radians instead of angles. -More C++11 work. -General cleanup.
This commit is contained in:
@ -895,25 +895,23 @@ bool RendererCL<T, bucketT>::BuildIterProgramForEmber(bool doAccum)
|
||||
if (b)
|
||||
{
|
||||
m_IterKernel = m_IterOpenCLKernelCreator.CreateIterKernelString(m_Ember, m_Params.first, m_GlobalShared.first, m_LockAccum, doAccum);
|
||||
//cout << "Building: " << endl << iterProgram << endl;
|
||||
//cout << "Building: " << "\n" << iterProgram << "\n";
|
||||
vector<std::thread> threads;
|
||||
std::function<void(RendererClDevice*)> func = [&](RendererClDevice * dev)
|
||||
{
|
||||
if (!dev->m_Wrapper.AddProgram(m_IterOpenCLKernelCreator.IterEntryPoint(), m_IterKernel, m_IterOpenCLKernelCreator.IterEntryPoint(), m_DoublePrecision))
|
||||
{
|
||||
m_ResizeCs.Enter();//Just use the resize CS for lack of a better one.
|
||||
rlg l(m_ResizeCs);//Just use the resize CS for lack of a better one.
|
||||
b = false;
|
||||
AddToReport(string(loc) + "()\n" + dev->m_Wrapper.DeviceName() + ":\nBuilding the following program failed: \n" + m_IterKernel + "\n");
|
||||
m_ResizeCs.Leave();
|
||||
}
|
||||
else if (!m_GlobalShared.second.empty())
|
||||
{
|
||||
if (!dev->m_Wrapper.AddAndWriteBuffer(m_GlobalSharedBufferName, m_GlobalShared.second.data(), m_GlobalShared.second.size() * sizeof(m_GlobalShared.second[0])))
|
||||
{
|
||||
m_ResizeCs.Enter();//Just use the resize CS for lack of a better one.
|
||||
rlg l(m_ResizeCs);//Just use the resize CS for lack of a better one.
|
||||
b = false;
|
||||
AddToReport(string(loc) + "()\n" + dev->m_Wrapper.DeviceName() + ":\nAdding global shared buffer failed.\n");
|
||||
m_ResizeCs.Leave();
|
||||
}
|
||||
}
|
||||
};
|
||||
@ -934,7 +932,7 @@ bool RendererCL<T, bucketT>::BuildIterProgramForEmber(bool doAccum)
|
||||
if (b)
|
||||
{
|
||||
//t.Toc(__FUNCTION__ " program build");
|
||||
//cout << string(loc) << "():\nBuilding the following program succeeded: \n" << iterProgram << endl;
|
||||
//cout << string(loc) << "():\nBuilding the following program succeeded: \n" << iterProgram << "\n";
|
||||
m_LastBuiltEmber = m_Ember;
|
||||
}
|
||||
}
|
||||
@ -988,7 +986,7 @@ bool RendererCL<T, bucketT>::RunIter(size_t iterCount, size_t temporalSample, si
|
||||
{
|
||||
bool b = true;
|
||||
auto& wrapper = m_Devices[dev]->m_Wrapper;
|
||||
intmax_t itersRemaining;
|
||||
intmax_t itersRemaining = 0;
|
||||
|
||||
while (atomLaunchesRan.fetch_add(1), (b && (atomLaunchesRan.load() <= launches) && ((itersRemaining = atomItersRemaining.load()) > 0) && !m_Abort))
|
||||
{
|
||||
@ -1002,7 +1000,7 @@ bool RendererCL<T, bucketT>::RunIter(size_t iterCount, size_t temporalSample, si
|
||||
//The number of iters per thread must be adjusted if they've requested less iters than is normally ran in a grid (256 * 256 * 64 * 2 = 32,768).
|
||||
uint iterCountPerKernel = std::min<uint>(uint(adjustedIterCountPerKernel), uint(ceil(double(itersRemaining) / IterGridKernelCount())));
|
||||
size_t iterCountThisLaunch = iterCountPerKernel * IterGridKernelWidth() * IterGridKernelHeight();
|
||||
//cout << "itersRemaining " << itersRemaining << ", iterCountPerKernel " << iterCountPerKernel << ", iterCountThisLaunch " << iterCountThisLaunch << endl;
|
||||
//cout << "itersRemaining " << itersRemaining << ", iterCountPerKernel " << iterCountPerKernel << ", iterCountThisLaunch " << iterCountThisLaunch << "\n";
|
||||
|
||||
if (b && !(b = wrapper.SetArg (kernelIndex, argIndex++, iterCountPerKernel))) { AddToReport(loc); }//Number of iters for each thread to run.
|
||||
|
||||
|
Reference in New Issue
Block a user