MCPcopy Create free account
hub / github.com/WolfireGames/overgrowth / Init

Method Init

Source/Graphics/text.cpp:922–934  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

920}
921
922void TextAtlasRenderer::Init() {
923 CHECK_GL_ERROR();
924 num_characters = 0;
925
926 CHECK_GL_ERROR();
927 Shaders* shaders = Shaders::Instance();
928 shader_id = shaders->returnProgram("simple_2d #TEXTURE");
929 shaders->createProgram(shader_id);
930 shader_attrib_vert_coord = shaders->returnShaderAttrib("vert_coord", shader_id);
931 shader_attrib_tex_coord = shaders->returnShaderAttrib("tex_coord", shader_id);
932 uniform_mvp_mat = shaders->returnShaderVariable("mvp_mat", shader_id);
933 uniform_color = shaders->returnShaderVariable("color", shader_id);
934}
935
936void TextAtlasRenderer::Dispose() {
937 index_vbo.Dispose();

Callers 13

ASDrawTextAtlas2Method · 0.45
InitScreenMethod · 0.45
ReadMethod · 0.45
InitializeMethod · 0.45
test<1>Method · 0.45
test<2>Method · 0.45
test<3>Method · 0.45
test<4>Method · 0.45
test<5>Method · 0.45
mainFunction · 0.45

Calls 3

returnProgramMethod · 0.80
returnShaderAttribMethod · 0.80
returnShaderVariableMethod · 0.80

Tested by 5

test<1>Method · 0.36
test<2>Method · 0.36
test<3>Method · 0.36
test<4>Method · 0.36
test<5>Method · 0.36