#pragma once

#define kPI				3.141592653589793238462643383279500
#define k2PI			6.283185307179586476925286766559000
#define k180DivPI		57.295779513082320876798154814105000
#define kPIDiv180		0.017453292519943295769236907684886
#define kPIDiv2			1.5707963267948966192313216916395
#define k270PI			4.712388980384689857693965074918


class Tool
{
public:
	static McCmColor DxfColor2Mx(int num, bool comp);

	static int       MxColor2Dxf(McCmColor color);

	static McDb::LineWeight DxfLineWeight2Mx(int iWeight);

	static int MxLineWeight2Dxf(McDb::LineWeight weight);

	static bool IsSystemDefaultBlockName(const MxString& sName);

	static bool IsZero(const double& diff,const double& epsilon = 1.0E-10);
};

#define MXDXF_W2A(val) ((const char *)(val))
#define MXDXF_A2W(val) ((const char *)(val))