Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions src/renderers/vulkan/tr_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ cvar_t *r_skipBackEnd;
cvar_t *r_greyscale;
cvar_t *r_dither;
cvar_t *r_presentBits;
cvar_t *r_outline;
cvar_t *r_outlineThreshold;

static cvar_t *r_ignorehwgamma;

Expand Down Expand Up @@ -2591,10 +2593,12 @@ static void R_Register( void )
ri.Cvar_Get( "r_svgMaxFileBytes", "2097152", CVAR_ARCHIVE );
ri.Cvar_SetDescription( ri.Cvar_Get( "r_svgMaxFileBytes", "2097152", CVAR_ARCHIVE ),
"Maximum accepted SVG source file size in bytes." );
ri.Cvar_Get( "r_outline", "0", CVAR_ARCHIVE );
ri.Cvar_SetDescription( ri.Cvar_Get( "r_outline", "0", CVAR_ARCHIVE ), "Edge-detection outline strength (0 = off, 0.5 = subtle, 1.0 = strong)." );
ri.Cvar_Get( "r_outlineThreshold", "0.15", CVAR_ARCHIVE );
ri.Cvar_SetDescription( ri.Cvar_Get( "r_outlineThreshold", "0.15", CVAR_ARCHIVE ), "Luminance edge threshold for outline detection." );
r_outline = ri.Cvar_Get( "r_outline", "0", CVAR_ARCHIVE );
ri.Cvar_SetDescription( r_outline, "Edge-detection outline strength (0 = off, 0.5 = subtle, 1.0 = strong)." );
ri.Cvar_SetGroup( r_outline, CVG_RENDERER );
r_outlineThreshold = ri.Cvar_Get( "r_outlineThreshold", "0.15", CVAR_ARCHIVE );
ri.Cvar_SetDescription( r_outlineThreshold, "Luminance edge threshold for outline detection." );
ri.Cvar_SetGroup( r_outlineThreshold, CVG_RENDERER );
ri.Cvar_Get( "r_safeMode", "0", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_SetDescription( ri.Cvar_Get( "r_safeMode", "0", CVAR_ARCHIVE | CVAR_LATCH ), "Safe mode: disables post-processing, bloom, SSAO, volumetric fog. Use if the engine crashes on startup." );

Expand Down
2 changes: 2 additions & 0 deletions src/renderers/vulkan/tr_local.h
Original file line number Diff line number Diff line change
Expand Up @@ -1788,6 +1788,8 @@ extern cvar_t *r_skipBackEnd;
extern cvar_t *r_greyscale;
extern cvar_t *r_dither;
extern cvar_t *r_presentBits;
extern cvar_t *r_outline;
extern cvar_t *r_outlineThreshold;

extern cvar_t *r_ignoreGLErrors;

Expand Down
8 changes: 2 additions & 6 deletions src/renderers/vulkan/vk_post_process_pipeline.c
Original file line number Diff line number Diff line change
Expand Up @@ -364,12 +364,8 @@ void vk_create_post_process_pipeline( int program_index, uint32_t width, uint32_
frag_spec_data.film_grain = PostFX_GetFilmGrain();
frag_spec_data.postprocess_enabled = ( r_post && r_post->integer ) ? 1 : 0;
frag_spec_data.film_look = PostFX_GetFilmLook();
{
cvar_t *r_outline = ri.Cvar_Get( "r_outline", "0", CVAR_ARCHIVE );
cvar_t *r_outlineThreshold = ri.Cvar_Get( "r_outlineThreshold", "0.15", CVAR_ARCHIVE );
frag_spec_data.outline_strength = r_outline ? r_outline->value : 0.0f;
frag_spec_data.outline_threshold = r_outlineThreshold ? r_outlineThreshold->value : 0.15f;
}
frag_spec_data.outline_strength = r_outline ? r_outline->value : 0.0f;
frag_spec_data.outline_threshold = r_outlineThreshold ? r_outlineThreshold->value : 0.15f;
{
cvar_t *r_post_contrast = ri.Cvar_Get( "r_post_contrast", "1.0", CVAR_ARCHIVE_ND );
cvar_t *r_post_saturation = ri.Cvar_Get( "r_post_saturation", "1.0", CVAR_ARCHIVE_ND );
Expand Down
4 changes: 0 additions & 4 deletions src/renderers/vulkan/vk_postfx_params.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ void vk_update_postfx_params( uint32_t cmd_index )
vec3_t shadowLift, midGamma, highlightGain, splitShadow, splitHighlight;
cvar_t *r_post_contrast;
cvar_t *r_post_saturation;
cvar_t *r_outline;
cvar_t *r_outlineThreshold;
cvar_t *r_autoExposure_target;
cvar_t *r_autoExposure_min;
cvar_t *r_autoExposure_max;
Expand Down Expand Up @@ -70,8 +68,6 @@ void vk_update_postfx_params( uint32_t cmd_index )
params.colorBalance[3] = ( r_pre_exposure_scale && r_pre_exposure_scale->value > 0.0f ) ? r_pre_exposure_scale->value : 1.0f;
r_post_contrast = ri.Cvar_Get( "r_post_contrast", "1.0", 0 );
r_post_saturation = ri.Cvar_Get( "r_post_saturation", "1.0", 0 );
r_outline = ri.Cvar_Get( "r_outline", "0", 0 );
r_outlineThreshold = ri.Cvar_Get( "r_outlineThreshold", "0.15", 0 );
params.colorGrade[0] = Com_Clamp( 0.0f, 3.0f, PostFX_GetGradeSaturation() );
params.colorGrade[1] = Com_Clamp( -1.0f, 1.0f, PostFX_GetGradeVibrance() );
params.colorGrade[2] = ( r_post_contrast && r_post_contrast->value > 0.0f ) ? r_post_contrast->value : 1.0f;
Expand Down
2 changes: 1 addition & 1 deletion src/server/sv_ccmds.c
Original file line number Diff line number Diff line change
Expand Up @@ -642,7 +642,7 @@ static void SV_BanNum_f( void ) {
}

#endif // USE_BANS
#endif // !COM_STANDALONE
#endif // !STANDALONE

#ifdef USE_BANS
/*
Expand Down
Loading