MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / grtext_SetFontScale

Function grtext_SetFontScale

grtext/grtext.cpp:318–333  ·  view source on GitHub ↗

sets font scale (1.0 = normal, 0.5 = 1/2, 2.0 = twice as large.

Source from the content-addressed store, hash-verified

316
317// sets font scale (1.0 = normal, 0.5 = 1/2, 2.0 = twice as large.
318void grtext_SetFontScale(float scale) {
319 struct {
320 char op;
321 float scale;
322 } cmd;
323
324 ASSERT((Grtext_ptr + sizeof(cmd)) < GRTEXT_BUFLEN);
325
326 cmd.op = GRTEXTOP_SCALE;
327 cmd.scale = scale;
328
329 memcpy(&Grtext_buffer[Grtext_ptr], &cmd, sizeof(cmd));
330 Grtext_ptr += sizeof(cmd);
331
332 Grtext_scale = scale;
333}
334
335// sets fancy color for text
336void grtext_SetFancyColor(ddgr_color col1, ddgr_color col2, ddgr_color col3, ddgr_color col4) {

Callers 4

RenderHUDItemsFunction · 0.85
RenderGaugesFunction · 0.85
RenderSmallWindowFunction · 0.85
Credits_RenderFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected