{"size": 617, "ext": "scrbl", "max_stars_repo_path": "scribblings/init.scrbl", "max_stars_repo_name": "LiberalArtist/sgl", "max_stars_repo_stars_event_min_datetime": "2018-07-29T04:13:52.000Z", "max_stars_repo_stars_event_max_datetime": "2022-02-14T16:11:17.000Z", "max_issues_repo_path": "scribblings/init.scrbl", "max_issues_repo_name": "LiberalArtist/sgl", "max_issues_repo_issues_event_min_datetime": "2017-08-25T20:26:37.000Z", "max_issues_repo_issues_event_max_datetime": "2022-02-26T17:48:40.000Z", "max_forks_repo_path": "scribblings/init.scrbl", "max_forks_repo_name": "LiberalArtist/sgl", "max_forks_repo_forks_event_min_datetime": "2021-06-23T03:01:13.000Z", "max_forks_repo_forks_event_max_datetime": "2022-01-01T03:01:16.000Z"}
{"max_stars_count": 10, "max_issues_count": 15, "max_forks_count": 4, "avg_line_length": 34.2777777778, "max_line_length": 70, "alphanum_fraction": 0.7811993517}
#lang scribble/doc
@(require "common.rkt" (for-label racket/class))

@title[#:tag "init"]{Initialization}

@defmodule[sgl/init]

Requiring the @racketmodname[sgl/init] library initializes
platform-specific OpenGL state to help avoid crashes when OpenGL
commands are incorrectly used without a current context.  This library
is @racket[require]d by @racketmodname[sgl] and
@racketmodname[sgl/gl], so it normally does not need to be
@racket[require]d explicitly.

On Mac OS X, @racketmodname[sgl/init] checks whether any GL context is
current, and if not, it creates a dummy context and sets it as the
current context.
