From 8a86bd567ff19f0cfd12ea43ee6ed319c5f8e40e Mon Sep 17 00:00:00 2001 From: David Mayerich Date: Tue, 21 Oct 2014 15:32:59 -0500 Subject: [PATCH] changed rts namespace to stim --- cuda/devices.h | 4 ++-- envi/bil.h | 2 +- envi/binary.h | 2 +- envi/bip.h | 4 ++-- envi/bsq.h | 4 ++-- envi/envi.h | 4 ++-- envi/envi_header.h | 2 +- gl/texture.h | 2 +- math/bessel.h | 4 ++-- math/complex.h | 2 +- math/complexfield.cuh | 2 +- math/constants.h | 6 +++--- math/field.cuh | 2 +- math/function.h | 2 +- math/legendre.h | 2 +- math/matrix.h | 3 +-- math/plane.h | 8 ++++---- math/quad.h | 2 +- math/quaternion.h | 2 +- math/realfield.cuh | 4 ++-- math/rect.h | 2 +- math/triangle.h | 2 +- math/vector.h | 8 ++++---- optics/beam.h | 4 ++-- optics/efield.cuh | 4 ++-- optics/esphere.cuh | 6 +++--- optics/halfspace.cuh | 4 ++-- optics/material.h | 2 +- optics/mirst-1d.cuh | 2 +- optics/planewave.h | 6 +++--- visualization/camera.h | 14 +++++++------- visualization/colormap.h | 6 +++--- 32 files changed, 61 insertions(+), 62 deletions(-) diff --git a/cuda/devices.h b/cuda/devices.h index 7aec183..4dce378 100644 --- a/cuda/devices.h +++ b/cuda/devices.h @@ -3,7 +3,7 @@ #include -namespace rts{ +namespace stim{ int maxThreadsPerBlock() { @@ -15,4 +15,4 @@ int maxThreadsPerBlock() } } //end namespace rts -#endif \ No newline at end of file +#endif diff --git a/envi/bil.h b/envi/bil.h index ff36234..47ad258 100644 --- a/envi/bil.h +++ b/envi/bil.h @@ -6,7 +6,7 @@ #include #include -namespace rts{ +namespace stim{ template diff --git a/envi/binary.h b/envi/binary.h index 2011bf3..dc35315 100644 --- a/envi/binary.h +++ b/envi/binary.h @@ -8,7 +8,7 @@ #include #include -namespace rts{ +namespace stim{ //This class contains a bunch of functions useful for multidimensional binary file access template< typename T, unsigned int D = 3 > diff --git a/envi/bip.h b/envi/bip.h index 98ec0c2..f929e20 100644 --- a/envi/bip.h +++ b/envi/bip.h @@ -7,7 +7,7 @@ #include #include -namespace rts{ +namespace stim{ template @@ -438,7 +438,7 @@ public: //first creat a temporary bil file and convert bip file to bil file bil(temp); - rts::bil n; + stim::bil n; if(n.open(temp, R[0], R[1], R[2], offset, w)==false){ //open infile std::cout<<"ERROR: unable to open input file"< #include -namespace rts{ +namespace stim{ template @@ -274,7 +274,7 @@ public: //first creat a temporary bil file and convert bsq file to bil file bil(temp); - rts::bil n; + stim::bil n; if(n.open(temp, R[0], R[1], R[2], offset, w)==false){ //open infile std::cout<<"ERROR: unable to open input file"< -namespace rts{ +namespace stim{ ///This class stores an OpenGL texture map and is used by rts_glShaderProgram. class glTexture diff --git a/math/bessel.h b/math/bessel.h index 9d12b8b..d291deb 100644 --- a/math/bessel.h +++ b/math/bessel.h @@ -8,7 +8,7 @@ #define el 0.5772156649015329 -namespace rts{ +namespace stim{ static complex cii(0.0,1.0); static complex cone(1.0,0.0); @@ -1512,4 +1512,4 @@ int cbessjyva_sph(int v,complex

z,P &vm,complex

