caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Christophe Raffalli <Christophe.Raffalli@univ-savoie.fr>
To: caml-list@inria.fr
Subject: [Caml-list] Announce: ocaml bindings for gles 3
Date: Sun, 6 Mar 2016 00:18:02 +0100	[thread overview]
Message-ID: <20160305231802.GA14665@delli7.univ-savoie.fr> (raw)

[-- Attachment #1: Type: text/plain, Size: 4162 bytes --]

Dear OCaml user,

I am please to annouce a first alpha release of gles3 for OCaml.
These are lightweight bindings for gles3, a join work with Alexandre
Miquel.

The package should be in the opam repository soon.
URLs: http://lama.univ-savoie.fr/~raffalli/gles3/
      http://lama.univ-savoie.fr/~raffalli/gles3/gles3-050316.tar.gz

This is also a call for contributions, mainly:
- to test and debug
- port the egl.ml file to other platforms than linux/EGL/X11
  (windows, OSX, linux/wayland, ios, android, ...)

Cheers,
Christophe Raffalli

--------------------------------------------------------------------
                         [1]OCaml [2]GLES 3.0 bindings

                            examples with shadows

Introduction

   This project aims at providing a portable way to do OpenGL (precisely
   GLES) application using OCaml. It comes in three parts:
     * Low level bindings which allow to call directly GLES functions.
       This binding tries to be reasonably type-safe using polymorphic
       variants to encode Glenum type. The low level bindings also provide
       some sanity checks for the size of bigarrays which allow to capture
       quite a lot of errors with clear messages.
     * High level bindings: to provide some auxiliary functions like
       matrix inversion and ease the development. For instance, to use
       shaders, with the high level bindings, you use compile_shader with
       the sources code, get a value of type unit program. Then, you can
       set the variables of the shaders (uniform or attributes), either as
       constant or function and get a function to finally run the shaders.
     * A way to open a window, start the main loop and interact. Currently
       only EGL under X11 is supported but it would be nice to have
       support for other platforms (windows, OSX, android, ios, wayland,
       ...) with exactly the same interface.

Authors

     * [3]Alexandre Miquel (initial low level bindings for GLES 2)
     * [4]Christophe Raffalli (partial port to GLES 3.0, high-level
       bindings and examples)

Documentation

     * [5]Generated html from the MLI files
     * the examples:
       [6]examples/testa_gles.ml: a rotating cube
       [7]examples/testb_gles.ml: a rotating cube with a texture
       [8]examples/testc_gles.ml: 7 rotating cubes with simple shadow
       mapping
       [9]examples/testd_gles.ml: 7 rotating cubes and 8 implicit surfaces
       with simple shadow mapping

TODO (please contribute !)

     * test and fix bugs !
     * documentation
     * complete the low-level bindings
     * develop the high-level bindings guided by more examples
     * provide support for more platforms (see introduction)
     * find a way to support multiple version of GLES (at least 2.0, 3.0,
       3.1) with only one OCaml library, and possibly in a transparent way
       when using the high-level bindings (i.e., the high lebel bindings
       should test the version and make the best choice)
     * collect regexp for error message in GLSL for most GLES vendors to
       give good error messages in all cases (only one vendor,
       nouveau/mesa supported currently). This is a pity that GLES does no
       define a standard at least for position in error messages.
     * ...

Known bugs

     * Mixing vertex arrays and buffer seems not to work (but no error
       flag are positionned), for instance, vertex in a buffer and normal
       in an array result in wrong normals. One shoud check this on a C
       program...
     * Textures are not yet garbage collected ... should be fixed soon

Références

   1. http://caml.inria.fr/
   2. https://www.khronos.org/registry/gles
   3. https://www.fing.edu.uy/~amiquel/
   4. file:///~raffalli
   5. file:///home/raffalli/Caml/gles3/main.html
   6. file:///home/raffalli/Caml/gles3/repos/examples/testa_gles.ml
   7. file:///home/raffalli/Caml/gles3/repos/examples/testa_gles.ml
   8. file:///home/raffalli/Caml/gles3/repos/examples/testa_gles.ml
   9. file:///home/raffalli/Caml/gles3/repos/examples/testa_gles.ml

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

             reply	other threads:[~2016-03-05 23:18 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-05 23:18 Christophe Raffalli [this message]
2016-03-06  0:42 ` Hendrik Boom
2016-03-06 11:14   ` Christophe Raffalli
2016-03-06 14:03     ` Hezekiah M. Carty
2016-03-06 16:25       ` Christophe Raffalli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160305231802.GA14665@delli7.univ-savoie.fr \
    --to=christophe.raffalli@univ-savoie.fr \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).