Graphics in c++

Hello to all , I've recently moved to c++ (actually I'm still nowhere but thats a different topic ) . I have a lot of programs in QBasic and I've reached quite a level there ,but the language's old and a bit slow ,so I decided I'd learn c++ as easy as it seemed . But figures It's really different ,actually there was a day till I made the "Hello world" work (well an hour or two but that's all the programming i did that day :D (at the end I was pretty much pissed off)) . So as I said I have accomplishments in QB but all of them are graphics programs and as it seems to get a circle on the screen isn't that easy in c++ . I got that I should include the graphics.h and initgraph but I get that BGI doesn't work in windows (I'm with borland c++ 4.5 by the way) and I have no idea what to do . If someone can give a push on the graphics basics in c++ it'd be great :)
Hi :)

Been having the same problem as to how to do graphics programming in c++.

In order for you to do graphics programming you need graphics libraries. There are a lot of it in the internet, you just have to look for one. Try this site

http://hge.relishgames.com/

it a site to a free game engine. Yup game engine, but why game engine? This game engine has support for 2d graphics. Cant tell you that much about this one since Im still practicing this to. Just visit this site and download the gameengine installer. Try their tutorials, it helps :)

If you want to try also, google OGRE or OpenGL, for 3D graphics.
Borland C++ 4.5? No S***!!! I have Borland TURBO C++ 4.5!!!

The point is, both of these programs were created for old versions of Windows (like 3.1 or 95). It's likely that, by now, support for their features has been dropped.

I've been wanting the same thing, too. My best DBMS still has a textual interface.

Oh, by the way, if you still have OWL on that compiler, you can use the Windows API itself to draw. But I've never mastered its complexity.
Last edited on
Thanks for the answers :) jdstufu , eventually I learned that there's no build in or standard library ,but at that point I was fed up and left the c++ alone ,until now actually . Graham, I lived with the thought that c++ is a very used and therefor I hoped new standard programming language when I started ,but figures otherwise . Does there actually exist the heaven of a close-to-QBasic syntax and in the same time better graphics and windows supporting and ..I'm shutting up . So I'll be posting again if there's a move on the graphics.
PRINT "Hello, petko10!"

Hmm i dont know much about Qbasic syntax, does it look like Basic or Microsoft's Visual Basic?

on topic:
Maybe you should learn the basics of C++ before going to graphics. Most graphics lib uses advanced to expert syntax.
Last edited on
(reply to jdstufu)
about the download link you been given.
the tutorial or rather, the example it gave, by creating the same output do we have to have this:
{
#include "..\..\include\hge.h"
#include "..\..\include\hgefont.h"
#include "..\..\include\hgegui.h"
}
in the library???
and how do we get one???
(reply to Jeff)
Yes pretty much looks like it but it isn't it . For my purposes (being graphics) Visual basic sucks ,try drawing a line - it has to be an individual object ,and a program that makes n lines (400 for ex.) wouldn't be that easy (as I didn't see a way to create objects ,if not set from the beginning )(and I mean that in QB you just type line(x,y)-(x,y) and there you go ,if there is a way to create objects without the tools, the option VB is back again) .
closed account (z05DSL3A)
petko10,
Can you explain more about what you want to achieve? I, for one, find the phrase ‘graphics programs’ a little vague. Are you talking about programming game graphics, Graphical User interfaces, programs for producing graphics files...?
Well ,I'll tell you about some of my programs in QBasic . My first project (still simple) was for displaying a simulation of a 2D orbit of an object ,with insignificant to the given gravitational point ,mass (I cannot describe the feeling when in 2 in the morning I got a picture of an uneven orbit around the imaginary gravitational point :D ) . So then I made a 3D of that program and after some programming I have an algorithm (a program) with which you can observe the 3D orbit (and actually any given ,by coordinates ,points ,it's a separate program) .The next goal is to make a program that from two images makes a 3D (like the human eyes) (and imports it into the last program) . Now as expected just a day ago ,as I was trying to record the program for observation (capture the screen for every frame ) ,QB made every bmp for at least 2-3 sec and thats already slow . I did see it coming actually ,so now it's no longer "I should" ,but "I have " to swich on to c++ :) . So at the moment what I whan to achieve is the 3D observation program in c++ ,it needs only to make circles and lines and some normal calculations (+-*/sin,cosine,ATN which in qb gets the angle of which you've given the tg ) and that's it ,but i'm missing the circles and lines right now s,but I've got the direction (graphic libraries) ,so I'll be posting if I get stuck on that :) . Here are some of the programs ,but mostly unfinished versions (some day I'll get the finished ones there too) ,only the ZAPISL 0.5 is close to last :) : http://www.network54.com/Forum/178387/message/1190987111/ProgramList+petko10 .So ,to your question Grey , I think it's closest to game graphics .
Last edited on
closed account (z05DSL3A)

It that case OGRE would probably be worth a look.
1
2
3
4
5
6
7
What Is OGRE?  
OGRE (Object-Oriented Graphics Rendering Engine) is a scene-oriented, 
flexible 3D engine written in C++ designed to make it easier and more 
intuitive for developers to produce applications utilising hardware-
accelerated 3D graphics. The class library abstracts all the details of using 
the underlying system libraries like Direct3D and OpenGL and provides an 
interface based on world objects and other intuitive classes. 

http://www.ogre3d.org/
senatin,

sorry it tool me long to reply, was out for a while, had to finish a lot of my mastes project here in our university.

The ones you were asking are header files, they are necessary for you to be able to use the HGE lib.
Topic archived. No new replies allowed.