*cjv, } //end namespace rts -#endif \ No newline at end of file +#endif diff --git a/math/complex.h b/math/complex.h index 2473ff8..052350e 100644 --- a/math/complex.h +++ b/math/complex.h @@ -11,7 +11,7 @@ and can therefore be used in CUDA code and on CUDA devices. #include #include -namespace rts +namespace stim { template diff --git a/math/complexfield.cuh b/math/complexfield.cuh index 3c1054f..e6e2433 100644 --- a/math/complexfield.cuh +++ b/math/complexfield.cuh @@ -8,7 +8,7 @@ #include "../math/complex.h" #include "../math/realfield.cuh" -namespace rts{ +namespace stim{ template __global__ void gpu_complexfield_mag(T* dest, complex* source, unsigned int r0, unsigned int r1){ diff --git a/math/constants.h b/math/constants.h index 3dae3a5..d333887 100644 --- a/math/constants.h +++ b/math/constants.h @@ -1,7 +1,7 @@ #ifndef RTS_CONSTANTS_H #define RTS_CONSTANTS_H -#define rtsPI 3.14159 -#define rtsTAU 2 * rtsPI +#define stimPI 3.14159 +#define stimTAU 2 * rtsPI -#endif \ No newline at end of file +#endif diff --git a/math/field.cuh b/math/field.cuh index 98a19e1..fce70bb 100644 --- a/math/field.cuh +++ b/math/field.cuh @@ -15,7 +15,7 @@ #include "../visualization/colormap.h" -namespace rts{ +namespace stim{ //multiply R = X * Y template diff --git a/math/function.h b/math/function.h index 59d90c6..033337d 100644 --- a/math/function.h +++ b/math/function.h @@ -3,7 +3,7 @@ #include -namespace rts{ +namespace stim{ //template class for a one-dimensional function template diff --git a/math/legendre.h b/math/legendre.h index 1d86a19..4859740 100644 --- a/math/legendre.h +++ b/math/legendre.h @@ -3,7 +3,7 @@ #include "rts/cuda/callable.h" -namespace rts{ +namespace stim{ template CUDA_CALLABLE void init_legendre(T x, T& P0, T& P1) diff --git a/math/matrix.h b/math/matrix.h index 183bdd9..421d011 100644 --- a/math/matrix.h +++ b/math/matrix.h @@ -7,8 +7,7 @@ #include "vector.h" #include "../cuda/callable.h" -namespace rts -{ +namespace stim{ template struct matrix diff --git a/math/plane.h b/math/plane.h index 38adbb7..e384ef0 100644 --- a/math/plane.h +++ b/math/plane.h @@ -6,14 +6,14 @@ #include "rts/cuda/callable.h" -namespace rts{ +namespace stim{ template class plane; } template -CUDA_CALLABLE rts::plane operator-(rts::plane v); +CUDA_CALLABLE stim::plane operator-(stim::plane v); -namespace rts{ +namespace stim{ template class plane{ @@ -176,4 +176,4 @@ public: -#endif \ No newline at end of file +#endif diff --git a/math/quad.h b/math/quad.h index bbd5f77..628b982 100644 --- a/math/quad.h +++ b/math/quad.h @@ -10,7 +10,7 @@ #include #include -namespace rts{ +namespace stim{ //template for a quadangle class in ND space template diff --git a/math/quaternion.h b/math/quaternion.h index 83141fc..4420658 100644 --- a/math/quaternion.h +++ b/math/quaternion.h @@ -4,7 +4,7 @@ #include "../math/matrix.h" #include "../cuda/callable.h" -namespace rts{ +namespace stim{ template class quaternion diff --git a/math/realfield.cuh b/math/realfield.cuh index 6a2f2af..8708101 100644 --- a/math/realfield.cuh +++ b/math/realfield.cuh @@ -33,7 +33,7 @@ __global__ void gpu_gaussian(T* dest, unsigned int r0, unsigned int r1, T mean, dest[i] = fx * fy * fz; }*/ -namespace rts{ +namespace stim{ //multiply R = X * Y template @@ -293,4 +293,4 @@ public: } //end namespace rts -#endif \ No newline at end of file +#endif diff --git a/math/rect.h b/math/rect.h index 28f5846..bcdd8f5 100644 --- a/math/rect.h +++ b/math/rect.h @@ -10,7 +10,7 @@ #include #include -namespace rts{ +namespace stim{ //template for a rectangle class in ND space template diff --git a/math/triangle.h b/math/triangle.h index 5b911be..1d99234 100644 --- a/math/triangle.h +++ b/math/triangle.h @@ -6,7 +6,7 @@ #include "../math/vector.h" #include -namespace rts{ +namespace stim{ template struct triangle diff --git a/math/vector.h b/math/vector.h index 81d1c70..86fbbfd 100644 --- a/math/vector.h +++ b/math/vector.h @@ -8,7 +8,7 @@ #include "../cuda/callable.h" -namespace rts +namespace stim { @@ -257,7 +257,7 @@ struct vec } //end namespace rts template -std::ostream& operator<<(std::ostream& os, rts::vec v) +std::ostream& operator<<(std::ostream& os, stim::vec v) { os< v) template -CUDA_CALLABLE rts::vec operator*(T lhs, rts::vec rhs) +CUDA_CALLABLE stim::vec operator*(T lhs, stim::vec rhs) { - rts::vec r; + stim::vec r; return rhs * lhs; } diff --git a/optics/beam.h b/optics/beam.h index 3e0f2a6..8587bb4 100644 --- a/optics/beam.h +++ b/optics/beam.h @@ -6,7 +6,7 @@ #include "../optics/planewave.h" #include -namespace rts{ +namespace stim{ template class beam : public planewave

