Move math namespace to fix #746.

This commit is contained in:
prideout
2019-02-06 10:52:16 -08:00
committed by Philip Rideout
parent 6089be6de6
commit 5ee359cf40
155 changed files with 746 additions and 717 deletions

View File

@@ -52,7 +52,7 @@
#include "app/FilamentApp.h"
#include "app/MeshAssimp.h"
using namespace math;
using namespace filament::math;
using namespace filament;
using namespace filamat;
using namespace utils;
@@ -338,11 +338,11 @@ static void setup(Engine* engine, View* view, Scene* scene) {
template<typename T>
static LinearImage toLinear(size_t w, size_t h, size_t bpr, const uint8_t* src) {
LinearImage result(w, h, 3);
math::float3* d = reinterpret_cast<math::float3*>(result.getPixelRef(0, 0));
filament::math::float3* d = reinterpret_cast<filament::math::float3*>(result.getPixelRef(0, 0));
for (size_t y = 0; y < h; ++y) {
T const* p = reinterpret_cast<T const*>(src + y * bpr);
for (size_t x = 0; x < w; ++x, p += 3) {
math::float3 sRGB(p[0], p[1], p[2]);
filament::math::float3 sRGB(p[0], p[1], p[2]);
sRGB /= std::numeric_limits<T>::max();
*d++ = sRGB;
}