else
//% VectorClear( normal );
VectorSet( normal, 0, 0, -1 );
+
+ if(colorsRGB)
+ {
+ color[0] = Image_LinearFloatFromsRGBFloat(color[0]);
+ color[1] = Image_LinearFloatFromsRGBFloat(color[1]);
+ color[2] = Image_LinearFloatFromsRGBFloat(color[2]);
+ }
/* create the flare surface (note shader defaults automatically) */
DrawSurfaceForFlare( mapEntityNum, origin, normal, color, flareShader, lightStyle );
{
char out[ 1024 ];
- char save_cmdline[1024], save_version[1024];
+ char save_cmdline[1024], save_version[1024], save_gridsize[1024];
const char *p;
/* note it */
p = ValueForKey(&entities[0], "_q3map2_version");
strncpy(save_version, p, sizeof(save_version));
save_version[sizeof(save_version)-1] = 0;
+ p = ValueForKey(&entities[0], "gridsize");
+ strncpy(save_gridsize, p, sizeof(save_gridsize));
+ save_gridsize[sizeof(save_gridsize)-1] = 0;
numEntities = 0;
SetKeyValue(&entities[0], "_q3map2_cmdline", save_cmdline);
if(*save_version)
SetKeyValue(&entities[0], "_q3map2_version", save_version);
+ if(*save_gridsize)
+ SetKeyValue(&entities[0], "gridsize", save_gridsize);
numBSPEntities = numEntities;
UnparseEntities();
maxSurfaceIndexes = game->maxSurfaceIndexes;
emitFlares = game->emitFlares;
texturesRGB = game->texturesRGB;
+ colorsRGB = game->colorsRGB;
/* process arguments */
for( i = 1; i < (argc - 1); i++ )
texturesRGB = qfalse;
Sys_Printf( "Textures are linear\n" );
}
+ else if( !strcmp( argv[ i ], "-sRGBcolor" ) )
+ {
+ colorsRGB = qtrue;
+ Sys_Printf( "Colors are in sRGB\n" );
+ }
+ else if( !strcmp( argv[ i ], "-nosRGBcolor" ) )
+ {
+ colorsRGB = qfalse;
+ Sys_Printf( "Colors are linear\n" );
+ }
+ else if( !strcmp( argv[ i ], "-nosRGB" ) )
+ {
+ texturesRGB = qfalse;
+ Sys_Printf( "Textures are linear\n" );
+ colorsRGB = qfalse;
+ Sys_Printf( "Colors are linear\n" );
+ }
else if( !strcmp( argv[ i ], "-altsplit" ) )
{
Sys_Printf( "Alternate BSP splitting (by 27) enabled\n" );