@@ -200,4 +200,4 @@ public: } -#endif \ No newline at end of file +#endif diff --git a/optics/efield.cuh b/optics/efield.cuh index 3af51fd..5002478 100644 --- a/optics/efield.cuh +++ b/optics/efield.cuh @@ -10,7 +10,7 @@ #include "../math/rect.h" -namespace rts{ +namespace stim{ template __global__ void gpu_planewave2efield(complex* X, complex* Y, complex* Z, unsigned int r0, unsigned int r1, @@ -406,4 +406,4 @@ public: } //end namespace rts -#endif \ No newline at end of file +#endif diff --git a/optics/esphere.cuh b/optics/esphere.cuh index 26aa5d0..1b5a559 100644 --- a/optics/esphere.cuh +++ b/optics/esphere.cuh @@ -8,7 +8,7 @@ #include "../cuda/devices.h" #include "../optics/efield.cuh" -namespace rts{ +namespace stim{ /* This class implements a discrete representation of an electromagnetic field in 2D scattered by a sphere. This class implements Mie scattering. @@ -17,7 +17,7 @@ template class esphere : public efield

{ private: - rts::complex

n; //sphere refractive index + stim::complex

n; //sphere refractive index P a; //sphere radius //parameters dependent on wavelength @@ -159,4 +159,4 @@ public: } //end namespace rts -#endif \ No newline at end of file +#endif diff --git a/optics/halfspace.cuh b/optics/halfspace.cuh index 2858159..0905ce1 100644 --- a/optics/halfspace.cuh +++ b/optics/halfspace.cuh @@ -4,7 +4,7 @@ #include "../math/plane.h" -namespace rts{ +namespace stim{ //GPU kernel to compute the electric field template @@ -336,4 +336,4 @@ public: } -#endif \ No newline at end of file +#endif diff --git a/optics/material.h b/optics/material.h index 568b545..0352b03 100644 --- a/optics/material.h +++ b/optics/material.h @@ -12,7 +12,7 @@ #include "../math/constants.h" #include "../math/function.h" -namespace rts{ +namespace stim{ //Material class - default representation for the material property is the refractive index (RI) template diff --git a/optics/mirst-1d.cuh b/optics/mirst-1d.cuh index 00d1f22..22377b9 100644 --- a/optics/mirst-1d.cuh +++ b/optics/mirst-1d.cuh @@ -8,7 +8,7 @@ #include #include -namespace rts{ +namespace stim{ //this function writes a sinc function to "dest" such that an iFFT produces a slab template diff --git a/optics/planewave.h b/optics/planewave.h index 57d052c..6a295f9 100644 --- a/optics/planewave.h +++ b/optics/planewave.h @@ -8,13 +8,13 @@ #include "../math/quaternion.h" #include "../math/constants.h" #include "../math/plane.h" -#include "rts/cuda/callable.h" +#include "../cuda/callable.h" /*Basic conversions used here (assuming a vacuum) lambda = */ -namespace rts{ +namespace stim{ template class planewave{ @@ -315,4 +315,4 @@ std::ostream& operator<<(std::ostream& os, rts::planewave p) return os; } -#endif \ No newline at end of file +#endif diff --git a/visualization/camera.h b/visualization/camera.h index 9b800dd..5da92ae 100644 --- a/visualization/camera.h +++ b/visualization/camera.h @@ -1,14 +1,14 @@ -#include -#include -#include -#include +#include <../math/vector.h> +#include <../math/point.h> +#include <../math/quaternion.h> +#include <../math/matrix.h> #include -#ifndef RTS_CAMERA_H -#define RTS_CAMERA_H +#ifndef STIM_CAMERA_H +#define STIM_CAMERA_H -namespace rts{ +namespace stim{ class camera { diff --git a/visualization/colormap.h b/visualization/colormap.h index c7400da..7d23c27 100644 --- a/visualization/colormap.h +++ b/visualization/colormap.h @@ -1,5 +1,5 @@ -#ifndef RTS_COLORMAP_H -#define RTS_COLORMAP_H +#ifndef STIM_COLORMAP_H +#define STIM_COLORMAP_H #include #include @@ -30,7 +30,7 @@ texture cudaTexBrewer; static cudaArray* gpuBrewer; #endif -namespace rts{ +namespace stim{ enum colormapType {cmBrewer, cmGrayscale, cmRainbow}; -- libgit2 0.21.4