473,748 Members | 8,933 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Colour and drawings or graphics in C++

I've been teaching myself the C++ Programming language. So far however,
I have not come across any useful tutorials on how I can output
coloured text, create drawings or graphics in C++. All I can create is
a simple console based application.
I would like to know if it's possible to do it using just the standard
header files or do I have to get proprietary ones. If there's anyone
with a suggestion or a good tutorial he/she knows of, please assist me.

Aug 27 '06 #1
6 3115
In article <11************ **********@m73g 2000cwd.googleg roups.com>,
fr*********@gma il.com says...
I've been teaching myself the C++ Programming language. So far however,
I have not come across any useful tutorials on how I can output
coloured text, create drawings or graphics in C++. All I can create is
a simple console based application.
I would like to know if it's possible to do it using just the standard
header files or do I have to get proprietary ones. If there's anyone
with a suggestion or a good tutorial he/she knows of, please assist me.
You can't do it with the standard library. There are some possibilities
in the range between standard and proprietary though. OpenGL, for one
obvious possibility, isn't part of the C++ standard, but definitely
isn't proprietary to one organization either -- it's available on a
fairly wide variety of hardware and software, including most of the
widely used OSes (e.g. *BSD, Linux, MacOS, Windows).

--
Later,
Jerry.

The universe is a figment of its own imagination.
Aug 27 '06 #2
Fredmanglis wrote:
I've been teaching myself the C++ Programming language. So far however,
I have not come across any useful tutorials on how I can output
coloured text, create drawings or graphics in C++. All I can create is
a simple console based application.
This is true; no input/output beyond simple console means is possible
with portable C/C++.
I would like to know if it's possible to do it using just the standard
header files or do I have to get proprietary ones. If there's anyone
with a suggestion or a good tutorial he/she knows of, please assist me.
You don't have to use proprietary ones, as there are loads of free
alternatives. You need to look what's available on your platform. What
platform are you using?

If you're a beginner and want to deal with colourful user interfaces,
you might also want to consider a different language. Higher level
languages can provide an easier starting point.

Jens
Aug 27 '06 #3

Jens Theisen wrote:
Fredmanglis wrote:
I've been teaching myself the C++ Programming language. So far however,
I have not come across any useful tutorials on how I can output
coloured text, create drawings or graphics in C++. All I can create is
a simple console based application.

This is true; no input/output beyond simple console means is possible
with portable C/C++.
I would like to know if it's possible to do it using just the standard
header files or do I have to get proprietary ones. If there's anyone
with a suggestion or a good tutorial he/she knows of, please assist me.

You don't have to use proprietary ones, as there are loads of free
alternatives. You need to look what's available on your platform. What
platform are you using?

If you're a beginner and want to deal with colourful user interfaces,
you might also want to consider a different language. Higher level
languages can provide an easier starting point.

Jens
Thanks. I am using Windows Operating Systems though I want at the
earliest convenient time to transfer to Linux. However since I am
currently using Windows I could take any help you have currently.

Aug 27 '06 #4
Fredmanglis wrote:
Thanks. I am using Windows Operating Systems though I want at the
earliest convenient time to transfer to Linux. However since I am
currently using Windows I could take any help you have currently.
If that means you're using VisualStudio, I'd just use what Microsoft
offers, as it's probably an easy start - though it's indeed proprietary.

It really depends on quite a lot of things, but my impression is that
you don't really care and just want to play around a bit with graphical
user interfaces. In this case, VisualStudio might be good starting point
- though I don't have any experience with it.

There are zillions of alternatives, but it doesn't really matter too
much, if you just want to experiment.

Jens
Aug 27 '06 #5

Fredmanglis wrote:
I've been teaching myself the C++ Programming language. So far however,
I have not come across any useful tutorials on how I can output
coloured text, create drawings or graphics in C++. All I can create is
a simple console based application.
I would like to know if it's possible to do it using just the standard
header files or do I have to get proprietary ones. If there's anyone
with a suggestion or a good tutorial he/she knows of, please assist me.
I was like you one year ago, looking for a convenient way to draw in
C/C++.
I can advise you SDL, which is a very well documented open source
multiplatform library, and totally free !!! To my opinion, SDL is
perfect to begin with 2D graphics, though you can also use to make 2D
games because SDL manages input (keyboard, joystick, mouse).

I started with this very good serie of 6 tutorials. Starting from
scratch, the last tutorial will cover anything to develop a space
shooter like game.

