(XMB Cg) Ribbon works with Cg now too

This commit is contained in:
twinaphex 2016-04-17 17:59:40 +02:00
parent 05f2153549
commit ec4f961348
3 changed files with 3 additions and 5 deletions

View File

@ -6,7 +6,7 @@ static const char *stock_xmb =
"float iqhash(float n)\n"
"{\n"
"return fract(sin(n)*43758.5453);\n"
"return frac(sin(n)*43758.5453);\n"
"}\n"
"float noise(float3 x)\n"

View File

@ -146,10 +146,7 @@ static void gl_cg_set_uniform_parameter(
}
if (param->lookup.add_prefix)
{
strlcat(ident, "IN.", sizeof(ident));
strlcat(ident, param->lookup.ident, sizeof(ident));
}
snprintf(ident, sizeof(ident), "IN.%s", param->lookup.ident);
location = cgGetNamedParameter(prog, param->lookup.add_prefix ? ident : param->lookup.ident);
}
else

View File

@ -1939,6 +1939,7 @@ static void xmb_draw_ribbon(menu_display_ctx_draw_t *draw)
t += 0.01;
uniform_param.enabled = true;
uniform_param.lookup.enable = true;
uniform_param.lookup.add_prefix = true;
uniform_param.lookup.idx = VIDEO_SHADER_MENU;