From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Delivered-To: caml-list@yquem.inria.fr Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by yquem.inria.fr (Postfix) with ESMTP id 67102BC75 for ; Wed, 23 Feb 2005 04:13:26 +0100 (CET) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j1N3DQnk017304 for ; Wed, 23 Feb 2005 04:13:26 +0100 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 EAA12386 for ; Wed, 23 Feb 2005 04:13:25 +0100 (MET) Received: from mail2.bluewin.ch (mail2.bluewin.ch [195.186.4.73]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j1N3D5BG017282 for ; Wed, 23 Feb 2005 04:13:25 +0100 Received: from [10.0.1.2] (83.76.251.179) by mail2.bluewin.ch (Bluewin AG 7.0.035) id 41DEA58B0046D9B8 for caml-list@inria.fr; Wed, 23 Feb 2005 03:13:04 +0000 Mime-Version: 1.0 (Apple Message framework v619.2) In-Reply-To: <200502230005.01479.jon@jdh30.plus.com> References: <20050222120308.GA2975@furbychan.cocan.org> <200502222216.25721.jon@jdh30.plus.com> <4a4478d088d9fa3d5d1d82dd42b163d8@epfl.ch> <200502230005.01479.jon@jdh30.plus.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Message-Id: Content-Transfer-Encoding: quoted-printable From: =?ISO-8859-1?Q?Daniel_B=FCnzli?= Subject: Re: [Caml-list] Cross-platform "Hello, World" graphical application in OCaml Date: Wed, 23 Feb 2005 04:13:12 +0100 To: caml-list@inria.fr X-Mailer: Apple Mail (2.619.2) X-Miltered: at nez-perce with ID 421BF4D6.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 421BF4C1.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; epfl:01 caml-list:01 ocaml:01 wrote:01 widget:01 widget:01 gtk:01 wxwindows:01 abstraction:01 mimic:01 cheers:01 defined:01 widgets:01 opengl:01 opengl:01 X-Spam-Checker-Version: SpamAssassin 3.0.2 (2004-11-16) on yquem.inria.fr X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.2 X-Spam-Level: Le 23 f=E9vr. 05, =E0 01:05, Jon Harrop a =E9crit : > On Tuesday 22 February 2005 23:30, Daniel B=FCnzli wrote: >> However the big problem of these custom gui systems is the lack of >> integration with the native gui system. This may not be an issue for >> fullscreen vizualisation tools or games but can be for other >> applications like editors (e.g., because you usually have a single >> window in which everything occurs (your gl context), you don't have >> access to platform specific save dialogs, look and feel, etc., etc.). > > I disagree. > > Firstly, you can have as many GL windows and contexts (and widgets) as=20= > you > like. You aren't restricted to just having one window with one widget=20= > and one > context. I didn't say you were restricted to one widget in one window. I said=20 that usually, OpenGL apps implementing their own gui system use only=20 one context (e.g. see the various cross-platform 3d modelers that do=20 so). There may be many reasons but what comes to my mind is : a) An OpenGL context is not a lightweight structure. Especially if you=20= are doing realtime rendering, a context switch is a heavy operation=0B.=20= Very often it is much more efficent to have a single context in which=20 you draw various subregion by setting the viewport and scissor rect=20 rather than creating many opengl contexts. b) OpenGL context management is not defined in the opengl specification=20= but by platform specific libraries (e.g. agl, wgl, glx, etc) that=20 behave quite differently and this means that you may run into various=20 issues (like platform dependent context texture sharing policy). > Secondly, using OpenGL does not prohibit the use of platform-specific=20= > look and > feel. There is no reason you shouldn't be able to bring up native=20 > menus and > dialogs. Qt, GTK and WxWindows all allow you to do this. Sure but if they do then : 1) Either they don't work at the level of OpenGL. That is they use the=20= platform specific gui libraries to provide their cross-platform=20 abstraction. Then we are not talking about the same thing (I was=20 talking about opengl-based gui systems). 2) Or they try to mimic the platform-specific look in their rendering,=20= an imitation that can become obsolated by any system update. But looking at the end of your message I think that we may not be=20 talking about the same thing. Cheers, Daniel=