Here are the tutorials :
http://cone3d.gamedev.net/cgi-bin/in...s/gfxsdl/index

And here is the website :
http://www.libsdl.org where you can download the runtime and the
developement libraries

Aug 27 '06 #6

Aurelien rainone wrote:
Fredmanglis wrote:
I've been teaching myself the C++ Programming language. So far however,
I have not come across any useful tutorials on how I can output
coloured text, create drawings or graphics in C++. All I can create is
a simple console based application.
I would like to know if it's possible to do it using just the standard
header files or do I have to get proprietary ones. If there's anyone
with a suggestion or a good tutorial he/she knows of, please assist me.

I was like you one year ago, looking for a convenient way to draw in
C/C++.
I can advise you SDL, which is a very well documented open source
multiplatform library, and totally free !!! To my opinion, SDL is
perfect to begin with 2D graphics, though you can also use to make 2D
games because SDL manages input (keyboard, joystick, mouse).

I started with this very good serie of 6 tutorials. Starting from
scratch, the last tutorial will cover anything to develop a space
shooter like game.

Here are the tutorials :
http://cone3d.gamedev.net/cgi-bin/in...s/gfxsdl/index

And here is the website :
http://www.libsdl.org where you can download the runtime and the
developement libraries
I do agree SDL is perfect to start.
But SDL does not have multiple windows :( If you need that, you have to
switch to another toolkit.

Aug 28 '06 #7

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

Similar topics

1
2379
by: Ali | last post by:
Hi, I wrote the following code and when I loaded the images as static images my background displayed as black (set at start of code), however, now I've started (trying!) to get my image to move, my background has defaulted to white. Can anyone tell my why this is and how to correct it? Thanks very much, Ali :o)
0
1209
by: ChadDiesel | last post by:
I have a table of parts that I would like to add a field for drawings. These drawings are image files that are on different tabs in an Excel Workbook--1 image/drawing per worksheet/tab. Most of the Excel workbooks have 2 tabs. I need to print these drawings in a report. I added an OLE Object field to my table and selected the location of the file on the network drive with the "link" option checked: \sharedrive\Drawings\drawing1.xls ...
7
1895
by: ChadDiesel | last post by:
Hello everyone, I'm having a problem with Access that I need some help with. The short version is, I want to print a list of parts and part quantities that belong to a certain part group---One list per page. I created a report that groups the parts by part classification group with a force new page after each group. The report is based on a query of that week's orders. Some of these parts have drawings (usually 2 each stored in an...
2
4131
by: Flare | last post by:
Hi. I have made a simple painting applcation. I have a mainform wich creates a class called drawingPanelwich inherit from Panel. In the drawingPaneli have overriden onPaint an the the painting. Now on my mainform i have a button called Print. I know how to print .....PrintPageEventArgs e (e.graphics......) But HOW do i get the things i ave painted on the drawingPanel? I cant see how i can access this temporary paint job. How is this...
2
1802
by: Carl Gilbert | last post by:
Hi I am looking to edit an icon at runtime on menu items such as change fill colour. I wish to replicate the features found in most applications where by the coloured bar on a colour picker icon changes colour to the last selected colour. Therefore the user can easily tell which colour will be apllied when
4
1450
by: Thief_ | last post by:
I'm trying to create many squares on a form and for every new square, change the background colour to the next colour. I'm trying to create a colour palette showing all available colours and their colour name. My problem is that I can not figger out how to create a new panel at specific intervals across and down the form. Here's the code I have so far: Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles...
11
8093
by: Tim Marshall | last post by:
I use Terry Kreft's & Stephen Lebans colour dialog procedures for users to pick colours for various control properties in certain apps. Is there a way to take the colour code that is displayed in a backcolor/forecolor/etc property and calculate the "reverse colour"? In other words, If a user picks 255 (red) for a control backcolor, I'd like to be able to calculate the opposite or negative of that colour and assign the control's...
4
1725
by: rdemyan via AccessMonster.com | last post by:
My application deals with building information. Users may want to view autocad drawings for a particular building. The problem is that the central server is so slow for some users that it could take five to ten minutes to open an AutoCad drawing. So I'm looking for a strategy where I could allow users to download these drawings to their local hard drive and then access the drawings from there. This is also complicated by the fact that...
3
17058
by: Samuel | last post by:
Can anyone advice how to set the background colour of a new Bitmap Thank you, Samuel
0
8826
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9534
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9316
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8239
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4597
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4867
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3303
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2777
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2211
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.