Fixes from PR review
This commit is contained in:
@@ -127,9 +127,9 @@ namespace AZ
|
||||
m_increments.fill(1); // By default increment by 1 between each number.
|
||||
}
|
||||
|
||||
//! Fills a provided container from begin to end with a Halton sequence
|
||||
//! Entries are expected to be, or implicitely convert to, AZStd::array<float, Dimensions>
|
||||
template<class Iterator>
|
||||
//! Fills a provided container from begin to end with a Halton sequence.
|
||||
//! Entries are expected to be, or implicitly converted to, AZStd::array<float, Dimensions>.
|
||||
template<typename Iterator>
|
||||
void FillHaltonSequence(Iterator begin, Iterator end)
|
||||
{
|
||||
AZStd::array<uint32_t, Dimensions> indices = m_offsets;
|
||||
@@ -149,7 +149,7 @@ namespace AZ
|
||||
AZStd::generate(begin, end, f);
|
||||
}
|
||||
|
||||
//! Returns a Halton sequence in an array of N length
|
||||
//! Returns a Halton sequence in an array of N length.
|
||||
template<uint32_t N>
|
||||
AZStd::array<AZStd::array<float, Dimensions>, N> GetHaltonSequence()
|
||||
{
|
||||
@@ -159,7 +159,7 @@ namespace AZ
|
||||
}
|
||||
|
||||
//! Sets the offsets per dimension to start generating a sequence from.
|
||||
//! By default, there is no offset (offset of 0 corresponds to starting at index 1)
|
||||
//! By default, there is no offset (offset of 0 corresponds to starting at index 1).
|
||||
void SetOffsets(AZStd::array<uint32_t, Dimensions> offsets)
|
||||
{
|
||||
m_offsets = offsets;
|
||||
|
||||
@@ -103,7 +103,7 @@ namespace UnitTest
|
||||
AZStd::array<Point, 5> ownedContainer;
|
||||
sequence.FillHaltonSequence(ownedContainer.begin(), ownedContainer.end());
|
||||
|
||||
for (uint32_t i = 0; i < regularSequence.size(); ++i)
|
||||
for (size_t i = 0; i < regularSequence.size(); ++i)
|
||||
{
|
||||
EXPECT_FLOAT_EQ(regularSequence[i][0], ownedContainer[i].x);
|
||||
EXPECT_FLOAT_EQ(regularSequence[i][1], ownedContainer[i].y);
|
||||
|
||||
Reference in New Issue
Block a user