Jump to content

WoW:GxApi: Difference between revisions

From Thunderbrew
No edit summary
No edit summary
Line 19: Line 19:


;
;
; <code>CGxDeviceOpenGl</code> : OpenGL implementation. Enabled by passing <code>-opengl</code> as a launch parameter, or setting a CVar: <code>SET gxApi "OpenGL"</code>
; <code>CGxDeviceOpenGl</code> : OpenGL implementation. Enabled by passing <code>-opengl</code> as a command-line argument, or setting a CVar: <code>SET gxApi "OpenGL"</code>
; <code>CGxDeviceD3d</code> : Direct3D 9 (DirectX) implementation.
; <code>CGxDeviceD3d</code> : Direct3D 9 (DirectX) implementation.
; <code>CGxDeviceD3d9Ex</code> : Direct3D 9Ex (DirectX) implementation
; <code>CGxDeviceD3d9Ex</code> : Direct3D 9Ex (DirectX) implementation

Revision as of 19:39, 12 June 2025

GxApi is a cross-platform graphics API that is part of the World of Warcraft engine. It:

  • Creates/destroys the window in which the game runs, which starts the game being able to read input events
  • Loads/unloads texture and geometry data
  • Creates/destroys textures
  • Draws to the window.

Graphics device

GxApi supports multiple low-level graphics APIs such as OpenGL and Direct3D (DirectX) 9. It does this by wrapping an base interface class, CGxDevice, whose virtual member functions handle the actual calls to the graphics driver.

Windows device

On Windows, the derived classes include:

CGxDeviceOpenGl
OpenGL implementation. Enabled by passing -opengl as a command-line argument, or setting a CVar: SET gxApi "OpenGL"
CGxDeviceD3d
Direct3D 9 (DirectX) implementation.
CGxDeviceD3d9Ex
Direct3D 9Ex (DirectX) implementation