1 #include "..\include\raMain.h" 14 ra_g_pLogFile = fopen(File.c_str(),
"wt");
15 if(!ra_g_pLogFile)
return false;
27 fflush(ra_g_pLogFile);
28 fclose(ra_g_pLogFile);
42 fprintf(ra_g_pLogFile,
"%s<br>", pcFormat.c_str());
44 fflush(ra_g_pLogFile);
56 DWORD dwInLength = strlen(pcIn);
58 size_t dwInLength = strlen(pcIn.c_str());
62 ZeroMemory((
void*)pcOut.c_str(), dwOutLength);
63 for(DWORD dwIn = 0; dwIn < dwInLength; dwIn++)
65 if(pcIn[dwIn] !=
'<') {pcOut[dwOut] = pcIn[dwIn]; dwOut++;}
68 while(pcIn[dwIn] !=
'>') dwIn++;
81 fprintf(ra_g_pLogFile,
"<tr><td><font size=\"2\" color=\"#000080\">%s</font></td></tr><br>", pcFormat.c_str());
83 fflush(ra_g_pLogFile);
86 OutputDebugString(pcFormat.c_str());
96 sprintf(temp,
"<tr><td><font size=\"2\"><b><font color=\"#000080\">2D-Vektor:</font></b> x = <i>%.3f</i>, y = <i>%.3f</i>, Länge = <i>%.3f</i></td></tr>",
107 sprintf(temp,
"<tr><td><font size=\"2\"><b><font color=\"#000080\">3D-Vektor:</font></b> x = <i>%.3f</i>, y = <i>%.3f</i>, z = <i>%.3f</i>, Länge = <i>%.3f</i></td></tr>",
117 raWriteToLogDirect(
"<tr><td><font size=\"2\"><b><font color=\"#000080\">Matrix:</font></b><table>");
118 for(
int iRow = 0; iRow < 4; iRow++)
123 for(
int iColumn = 0; iColumn < 4; iColumn++)
126 sprintf(buf,
"<i>%.3f</i>", m.
m[iRow][iColumn]);
143 sprintf(temp,
"<tr><td><font size=\"2\"><b><font color=\"#000080\">Ebene:</font></b> a = <i>%.3f</i>, b = <i>%.3f</i>, c = <i>%.3f</i>, d = <i>%.3f</i>, Normalenvektorlänge = <i>%.3f</i></td></tr>",
154 sprintf(acHexColor,
"%x", (DWORD)(c) << 8);
159 sprintf(temp,
"<tr><td><font size=\"2\"><b><font color=\"#000080\">Farbe:</font></b> a = <i>%.3f</i>, r = <i>%.3f</i>, g = <i>%.3f</i>, b = <i>%.3f</i>, Hexadezimal: <i>0x%x</i>, <font color=\"#%s\"><i>Probetext</i></font></td></tr>",
160 c.
a, c.
r, c.
g, c.
b, (DWORD)(c), acHexColor);
RAPI bool raInitLog(raString File)
RAPI bool raWriteVector3ToLog(raVector3 &v)
bool RemoveHTMLTags(raString pcIn, raString pcOut, DWORD dwOutLength)
RAPI bool raWriteColorToLog(raColor &c)
raFloat raVector3Lenght(const raVector3 &v)
RAPI bool raWriteMatrixToLog(raMatrix &m)
raFloat raVector4Lenght(const raVector4 &v)
RAPI bool raWriteVector2ToLog(raVector2 &v)
RAPI bool raWriteToLog(raString pcFormat)
RAPI bool raWriteToLogDirect(raString pcFormat)
RAPI bool raWritePlaneToLog(raPlane &p)
raFloat raVector2Lenght(const raVector2 &v)