[prev in list] [next in list] [prev in thread] [next in thread] 

List:       ruby-talk
Subject:    Re: Graphics mode
From:       Ken Bloom <kbloom () gmail ! com>
Date:       2009-12-03 2:47:01
Message-ID: pan.2009.12.03.02.31.42 () gmail ! com
[Download RAW message or body]

On Thu, 03 Dec 2009 00:49:57 +0900, Teodor Carstea wrote:

>>C++ doesn't have a way to "initialize graphics mode"
> 
> Well, this is the way I do it in C++:
> 
> #include <graphics.h>
> void main(){
>   //initializing graphics mode
>         int gdriver=DETECT, gmode, errorcode;
>   initgraph(&gdriver, &gmode, "C:\\Progra~1\\BORLANDC\\BGI"); errorcode
>   = graphresult();
>   if(errorcode!=grOk) {
>        cout<<"Graphics error!!!\n"
>            <<"Press any key...";
>        getch();
>        exit(1);
>   }
> //...
> //AND HERE IS DA MAIN PROGRAM CODE.
> //...
> }
> 
> I'd like to make my ruby prog like this. Any Ideas? P.S.: If you have an
> idea, please describe it in a way you would talk to a noob, for I'm
> really green. Plus, I use Ubuntu, no comment.
> 
> Thanks!

What a blast from the past!

It ain't Ruby, but you might be interested in the BOSS library
( http://www.codedread.com/code.php#BOSS )
which implements a bunch of the old Borland C++ libraries on top of the 
modern SDL graphics library, if you plan to keep coding in C++.

--Ken

-- 
Chanoch (Ken) Bloom. PhD candidate. Linguistic Cognition Laboratory.
Department of Computer Science. Illinois Institute of Technology.
http://www.iit.edu/~kbloom1/


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic