11 void set(
size_t x,
size_t y,
size_t z,
size_t c)
13 this->m_x = x; this->m_y = y; this->m_z = z; this->m_color = c;
20 void set(
size_t x,
size_t y,
size_t z,
size_t c)
22 this->m_x = x; this->m_y = y; this->m_z = z; this->m_color = c;
29 os <<
"< " << obj.
m_x <<
", " <<obj.
m_y <<
", " << obj.
m_z <<
" >";
35 os <<
"< " << obj.
m_x <<
", " <<obj.
m_y <<
", " << obj.
m_z <<
" >";
39template<
typename ElementType>
42 size_t test_count = 100;
46 << test_count <<
" times " <<
endl;
49 for(
size_t i = 0; i < test_count; ++i)
61 stream <<
"\nTesting tpf::dynamic_array<int> - " <<
array_size <<
" elements - "
62 << test_count <<
" times " <<
endl;
63 for(
size_t i = 0; i < test_count; ++i)
68 array[j].
set(j, j, j, j);
79 performance_test<vector_3d_pod>();
81 performance_test<vector_3d_class>();
std::ostream & operator<<(std::ostream &os, const vector_3d_pod &obj)
std::string elapsed_time(bool bReset=true, TimeUnit dummy_time=TimeUnit{}) const
Implements set operations.
constexpr size_t array_size(ElementType(&array)[ElementSize]) noexcept
void set(size_t x, size_t y, size_t z, size_t c)
void set(size_t x, size_t y, size_t z, size_t c)
Stream output operators << are implemented.