[glutils] Change macro names to comply with broader conventions
This commit is contained in:
parent
962fe8bc22
commit
dc72500b98
8
deps/glutils/src/glutils.cpp
vendored
8
deps/glutils/src/glutils.cpp
vendored
@ -89,7 +89,7 @@ static ox::Result<GLShader> buildShader(
|
|||||||
}
|
}
|
||||||
|
|
||||||
ox::Result<GLProgram> buildShaderProgram(ProgramSource const&src) noexcept {
|
ox::Result<GLProgram> buildShaderProgram(ProgramSource const&src) noexcept {
|
||||||
oxRequireM(program, buildShaderProgram(
|
OX_REQUIRE_M(program, buildShaderProgram(
|
||||||
src.vertShader,
|
src.vertShader,
|
||||||
src.fragShader,
|
src.fragShader,
|
||||||
src.geomShader));
|
src.geomShader));
|
||||||
@ -127,13 +127,13 @@ ox::Result<GLProgram> buildShaderProgram(
|
|||||||
ox::CStringView const&frag,
|
ox::CStringView const&frag,
|
||||||
ox::CStringView const&geo) noexcept {
|
ox::CStringView const&geo) noexcept {
|
||||||
GLProgram prgm(glCreateProgram());
|
GLProgram prgm(glCreateProgram());
|
||||||
oxRequire(vs, buildShader(GL_VERTEX_SHADER, vert.c_str(), "vshad"));
|
OX_REQUIRE(vs, buildShader(GL_VERTEX_SHADER, vert.c_str(), "vshad"));
|
||||||
glAttachShader(prgm, vs);
|
glAttachShader(prgm, vs);
|
||||||
if (geo.c_str() && geo.bytes() != 0) {
|
if (geo.c_str() && geo.bytes() != 0) {
|
||||||
oxRequire(gs, buildShader(GL_GEOMETRY_SHADER, geo.c_str(), "gshad"));
|
OX_REQUIRE(gs, buildShader(GL_GEOMETRY_SHADER, geo.c_str(), "gshad"));
|
||||||
glAttachShader(prgm, gs);
|
glAttachShader(prgm, gs);
|
||||||
}
|
}
|
||||||
oxRequire(fs, buildShader(GL_FRAGMENT_SHADER, frag.c_str(), "fshad"));
|
OX_REQUIRE(fs, buildShader(GL_FRAGMENT_SHADER, frag.c_str(), "fshad"));
|
||||||
glAttachShader(prgm, fs);
|
glAttachShader(prgm, fs);
|
||||||
glLinkProgram(prgm);
|
glLinkProgram(prgm);
|
||||||
return prgm;
|
return prgm;
|
||||||
|
Loading…
Reference in New Issue
Block a user