pColorPacket CAtmoTools::ApplyColorK(CAtmoConfig *pAtmoConfig, pColorPacket ColorPacket)
{

	for (int zoneIdx = 0; zoneIdx < ColorPacket->numColors; zoneIdx++)  
	{

		ColorPacket->zone[zoneIdx].r   =  trilinear(pAtmoConfig, ColorPacket->zone[zoneIdx].r,ColorPacket->zone[zoneIdx].g, ColorPacket->zone[zoneIdx].b,0);	
		ColorPacket->zone[zoneIdx].g   =  trilinear(pAtmoConfig, ColorPacket->zone[zoneIdx].r,ColorPacket->zone[zoneIdx].g, ColorPacket->zone[zoneIdx].b,1);
		ColorPacket->zone[zoneIdx].b   =  trilinear(pAtmoConfig, ColorPacket->zone[zoneIdx].r,ColorPacket->zone[zoneIdx].g, ColorPacket->zone[zoneIdx].b,2);
	}	
	return ColorPacket;
}
Esempio n. 2
0
/* ----------------------------------------------------------------------------
 * To invoke the interpolation
 * ---------------------------------------------------------------------------- */
void Interpolate::execute(double *qin, doublecomplex *DMq)
{
  UseGamma = 0;
  if (which == 1) // 1: tricubic
    tricubic(qin, DMq);
  else       // otherwise: trilinear
    trilinear(qin, DMq);
return;
}
Esempio n. 3
0
inline Tv trilinear(
	const Tf3& f, 
	const Tv& xyz, const Tv& Xyz,
	const Tv& xYz, const Tv& XYz,
	const Tv& xyZ, const Tv& XyZ,
	const Tv& xYZ, const Tv& XYZ
){
	return trilinear(f[0],f[1],f[2],xyz,Xyz,xYz,XYz,xyZ,XyZ,xYZ,XYZ);
}