473,321 Members | 1,667 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,321 software developers and data experts.

graphics functions under unix...

How can I use the graphics functions with gcc such as box,palette,color.
Nov 13 '05 #1
4 5320
hp*******@yahoo.com (ehab) wrote:
# How can I use the graphics functions with gcc such as box,palette,color.

Every unix should have a library called _curses_ which is a very old windowing
system that runs inside a terminal window. For modern bit mapped graphics,
you can use _X-Windows_. Some unices have other windowings, like MacOSX Aqua.

--
Derk Gwen http://derkgwen.250free.com/html/index.html
So....that would make Bethany part black?
Nov 13 '05 #2

"ehab" <hp*******@yahoo.com> wrote in message
How can I use the graphics functions with gcc such as
box,palette,color.

You need a non-standard library. The first thing to do is determine which
non-standard libraries are available on your system - if you have a GUI then
almost certainly some sort of graphics capability will be provided.

In your source you then #include the headers (non-standard) needed for that
library, and then call the functions as directed in the documentation.

Then you need to link the library at link time. This may be done
automatically, or it may be necessary to specify this directly to the
compiler, using an option like -l.
Nov 13 '05 #3
Malcolm wrote:
"ehab" <hp*******@yahoo.com> wrote in message
How can I use the graphics functions with gcc such as
box,palette,color.
You need a non-standard library.


If by non-standard, you mean something that gcc doesn't link in
by default, then yes. But if by non-standard, you mean some
third-party library, you don't really need that. You can do
all of the above with libX11, right? Windows, lines, rectangles,
colors, etc. It's probably not the best library to use for
a real application (with buttons, menus, etc.), but it might
not be bad for some experimentation and learning.

- Logan

Nov 13 '05 #4
Logan Shaw <ls**********@austin.rr.com> writes:
Malcolm wrote:
"ehab" <hp*******@yahoo.com> wrote in message
How can I use the graphics functions with gcc such as
box,palette,color.

You need a non-standard library.


If by non-standard, you mean something that gcc doesn't link in by
default, then yes. But if by non-standard, you mean some third-party
library, you don't really need that. You can do all of the above with
libX11, right?


I don't know in which of the five newsgroups Malcolm read the original post,
but "here" in comp.lang.c, everything not defined by the ISO C standard is
cosidered non-standard. Therefore, libX11 *is* non-standard in the context
of comp.lang.c.

That said, I think it is in fact possible to write a strictly conforming C
program which opens windows, draws buttons and menus, etc., on an X server.
Just implement the X protocol, and run the program in such a way that
standard input and standard output are network connections to the X server.
;)

Martin
Nov 13 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Markus Elfring | last post by:
Hello, A lot of clipart libraries offer free raster images. I am looking for a similar collection for vector graphics. Do you know a gallery or archive for the following formats? - Scalable...
2
by: JBiagio | last post by:
Hello All, I am attempting to learn a bit about the GDI+ transforms and charting data and I feel like I'm getting a handle on how the transforms work. My chart object has a large "canvas" bitmap...
10
by: eggbert | last post by:
Jeff Garcia deserves to play!!! Anyway, why has Microsoft eliminated the "Point" and "Pset" functions in VB.NET from what was already a limited selection of graphical functions in earlier versions...
3
by: Adam | last post by:
hi how could I use graphic in dos program, but compiled under windows compiler? graphics.h could not be compiled under windows. thanks in advance Adam
36
by: lovecreatesbeauty | last post by:
In the C programming language, I/O operation functions are declared in stdio.h, for example, fopen(), fclose(), fwrite(), fread(), fseek() ... But another set of I/O functions are also defined in...
1
by: MC felon | last post by:
i work on turbo c++. maybe i should upgrade to the ultimate compiler in c++ (visual, maybe..) can anyone please direct me to the best compiler? i mean to work on graphics a lot, too.. if i get...
12
by: Xah Lee | last post by:
Of Interest: Introduction to 3D Graphics Programing http://xahlee.org/3d/index.html Currently, this introduction introduces you to the graphics format of Mathematica, and two Java Applet...
1
ilikesuresh
by: ilikesuresh | last post by:
Hi How to add graphics options (For Ex Add color) in Unix C programming?
20
by: J de Boyne Pollard | last post by:
MThe library functions which are included to allow process Mlaunch, forking, and termination, imply that it is both Mpossible and desirable for a process to fork itself. This is Ma fundamental...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.