예제 #1
0
 void apply( Out::VecCoord& out, const In::VecCoord& in )
 {
     out.resize(in.size());
     dx.resize(in.size());
     for(unsigned int i=0; i<out.size(); i++)
     {
         double c = cos(in[i]);
         double s = sin(in[i]);
         out[i] = p0+rx*c+ry*s;
         dx[i] = rx*(-s)+ry*c;
     }
 }
예제 #2
0
void BarycentricMapperRegularGridTopology<CudaVec3f1Types,CudaVec3f1Types>::apply( Out::VecCoord& out, const In::VecCoord& in )
{
    unsigned int gridsize[3] = { (unsigned int)topology->getNx(), (unsigned int)topology->getNy(), (unsigned int)topology->getNz() };
    out.fastResize(map.size());
    RegularGridMapperCuda3f1_apply(map.size(), gridsize, map.deviceRead(), out.deviceWrite(), in.deviceRead());
}
예제 #3
0
void BarycentricMapperMeshTopology<CudaVec3f1Types,CudaVec3f1Types>::apply( Out::VecCoord& out, const In::VecCoord& in )
{
    out.fastResize(size);
    MeshMapperCuda3f1_apply(size, maxNIn, map.deviceRead(), out.deviceWrite(), in.deviceRead());
}
예제 #4
0
void BarycentricMapperSparseGridTopology<CudaVec3f1Types,CudaVec3f1Types>::apply( Out::VecCoord& out, const In::VecCoord& in )
{
    out.fastResize(map.size());
    buildHexa();
    SparseGridMapperCuda3f1_apply(map.size(), CudaHexa.deviceRead(), map.deviceRead(), out.deviceWrite(), in.deviceRead());
}
예제 #5
0
 void apply( Out::VecCoord& out, const In::VecCoord& in )
 {
     out.resize(in.size());
     for(unsigned int i=0; i<out.size(); i++)
         out[i] = p0+dx*in[i];
 }