Un-ignored: the dev drive is the ground truth the restoration and emulator work constantly reference (DPL3/LIBDPL + VRENDER i860 renderer source, BT/RP live+dev game trees, VGL_LABS pod boot, scene/audio content). Kept in-repo for the pod-owner community. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
27 lines
485 B
C++
27 lines
485 B
C++
#include <stdio.h>
|
|
#include <math.h>
|
|
|
|
|
|
int main ( int argc, char **argv )
|
|
{
|
|
float k, scale=1.0f, gamma=1.7f;
|
|
int i, o;
|
|
|
|
printf ( "int gamma_2point2[256] = \n {");
|
|
|
|
for (i=0; i<256; i++ ) {
|
|
|
|
k = scale * (1023.0 / pow(255.0,1.0/gamma));
|
|
o = (int) (k * (pow((float)i,1.0/gamma)));
|
|
|
|
printf (" %d", o );
|
|
if (i==255)
|
|
printf ( " };\n");
|
|
else if ((i&7)==7)
|
|
printf(",\n ");
|
|
else
|
|
printf (",");
|
|
}
|
|
return 1;
|
|
}
|