module SDLGL:SDL OpenGL supportsig
..end
type
gl_attr =
| |
RED_SIZE |
(* | Size of the framebuffer red component, in bits | *) |
| |
GREEN_SIZE |
(* | Size of the framebuffer green component, in bits | *) |
| |
BLUE_SIZE |
(* | Size of the framebuffer blue component, in bits | *) |
| |
ALPHA_SIZE |
(* | Size of the framebuffer alpha component, in bits | *) |
| |
DOUBLEBUFFER |
(* | 0 or 1, enable or disable double buffering | *) |
| |
BUFFER_SIZE |
(* | Size of the framebuffer, in bits | *) |
| |
DEPTH_SIZE |
(* | Size of the depth buffer, in bits | *) |
| |
STENCIL_SIZE |
(* | Size of the stencil buffer, in bits | *) |
| |
ACCUM_RED_SIZE |
(* | Size of the accumulation buffer red component, in bits | *) |
| |
ACCUM_GREEN_SIZE |
(* | Size of the accumulation buffer green component, in bits | *) |
| |
ACCUM_BLUE_SIZE |
(* | Size of the accumulation buffer blue component, in bits | *) |
| |
ACCUM_ALPHA_SIZE |
(* | Size of the accumulation buffer alpha component, in bits | *) |
set_attribute
and get_attribute
.val swap_buffers : unit -> unit
swap_buffers
Swap OpenGL framebuffers/Update Display
val load_bmp : string -> Sdl.Video.surface
load_bmp file -> surface
Loads a Windows Bitmap file and loads it into a surface suitable for use as an OpenGL texture
val set_attribute : gl_attr -> int -> unit
set_attribute attr value
Sets the OpenGL attribute attr to value. The attributes you set don't take effect until after a call to set_video_mode
.
You should use get_attribute
to check the values after a set_video_mode
call.
val get_attribute : gl_attr -> int
get_attribute attr -> value
Returns the value of the SDL/OpenGL attribute attr in value.
This is useful after a call to set_video_mode
to check whether your attributes have been set as you expected.