Download the PHP package microscrap/open-gl without Composer

On this page you can find all versions of the php package microscrap/open-gl. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package open-gl

microscrap/open-gl — OpenGL bindings for PHP

Docs (production): ScrapyardIO · microscrap/open-gl 0.7.x

Docs CI Packagist Version PHP Version Require Requires ext-opengl Tests

PHP library that wraps the open-gl extension (ext-opengl) with global helpers, enums, and a static wrapper class. Every helper delegates to Microscrap\Bindings\OpenGL\GL, which is the only layer that calls Opengl\GL\GL.

Token constants from the OpenGL SDK (GL_COLOR_BUFFER_BIT, …) live here as backed PHP enums — the native extension does not expose them.

This is the bindings package — not the native extension. Ecosystem docs: 0.7.x.

Highlights

Requirements

Installation

Confirm ext-opengl is loaded:

Composer autoloads helper files in src/Helpers/, registering global gl* functions when the package is installed. Helpers are only defined if the name is not already taken (function_exists guard).

Note: microscrap/glfw also defines a small subset of gl* helpers for visual proofs. Prefer this package as the canonical OpenGL binding; load order decides which definition wins under the guard.

The two calling styles

C-ish — global functions with exact OpenGL C / extension names:

OO-ish — static wrapper class, same behavior:

Helpers never touch the extension directly; they delegate one-to-one to GL, which is the only layer calling Opengl\GL\GL. Flag/enum parameters take EnumType|int.

Name transforms

Wrapper surface (0.7.0)

Class Wraps Methods
GL Opengl\GL\GL full slice-1 draw API (state, immediate mode, buffers, textures, shaders/programs, draw)

Enums

Enum Purpose
ClearBufferMask glClear bitfield
EnableCap glEnable / glDisable
StringName glGetString
GetPName glGetIntegerv
PrimitiveMode glBegin / glDrawArrays
MatrixMode glMatrixMode
BufferTarget / BufferUsage buffer binds & uploads
TextureTarget / TextureParameterName / TextureParameter texture state
ShaderType glCreateShader
ErrorCode glGetError values

Testing

CI runs the same suite on PHP 8.3–8.5 (coverage uses the committed extension method snapshot when ext-opengl is not loaded).

License

MIT — see LICENSE.


All versions of open-gl with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
ext-opengl Version ^0.7.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package microscrap/open-gl contains the following files

Loading the files please wait ...