FACT++  1.0
void QCameraWidget::CalculatePatchColor ( )
private

Definition at line 422 of file QCameraWidget.cc.

References BasicGlCamera::fWhitePatch, i, BasicGlCamera::patchColour, BasicGlCamera::pixelsColor, and BasicGlCamera::softwareMapping.

Referenced by CalculatePixelsColor().

423  {
424  return;
425  //calculate the patch contour color. let's use the anti-colour of the pixels
426  GLfloat averagePatchColour[3] = {0.0f,0.0f,0.0f};
427  for (int i=0;i<9;i++)
428  for (int j=0;j<3;j++)
429  averagePatchColour[j] += pixelsColor[softwareMapping[fWhitePatch*9+i]][j];
430  for (int j=0;j<3;j++)
431  averagePatchColour[j] /= 9;
432  for (int j=0;j<3;j++)
433  patchColour[j] = 1.0f - averagePatchColour[j];
434  }
int i
Definition: db_dim_client.c:21
GLfloat patchColour[3]
Definition: BasicGlCamera.h:65
GLfloat pixelsColor[NPIX][3]
static int softwareMapping[NPIX]

+ Here is the caller graph for this function: