// Color.cpp: implementation of the CColor class.
//
//////////////////////////////////////////////////////////////////////

#include "stdafx.h"
#include "Capture.h"
#include "Color.h"
#include "stdafx.h"
#include "VideoWnd.h"
#include "fwxVideo.h" 
#include "fwx1394API.h"
#include "fwxDCam.h"
#include "ControlDlg.h"

#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

CColor::CColor()
{

}

CColor::~CColor()
{

}

// Calc the RGB Red component from the YUV data
/*BYTE CVideoProcess::fwxCalcYUVRed(int Y, int V)
{
	int R = Y + ((int)(1.4020 * V));

	// Fix any out of range values
	if (R < 0)
		R = 0;
	else if (R > 255)
		R = 255;

	return (BYTE)R;
}

// Calc the RGB Green component from the YUV data
BYTE CVideoProcess::fwxCalcYUVGreen(int Y, int U, int V)
{
	int G = Y - ((int)(0.3441 * U)) - ((int)(0.7139 * V));

	// Fix any out of range values
	if (G < 0)
		G = 0;
	else if (G > 255)
		G = 255;

	return (BYTE)G;
}

// Calc the RGB Blue component from the YUV data
BYTE CVideoProcess::fwxCalcYUVBlue(int Y, int U)
{
	int B = Y + ((int)(1.7718 * U));

	// Fix any out of range values
	if (B < 0)
		B = 0;
	else if (B > 255)
		B = 255;

	return (BYTE)B;
}*/









