UFO: Alien Invasion
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
r_misc.h File Reference

Go to the source code of this file.

Functions

void R_Transform (const vec3_t transform, const vec3_t rotate, const vec3_t scale)
 Perform translate, rotate and scale operations on the current matrix. More...
 
void R_PopMatrix (void)
 Removes the current matrix from the stack. More...
 
void R_PushMatrix (void)
 Push a new matrix to the stack. More...
 
void R_InitMiscTexture (void)
 
void R_ScreenShot_f (void)
 
void R_ScreenShot (int x, int y, int width, int height, const char *filename, const char *ext)
 
void R_DumpOpenGlState (void)
 Dumps OpenGL state for debugging - typically every capability set with glEnable(). More...
 
void R_ReinitOpenglContext (void)
 Re-initializes OpenGL state machine, all textures and renderer variables, this needed when application is put to background on Android. More...
 

Function Documentation

void R_DumpOpenGlState ( void  )

Dumps OpenGL state for debugging - typically every capability set with glEnable().

Definition at line 256 of file r_misc.cpp.

References CAPABILITY, Com_Printf(), f, i, lengthof, and Q_strcat().

void R_PopMatrix ( void  )

Removes the current matrix from the stack.

Definition at line 248 of file r_misc.cpp.

Referenced by uiSequenceNode::draw(), SEQ_Render3D(), and UI_Transform().

void R_PushMatrix ( void  )

Push a new matrix to the stack.

Definition at line 240 of file r_misc.cpp.

Referenced by uiSequenceNode::draw(), SEQ_Render3D(), and UI_Transform().

void R_ScreenShot ( int  x,
int  y,
int  width,
int  height,
const char *  filename,
const char *  ext 
)

Take a screenshot of the frame buffer

Parameters
[in]x
[in]y
[in]width
[in]height
[in]filenameForce to use a filename. Else nullptr to autogen a filename
[in]extForce to use an image format (tga/png/jpg). Else nullptr to use value of r_screenshot_format

Definition at line 101 of file r_misc.cpp.

References Cmd_Argc(), Cmd_Argv(), Com_Printf(), Com_sprintf(), f, FILE_WRITE, FS_CheckFile(), FS_Gamedir(), FS_OpenFile(), cvar_s::integer, MAX_OSPATH, Mem_Free, Mem_PoolAllocTypeN, Q_strcasecmp, R_CheckError, r_screenshot_format, r_screenshot_jpeg_quality, R_WriteCompressedTGA(), R_WriteJPG(), R_WritePNG(), SSHOTTYPE_JPG, SSHOTTYPE_PNG, SSHOTTYPE_TGA_COMP, cvar_s::string, type, and vid_imagePool.

Referenced by CL_BattlescapeRadarGenerate_f(), and R_ScreenShot_f().

void R_ScreenShot_f ( void  )
void R_Transform ( const vec3_t  transform,
const vec3_t  rotate,
const vec3_t  scale 
)

Perform translate, rotate and scale operations on the current matrix.

Note
Every parameter may be nullptr and is ignored then
Parameters
[in]transformTranslation vector
[in]rotateRotation vector
[in]scaleScale vector (keep in mind to not set this to vec3_origin or zero)
See also
R_PushMatrix
R_PopMatrix

Definition at line 220 of file r_misc.cpp.

Referenced by UI_DrawNode(), and UI_Transform().