10-20-2025, 11:52 PM
and AI says.....
Here's a breakdown of the commands and versions available in QB64:
OpenGL 1.1 fixed-function pipeline: Most of the _GL commands directly map to OpenGL 1.1 functions, such as glBegin, glEnd, glVertex2f, glColor3f, and glOrtho. This means you are generally limited to the rendering methods of the mid-90s, using commands to define vertices and draw primitives.
Compatibility contexts: While the commands themselves are from an older version, the QB64 compiler and its underlying libraries (like SDL) can request a "compatibility profile" context from the graphics driver. This allows code written for the older fixed-function pipeline to run on modern OpenGL drivers, which primarily support newer core profiles.
System-dependent capabilities: The specific OpenGL version and extensions your program can utilize ultimately depend on the user's graphics drivers and hardware. For example, if a user's graphics card supports OpenGL 4.5, your QB64 program can still run, as the driver will execute the older, backward-compatible commands.
No direct access to modern OpenGL: The core QB64 language does not provide native keywords for modern OpenGL features like shaders, Vertex Buffer Objects (VBOs), or Framebuffer Objects (FBOs). To use these features, you would need to use DECLARE statements to directly access the functions from an external DLL or shared object, effectively writing C++ style code within your BASIC program.
Hope that helps! (I learnt from it so happy days!)
John
Here's a breakdown of the commands and versions available in QB64:
OpenGL 1.1 fixed-function pipeline: Most of the _GL commands directly map to OpenGL 1.1 functions, such as glBegin, glEnd, glVertex2f, glColor3f, and glOrtho. This means you are generally limited to the rendering methods of the mid-90s, using commands to define vertices and draw primitives.
Compatibility contexts: While the commands themselves are from an older version, the QB64 compiler and its underlying libraries (like SDL) can request a "compatibility profile" context from the graphics driver. This allows code written for the older fixed-function pipeline to run on modern OpenGL drivers, which primarily support newer core profiles.
System-dependent capabilities: The specific OpenGL version and extensions your program can utilize ultimately depend on the user's graphics drivers and hardware. For example, if a user's graphics card supports OpenGL 4.5, your QB64 program can still run, as the driver will execute the older, backward-compatible commands.
No direct access to modern OpenGL: The core QB64 language does not provide native keywords for modern OpenGL features like shaders, Vertex Buffer Objects (VBOs), or Framebuffer Objects (FBOs). To use these features, you would need to use DECLARE statements to directly access the functions from an external DLL or shared object, effectively writing C++ style code within your BASIC program.
Hope that helps! (I learnt from it so happy days!)
John

