From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 75CFFBB9A for ; Tue, 4 Oct 2005 22:29:28 +0200 (CEST) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id j94KTRGQ027056 for ; Tue, 4 Oct 2005 22:29:27 +0200 Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id WAA06439 for ; Tue, 4 Oct 2005 22:29:27 +0200 (MET DST) Received: from nproxy.gmail.com (nproxy.gmail.com [64.233.182.204]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j94KTQ4V029751 for ; Tue, 4 Oct 2005 22:29:26 +0200 Received: by nproxy.gmail.com with SMTP id a4so1478nfc for ; Tue, 04 Oct 2005 13:29:26 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=d5y4VIcWqDV7DDjwNAsQ2XzGepayCgyxM5vCuaaySG3+/hkAmR6kVYi8B80iF8dYMjujjyb9zexI5AfZU4PcAx4hTWwWvRtOeGfV1eaBVxqpV5UdbNSoAYUjCp2m2zQDIEPLcu44C4uq+aMFXZnksRtAJE+GVweIZoxMOAYXMss= Received: by 10.48.226.10 with SMTP id y10mr938nfg; Tue, 04 Oct 2005 13:29:26 -0700 (PDT) Received: by 10.48.30.18 with HTTP; Tue, 4 Oct 2005 13:29:26 -0700 (PDT) Message-ID: Date: Tue, 4 Oct 2005 20:29:26 +0000 From: Chris Campbell Reply-To: Chris Campbell To: caml-list@inria.fr Subject: Automatic interfacing of ocaml to c? MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Miltered: at concorde with ID 4342E627.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 4342E626.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; interfacing:01 ocaml:01 lablgl:01 enumeration:01 variants:01 enumeration:01 lablgl:01 ocaml:01 functions:01 modules:01 opengl:01 opengl:01 tricky:02 binding:02 types:02 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=RCVD_BY_IP autolearn=disabled version=3.0.3 Hi, Has anyone done any work on this? I'm in the process of attempting a semi autogenerated binding to opengl using the mesa xml specifications of the interface and lablgl. This is very early days; so far all I've done is map the flat (a portion of the) gl enumeration space to a set of types and values, then auto generate tables mapping the ml variants to gl enumeration values ala lablgl. I have a good idea of what it will do and am just looking for advice from anyone who has done this sort of thing before (if any). The main problems so far arise from the flat gl space and wanting to split that up into a more friendly set of types and modules. In fact, I will only be generating the mundane stuff as some of this mapping is quite tricky and using that as a base. Many of the opengl functions are trivially mapped to OCaml but those that don't will be hand coded. Any thoughts? Regards, Chris