summaryrefslogtreecommitdiffstatshomepage
path: root/src/osd
diff options
context:
space:
mode:
Diffstat (limited to 'src/osd')
-rw-r--r--src/osd/modules/render/d3d/d3dhlsl.cpp218
-rw-r--r--src/osd/modules/render/d3d/d3dhlsl.h7
-rw-r--r--src/osd/windows/winmain.cpp10
-rw-r--r--src/osd/windows/winmain.h8
4 files changed, 171 insertions, 72 deletions
diff --git a/src/osd/modules/render/d3d/d3dhlsl.cpp b/src/osd/modules/render/d3d/d3dhlsl.cpp
index 0280dd31e68..8a60eaa5190 100644
--- a/src/osd/modules/render/d3d/d3dhlsl.cpp
+++ b/src/osd/modules/render/d3d/d3dhlsl.cpp
@@ -76,7 +76,7 @@ shaders::shaders() :
vecbuf_type(), vecbuf_index(0), vecbuf_count(0), avi_output_file(NULL), avi_frame(0), avi_copy_surface(NULL), avi_copy_texture(NULL), avi_final_target(NULL), avi_final_texture(NULL),
black_surface(NULL), black_texture(NULL), render_snap(false), snap_rendered(false), snap_copy_target(NULL), snap_copy_texture(NULL), snap_target(NULL), snap_texture(NULL),
snap_width(0), snap_height(0), lines_pending(false), backbuffer(NULL), curr_effect(NULL), default_effect(NULL), prescale_effect(NULL), post_effect(NULL), distortion_effect(NULL),
- focus_effect(NULL), phosphor_effect(NULL), deconverge_effect(NULL), color_effect(NULL), yiq_encode_effect(NULL), yiq_decode_effect(NULL), bloom_effect(NULL),
+ focus_effect(NULL), phosphor_effect(NULL), deconverge_effect(NULL), color_effect(NULL), ntsc_effect(NULL), bloom_effect(NULL),
downsample_effect(NULL), vector_effect(NULL), fsfx_vertices(NULL), curr_texture(NULL), curr_render_target(NULL), curr_poly(NULL)
{
master_enable = false;
@@ -632,7 +632,7 @@ void shaders::set_texture(texture_info *texture)
default_effect->set_texture("Diffuse", (texture == NULL) ? default_texture->get_finaltex() : texture->get_finaltex());
if (options->yiq_enable)
{
- yiq_encode_effect->set_texture("Diffuse", (texture == NULL) ? default_texture->get_finaltex() : texture->get_finaltex());
+ ntsc_effect->set_texture("Diffuse", (texture == NULL) ? default_texture->get_finaltex() : texture->get_finaltex());
}
else
{
@@ -706,7 +706,8 @@ void shaders::init(base *d3dintf, running_machine *machine, d3d::renderer *rende
options->scanline_height = winoptions.screen_scanline_height();
options->scanline_bright_scale = winoptions.screen_scanline_bright_scale();
options->scanline_bright_offset = winoptions.screen_scanline_bright_offset();
- options->scanline_offset = winoptions.screen_scanline_offset();
+ options->scanline_jitter = winoptions.screen_scanline_jitter();
+ options->hum_bar_alpha = winoptions.screen_hum_bar_alpha();
get_vector(winoptions.screen_defocus(), 2, options->defocus, TRUE);
get_vector(winoptions.screen_converge_x(), 3, options->converge_x, TRUE);
get_vector(winoptions.screen_converge_y(), 3, options->converge_y, TRUE);
@@ -722,6 +723,7 @@ void shaders::init(base *d3dintf, running_machine *machine, d3d::renderer *rende
get_vector(winoptions.screen_phosphor(), 3, options->phosphor, TRUE);
options->saturation = winoptions.screen_saturation();
options->yiq_enable = winoptions.screen_yiq_enable();
+ options->yiq_jitter = winoptions.screen_yiq_jitter();
options->yiq_cc = winoptions.screen_yiq_cc();
options->yiq_a = winoptions.screen_yiq_a();
options->yiq_b = winoptions.screen_yiq_b();
@@ -917,8 +919,7 @@ int shaders::create_resources(bool reset)
focus_effect = new effect(this, d3d->get_device(), "focus.fx", fx_dir);
deconverge_effect = new effect(this, d3d->get_device(), "deconverge.fx", fx_dir);
color_effect = new effect(this, d3d->get_device(), "color.fx", fx_dir);
- yiq_encode_effect = new effect(this, d3d->get_device(), "yiq_encode.fx", fx_dir);
- yiq_decode_effect = new effect(this, d3d->get_device(), "yiq_decode.fx", fx_dir);
+ ntsc_effect = new effect(this, d3d->get_device(), "ntsc.fx", fx_dir);
bloom_effect = new effect(this, d3d->get_device(), "bloom.fx", fx_dir);
downsample_effect = new effect(this, d3d->get_device(), "downsample.fx", fx_dir);
vector_effect = new effect(this, d3d->get_device(), "vector.fx", fx_dir);
@@ -931,8 +932,7 @@ int shaders::create_resources(bool reset)
!focus_effect->is_valid() ||
!deconverge_effect->is_valid() ||
!color_effect->is_valid() ||
- !yiq_encode_effect->is_valid() ||
- !yiq_decode_effect->is_valid() ||
+ !ntsc_effect->is_valid() ||
!bloom_effect->is_valid() ||
!downsample_effect->is_valid() ||
!vector_effect->is_valid())
@@ -940,7 +940,7 @@ int shaders::create_resources(bool reset)
return 1;
}
- effect *effects[14] = {
+ effect *effects[13] = {
default_effect,
post_effect,
distortion_effect,
@@ -949,15 +949,14 @@ int shaders::create_resources(bool reset)
focus_effect,
deconverge_effect,
color_effect,
- yiq_encode_effect,
- yiq_decode_effect,
+ ntsc_effect,
color_effect,
bloom_effect,
downsample_effect,
vector_effect
};
- for (int i = 0; i < 14; i++)
+ for (int i = 0; i < 13; i++)
{
effects[i]->add_uniform("SourceDims", uniform::UT_VEC2, uniform::CU_SOURCE_DIMS);
effects[i]->add_uniform("SourceRect", uniform::UT_VEC2, uniform::CU_SOURCE_RECT);
@@ -967,27 +966,16 @@ int shaders::create_resources(bool reset)
effects[i]->add_uniform("SwapXY", uniform::UT_BOOL, uniform::CU_SWAP_XY);
}
- yiq_encode_effect->add_uniform("CCValue", uniform::UT_FLOAT, uniform::CU_NTSC_CCFREQ);
- yiq_encode_effect->add_uniform("AValue", uniform::UT_FLOAT, uniform::CU_NTSC_A);
- yiq_encode_effect->add_uniform("BValue", uniform::UT_FLOAT, uniform::CU_NTSC_B);
- yiq_decode_effect->add_uniform("OValue", uniform::UT_FLOAT, uniform::CU_NTSC_O);
- yiq_encode_effect->add_uniform("PValue", uniform::UT_FLOAT, uniform::CU_NTSC_P);
- yiq_encode_effect->add_uniform("NotchHalfWidth", uniform::UT_FLOAT, uniform::CU_NTSC_NOTCH);
- yiq_encode_effect->add_uniform("YFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_YFREQ);
- yiq_encode_effect->add_uniform("IFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_IFREQ);
- yiq_encode_effect->add_uniform("QFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_QFREQ);
- yiq_encode_effect->add_uniform("ScanTime", uniform::UT_FLOAT, uniform::CU_NTSC_HTIME);
-
- yiq_decode_effect->add_uniform("CCValue", uniform::UT_FLOAT, uniform::CU_NTSC_CCFREQ);
- yiq_decode_effect->add_uniform("AValue", uniform::UT_FLOAT, uniform::CU_NTSC_A);
- yiq_decode_effect->add_uniform("BValue", uniform::UT_FLOAT, uniform::CU_NTSC_B);
- yiq_decode_effect->add_uniform("OValue", uniform::UT_FLOAT, uniform::CU_NTSC_O);
- yiq_decode_effect->add_uniform("PValue", uniform::UT_FLOAT, uniform::CU_NTSC_P);
- yiq_decode_effect->add_uniform("NotchHalfWidth", uniform::UT_FLOAT, uniform::CU_NTSC_NOTCH);
- yiq_decode_effect->add_uniform("YFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_YFREQ);
- yiq_decode_effect->add_uniform("IFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_IFREQ);
- yiq_decode_effect->add_uniform("QFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_QFREQ);
- yiq_decode_effect->add_uniform("ScanTime", uniform::UT_FLOAT, uniform::CU_NTSC_HTIME);
+ ntsc_effect->add_uniform("CCValue", uniform::UT_FLOAT, uniform::CU_NTSC_CCFREQ);
+ ntsc_effect->add_uniform("AValue", uniform::UT_FLOAT, uniform::CU_NTSC_A);
+ ntsc_effect->add_uniform("BValue", uniform::UT_FLOAT, uniform::CU_NTSC_B);
+ ntsc_effect->add_uniform("OValue", uniform::UT_FLOAT, uniform::CU_NTSC_O);
+ ntsc_effect->add_uniform("PValue", uniform::UT_FLOAT, uniform::CU_NTSC_P);
+ ntsc_effect->add_uniform("NotchHalfWidth", uniform::UT_FLOAT, uniform::CU_NTSC_NOTCH);
+ ntsc_effect->add_uniform("YFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_YFREQ);
+ ntsc_effect->add_uniform("IFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_IFREQ);
+ ntsc_effect->add_uniform("QFreqResponse", uniform::UT_FLOAT, uniform::CU_NTSC_QFREQ);
+ ntsc_effect->add_uniform("ScanTime", uniform::UT_FLOAT, uniform::CU_NTSC_HTIME);
color_effect->add_uniform("RedRatios", uniform::UT_VEC3, uniform::CU_COLOR_RED_RATIOS);
color_effect->add_uniform("GrnRatios", uniform::UT_VEC3, uniform::CU_COLOR_GRN_RATIOS);
@@ -1062,8 +1050,7 @@ void shaders::begin_draw()
focus_effect->set_technique("DefaultTechnique");
deconverge_effect->set_technique("DefaultTechnique");
color_effect->set_technique("DefaultTechnique");
- yiq_encode_effect->set_technique("DefaultTechnique");
- yiq_decode_effect->set_technique("DefaultTechnique");
+ ntsc_effect->set_technique("DefaultTechnique");
color_effect->set_technique("DefaultTechnique");
bloom_effect->set_technique("DefaultTechnique");
downsample_effect->set_technique("DefaultTechnique");
@@ -1244,27 +1231,16 @@ int shaders::ntsc_pass(render_target *rt, int source_index, poly_info *poly, int
{
return next_index;
}
-
- float frame_offset = curr_texture->get_cur_frame() == 0
- ? 0.0f
- : (float)curr_texture->get_cur_frame();
-
- // Convert our signal into YIQ
- curr_effect = yiq_encode_effect;
- curr_effect->update_uniforms();
- curr_effect->set_float("FrameOffset", frame_offset);
- // initial "Diffuse" texture is set in shaders::set_texture()
+ float signal_offset = curr_texture->get_cur_frame() == 0
+ ? 0.0f
+ : options->yiq_jitter;
- next_index = rt->next_index(next_index);
- blit(rt->native_target[next_index], true, D3DPT_TRIANGLELIST, 0, 2);
+ // initial "Diffuse" texture is set in shaders::set_texture()
- // Convert our signal from YIQ
- curr_effect = yiq_decode_effect;
+ curr_effect = ntsc_effect;
curr_effect->update_uniforms();
- curr_effect->set_texture("Composite", rt->native_texture[next_index]);
- curr_effect->set_texture("Diffuse", curr_texture->get_finaltex());
- curr_effect->set_float("FrameOffset", frame_offset);
+ curr_effect->set_float("SignalOffset", signal_offset);
next_index = rt->next_index(next_index);
blit(rt->native_target[next_index], true, D3DPT_TRIANGLELIST, 0, 2);
@@ -1457,7 +1433,9 @@ int shaders::post_pass(render_target *rt, int source_index, poly_info *poly, int
curr_effect->set_vector("BackColor", 3, back_color);
curr_effect->set_vector("ScreenScale", 2, screen_scale);
curr_effect->set_vector("ScreenOffset", 2, screen_offset);
- curr_effect->set_float("ScanlineOffset", curr_texture->get_cur_frame() == 0 ? 0.0f : options->scanline_offset);
+ curr_effect->set_float("ScanlineOffset", curr_texture->get_cur_frame() == 0 ? 0.0f : options->scanline_jitter);
+ curr_effect->set_float("TimeMilliseconds", (float)machine->time().as_double() * 1000.0f);
+ curr_effect->set_float("HumBarAlpha", options->hum_bar_alpha);
curr_effect->set_bool("PrepareBloom", prepare_bloom);
curr_effect->set_bool("PrepareVector", prepare_vector);
@@ -2159,15 +2137,10 @@ void shaders::delete_resources(bool reset)
delete color_effect;
color_effect = NULL;
}
- if (yiq_encode_effect != NULL)
- {
- delete yiq_encode_effect;
- yiq_encode_effect = NULL;
- }
- if (yiq_decode_effect != NULL)
+ if (ntsc_effect != NULL)
{
- delete yiq_decode_effect;
- yiq_decode_effect = NULL;
+ delete ntsc_effect;
+ ntsc_effect = NULL;
}
if (backbuffer != NULL)
@@ -2423,10 +2396,16 @@ static INT32 slider_scanline_bright_offset(running_machine &machine, void *arg,
return slider_set(&(((hlsl_options*)arg)->scanline_bright_offset), 0.05f, "%2.2f", str, newval);
}
-static INT32 slider_scanline_offset(running_machine &machine, void *arg, std::string *str, INT32 newval)
+static INT32 slider_scanline_jitter(running_machine &machine, void *arg, std::string *str, INT32 newval)
{
((hlsl_options*)arg)->params_dirty = true;
- return slider_set(&(((hlsl_options*)arg)->scanline_offset), 0.05f, "%2.2f", str, newval);
+ return slider_set(&(((hlsl_options*)arg)->scanline_jitter), 0.01f, "%1.2f", str, newval);
+}
+
+static INT32 slider_hum_bar_alpha(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->hum_bar_alpha), 0.01f, "%1.2f", str, newval);
}
static INT32 slider_defocus_x(running_machine &machine, void *arg, std::string *str, INT32 newval)
@@ -2781,6 +2760,105 @@ static INT32 slider_bloom_lvl10_scale(running_machine &machine, void *arg, std::
return slider_set(&(((hlsl_options*)arg)->bloom_level10_weight), 0.01f, "%1.2f", str, newval);
}
+
+static INT32 slider_ntsc_enable(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ hlsl_options *options = (hlsl_options*)arg;
+ if (newval != SLIDER_NOCHANGE)
+ {
+ options->yiq_enable = newval;
+ }
+ if (str != NULL)
+ {
+ strprintf(*str, "%s", options->yiq_enable == 0 ? "Off" : "On");
+ }
+ options->params_dirty = true;
+
+ return options->yiq_enable;
+}
+
+// static INT32 slider_ntsc_phase_count(running_machine &machine, void *arg, std::string *str, INT32 newval)
+// {
+// hlsl_options *options = (hlsl_options*)arg;
+// if (newval != SLIDER_NOCHANGE)
+// {
+// options->yiq_phase_count = newval;
+// }
+// if (str != NULL)
+// {
+// strprintf(*str, "%d", options->yiq_phase_count);
+// }
+// options->params_dirty = true;
+
+// return options->yiq_phase_count;
+// }
+
+static INT32 slider_ntsc_jitter(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_jitter), 0.01f, "%1.2f", str, newval);
+}
+
+static INT32 slider_ntsc_a_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_a), 0.01f, "%1.2f", str, newval);
+}
+
+static INT32 slider_ntsc_b_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_b), 0.01f, "%1.2f", str, newval);
+}
+
+static INT32 slider_ntsc_p_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_p), 0.01f, "%1.2f", str, newval);
+}
+
+static INT32 slider_ntsc_o_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_o), 0.01f, "%1.2f", str, newval);
+}
+
+static INT32 slider_ntsc_cc_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_cc), 0.0001f, "%1.4f", str, newval);
+}
+
+static INT32 slider_ntsc_n_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_n), 0.01f, "%1.4f", str, newval);
+}
+
+static INT32 slider_ntsc_y_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_y), 0.01f, "%1.4f", str, newval);
+}
+
+static INT32 slider_ntsc_i_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_i), 0.01f, "%1.4f", str, newval);
+}
+
+static INT32 slider_ntsc_q_value(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_q), 0.01f, "%1.4f", str, newval);
+}
+
+static INT32 slider_ntsc_scan_time(running_machine &machine, void *arg, std::string *str, INT32 newval)
+{
+ ((hlsl_options*)arg)->params_dirty = true;
+ return slider_set(&(((hlsl_options*)arg)->yiq_scan_time), 0.01f, "%1.2f", str, newval);
+}
+
hlsl_options shaders::last_options = { false };
shaders::slider_desc shaders::s_sliders[] =
@@ -2805,7 +2883,8 @@ shaders::slider_desc shaders::s_sliders[] =
{ "Scanline Indiv. Height", 1, 20, 80, 1, 5, slider_scanline_height },
{ "Scanline Brightness", 0, 20, 40, 1, 5, slider_scanline_bright_scale },
{ "Scanline Brightness Overdrive", 0, 0, 20, 1, 5, slider_scanline_bright_offset },
- { "Scanline Jitter", 0, 0, 40, 1, 5, slider_scanline_offset },
+ { "Scanline Jitter", 0, 0, 100, 1, 5, slider_scanline_jitter },
+ { "Hum Bar Darkness", 0, 0, 100, 1, 5, slider_hum_bar_alpha },
{ "Defocus X", 0, 0, 100, 1, 7, slider_defocus_x },
{ "Defocus Y", 0, 0, 100, 1, 7, slider_defocus_y },
{ "Red Position Offset X", -100, 0, 100, 1, 7, slider_red_converge_x },
@@ -2861,6 +2940,19 @@ shaders::slider_desc shaders::s_sliders[] =
{ "Bloom Level 8 Scale", 0, 0, 100, 1, 7, slider_bloom_lvl8_scale },
{ "Bloom Level 9 Scale", 0, 0, 100, 1, 7, slider_bloom_lvl9_scale },
{ "Bloom Level 10 Scale", 0, 0, 100, 1, 7, slider_bloom_lvl10_scale },
+ { "NTSC processing", 0, 0, 1, 1, 5, slider_ntsc_enable },
+ { "Signal Jitter", 0, 0, 100, 1, 5, slider_ntsc_jitter },
+ { "A Value", -100, 50, 100, 1, 5, slider_ntsc_a_value },
+ { "B Value", -100, 50, 100, 1, 5, slider_ntsc_b_value },
+ { "Incoming Pixel Clock Scaling", -300, 100, 300, 1, 5, slider_ntsc_p_value },
+ { "Outgoing Color Carrier Phase", -300, 0, 300, 1, 5, slider_ntsc_o_value },
+ { "Color Carrier Frequency", 0, 35795, 60000, 5, 5, slider_ntsc_cc_value },
+ { "Y Notch", 0, 100, 600, 5, 5, slider_ntsc_n_value },
+ { "Y Frequency", 0, 600, 600, 5, 5, slider_ntsc_y_value },
+ { "I Frequency", 0, 120, 600, 5, 5, slider_ntsc_i_value },
+ { "Q Frequency", 0, 60, 600, 5, 5, slider_ntsc_q_value },
+ { "Scanline Duration", 0, 5260, 10000, 1, 5, slider_ntsc_scan_time },
+ // { "Phase Count", 1, 2, 3, 1, 5, slider_ntsc_phase_count },
{ NULL, 0, 0, 0, 0, 0, NULL },
};
diff --git a/src/osd/modules/render/d3d/d3dhlsl.h b/src/osd/modules/render/d3d/d3dhlsl.h
index a6d71f27d37..d949c1417c8 100644
--- a/src/osd/modules/render/d3d/d3dhlsl.h
+++ b/src/osd/modules/render/d3d/d3dhlsl.h
@@ -210,7 +210,8 @@ struct hlsl_options
float scanline_height;
float scanline_bright_scale;
float scanline_bright_offset;
- float scanline_offset;
+ float scanline_jitter;
+ float hum_bar_alpha;
float defocus[2];
float converge_x[3];
float converge_y[3];
@@ -228,6 +229,7 @@ struct hlsl_options
// NTSC
bool yiq_enable;
+ float yiq_jitter;
float yiq_cc;
float yiq_a;
float yiq_b;
@@ -427,8 +429,7 @@ private:
effect * phosphor_effect; // pointer to the phosphor-effect object
effect * deconverge_effect; // pointer to the deconvergence-effect object
effect * color_effect; // pointer to the color-effect object
- effect * yiq_encode_effect; // pointer to the YIQ encoder effect object
- effect * yiq_decode_effect; // pointer to the YIQ decoder effect object
+ effect * ntsc_effect; // pointer to the NTSC effect object
effect * bloom_effect; // pointer to the bloom composite effect
effect * downsample_effect; // pointer to the bloom downsample effect
effect * vector_effect; // pointer to the vector-effect object
diff --git a/src/osd/windows/winmain.cpp b/src/osd/windows/winmain.cpp
index 72682c177c4..27907f49783 100644
--- a/src/osd/windows/winmain.cpp
+++ b/src/osd/windows/winmain.cpp
@@ -303,12 +303,13 @@ const options_entry windows_options::s_option_entries[] =
{ WINOPTION_REFLECTION";fs_ref(0.0-1.0)", "0.0", OPTION_FLOAT, "screen reflection amount" },
{ WINOPTION_VIGNETTING";fs_vig(0.0-1.0)", "0.0", OPTION_FLOAT, "image vignetting amount" },
/* Beam-related values below this line*/
- { WINOPTION_SCANLINE_AMOUNT";fs_scanam(0.0-4.0)", "1.0", OPTION_FLOAT, "overall alpha scaling value for scanlines" },
+ { WINOPTION_SCANLINE_AMOUNT";fs_scanam(0.0-4.0)", "0.0", OPTION_FLOAT, "overall alpha scaling value for scanlines" },
{ WINOPTION_SCANLINE_SCALE";fs_scansc(0.0-4.0)", "1.0", OPTION_FLOAT, "overall height scaling value for scanlines" },
{ WINOPTION_SCANLINE_HEIGHT";fs_scanh(0.0-4.0)", "1.0", OPTION_FLOAT, "individual height scaling value for scanlines" },
{ WINOPTION_SCANLINE_BRIGHT_SCALE";fs_scanbs(0.0-2.0)", "1.0", OPTION_FLOAT, "overall brightness scaling value for scanlines (multiplicative)" },
{ WINOPTION_SCANLINE_BRIGHT_OFFSET";fs_scanbo(0.0-1.0)", "0.0", OPTION_FLOAT, "overall brightness offset value for scanlines (additive)" },
- { WINOPTION_SCANLINE_OFFSET";fs_scanjt(0.0-4.0)", "0.0", OPTION_FLOAT, "overall interlace jitter scaling value for scanlines" },
+ { WINOPTION_SCANLINE_JITTER";fs_scanjt(0.0-4.0)", "0.0", OPTION_FLOAT, "overall interlace jitter scaling value for scanlines" },
+ { WINOPTION_HUM_BAR_ALPHA";fs_humba(0.0-1.0)", "0.0", OPTION_FLOAT, "overall alpha scaling value for hum bar" },
{ WINOPTION_DEFOCUS";fs_focus", "1.0,0.0", OPTION_STRING, "overall defocus value in screen-relative coords" },
{ WINOPTION_CONVERGE_X";fs_convx", "0.25,0.00,-0.25", OPTION_STRING, "convergence in screen-relative X direction" },
{ WINOPTION_CONVERGE_Y";fs_convy", "0.0,0.25,-0.25", OPTION_STRING, "convergence in screen-relative Y direction" },
@@ -327,10 +328,11 @@ const options_entry windows_options::s_option_entries[] =
/* NTSC simulation below this line */
{ NULL, NULL, OPTION_HEADER, "NTSC POST-PROCESSING OPTIONS" },
{ WINOPTION_YIQ_ENABLE";yiq", "0", OPTION_BOOLEAN, "enables YIQ-space HLSL post-processing" },
- { WINOPTION_YIQ_CCVALUE";yiqcc", "3.59754545", OPTION_FLOAT, "Color Carrier frequency for NTSC signal processing" },
+ { WINOPTION_YIQ_JITTER";yiqj", "0.0", OPTION_FLOAT, "Jitter for the NTSC signal processing" },
+ { WINOPTION_YIQ_CCVALUE";yiqcc", "3.57954545", OPTION_FLOAT, "Color Carrier frequency for NTSC signal processing" },
{ WINOPTION_YIQ_AVALUE";yiqa", "0.5", OPTION_FLOAT, "A value for NTSC signal processing" },
{ WINOPTION_YIQ_BVALUE";yiqb", "0.5", OPTION_FLOAT, "B value for NTSC signal processing" },
- { WINOPTION_YIQ_OVALUE";yiqo", "1.0", OPTION_FLOAT, "Outgoing Color Carrier phase offset for NTSC signal processing" },
+ { WINOPTION_YIQ_OVALUE";yiqo", "0.0", OPTION_FLOAT, "Outgoing Color Carrier phase offset for NTSC signal processing" },
{ WINOPTION_YIQ_PVALUE";yiqp", "1.0", OPTION_FLOAT, "Incoming Pixel Clock scaling value for NTSC signal processing" },
{ WINOPTION_YIQ_NVALUE";yiqn", "1.0", OPTION_FLOAT, "Y filter notch width for NTSC signal processing" },
{ WINOPTION_YIQ_YVALUE";yiqy", "6.0", OPTION_FLOAT, "Y filter cutoff frequency for NTSC signal processing" },
diff --git a/src/osd/windows/winmain.h b/src/osd/windows/winmain.h
index 53f9e137604..a9f7066bf90 100644
--- a/src/osd/windows/winmain.h
+++ b/src/osd/windows/winmain.h
@@ -55,7 +55,8 @@
#define WINOPTION_SCANLINE_HEIGHT "scanline_height"
#define WINOPTION_SCANLINE_BRIGHT_SCALE "scanline_bright_scale"
#define WINOPTION_SCANLINE_BRIGHT_OFFSET "scanline_bright_offset"
-#define WINOPTION_SCANLINE_OFFSET "scanline_jitter"
+#define WINOPTION_SCANLINE_JITTER "scanline_jitter"
+#define WINOPTION_HUM_BAR_ALPHA "hum_bar_alpha"
#define WINOPTION_DEFOCUS "defocus"
#define WINOPTION_CONVERGE_X "converge_x"
#define WINOPTION_CONVERGE_Y "converge_y"
@@ -71,6 +72,7 @@
#define WINOPTION_PHOSPHOR "phosphor_life"
#define WINOPTION_SATURATION "saturation"
#define WINOPTION_YIQ_ENABLE "yiq_enable"
+#define WINOPTION_YIQ_JITTER "yiq_jitter"
#define WINOPTION_YIQ_CCVALUE "yiq_cc"
#define WINOPTION_YIQ_AVALUE "yiq_a"
#define WINOPTION_YIQ_BVALUE "yiq_b"
@@ -154,7 +156,8 @@ public:
float screen_scanline_height() const { return float_value(WINOPTION_SCANLINE_HEIGHT); }
float screen_scanline_bright_scale() const { return float_value(WINOPTION_SCANLINE_BRIGHT_SCALE); }
float screen_scanline_bright_offset() const { return float_value(WINOPTION_SCANLINE_BRIGHT_OFFSET); }
- float screen_scanline_offset() const { return float_value(WINOPTION_SCANLINE_OFFSET); }
+ float screen_scanline_jitter() const { return float_value(WINOPTION_SCANLINE_JITTER); }
+ float screen_hum_bar_alpha() const { return float_value(WINOPTION_HUM_BAR_ALPHA); }
float screen_reflection() const { return float_value(WINOPTION_REFLECTION); }
float screen_curvature() const { return float_value(WINOPTION_CURVATURE); }
float screen_round_corner() const { return float_value(WINOPTION_ROUND_CORNER); }
@@ -169,6 +172,7 @@ public:
const char *screen_grn_ratio() const { return value(WINOPTION_GRN_RATIO); }
const char *screen_blu_ratio() const { return value(WINOPTION_BLU_RATIO); }
bool screen_yiq_enable() const { return bool_value(WINOPTION_YIQ_ENABLE); }
+ float screen_yiq_jitter() const { return float_value(WINOPTION_YIQ_JITTER); }
float screen_yiq_cc() const { return float_value(WINOPTION_YIQ_CCVALUE); }
float screen_yiq_a() const { return float_value(WINOPTION_YIQ_AVALUE); }
float screen_yiq_b() const { return float_value(WINOPTION_YIQ_BVALUE); }