From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.3 required=5.0 tests=BAYES_00,FREEMAIL_FROM, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,5b7ee26df9f9c357 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!feeder1.cambriumusenet.nl!feeder3.cambriumusenet.nl!feed.tweaknews.nl!83.128.0.11.MISMATCH!news-out1.kabelfoon.nl!newsfeed.kabelfoon.nl!bandi.nntp.kabelfoon.nl!news.ett.com.ua!not-for-mail From: anon@att.net Newsgroups: comp.lang.ada Subject: Re: OpenGL in Ada Date: Sun, 11 Jul 2010 20:46:53 +0000 (UTC) Organization: ETT newsserver Message-ID: References: Reply-To: anon@anon.org NNTP-Posting-Host: dialup-4.225.174.252.dial1.dallas1.level3.net X-Complaints-To: usenet@news.ett.com.ua X-Notice: Filtered by postfilter v. 0.6.1 X-Newsreader: IBM NewsReader/2 2.0 Xref: g2news1.google.com comp.lang.ada:12324 Date: 2010-07-11T20:46:53+00:00 List-Id: In , tmoran@acm.org writes: >> >>> Procedure Color ( red, green, blue : in double ); >> >>> Procedure Color ( red, green, blue : in float ); >> >> One problem you'll have is if a user wants to make a call with all >> literals, i.e. Color(1, 2, 3) or Color(1.0, 2.0, 3.0), the compiler >> won't know which version to use. The best solution I've found (besides >> making users specify a type) > >And what's wrong with requiring the user to be unambiguous by specifying >a type? It's unlikely there will be a lot of calls with all literals >(unless generated by some program) so it shouldn't be onerous. And >"Float'(1.0)" is clearer to the person reading the code five years >from now than "Color_F". What your are forgetting is the openGL is a specification from the openGL group ( opengl.org ), it is just like the Ada RM in that respect. For a program or package, to be classified as openGL it must comply with "openGL group" openGL specification. Changing any API part nullify the use of openGL in any part of your system. So, adding or altering any definitions about the given API must comply with the openGL specification. Names of the API functions and procedures with the API defined types are set by this openGL group. visit www.opengl.org for more information on openGL and the "openGL group" Also, you may find the API specifications predefined with examples in C that you can alter to Ada there as well.