graphics in codebloc & vcc

graphics.h doesnt works in codeblocs or visul cpp...then how should i use to display graphics or convert programs with graphics.h header file in codeblocs?
"..doesnt work" (sic) is kind of a useless description of your problem, what is the error you are getting when you go to include the header file?
closed account (zb0S216C)
Rahul Raja wrote:
graphics.h doesnt works in codeblocs or visul cpp

I tried to include <graphics.h> in VCE '10 and it appears to be an invalid file. Is <graphics.h> a file within MinGW suite that came with Code::Blocks?

Rahul Raja wrote:
in codeblocs

Are your using VCE/VCS '10, or Code::Blocks?

Wazzak
Last edited on
Also do you mean "Graphics.h" the C header file for SFML? Are you sure you didn't grab "Graphics.hpp" instead?
I assumed that the OP meant "graphics.h" the DOS graphics header. If that is the case, it doesn't come with modern compilers, which is why you are having problems. You should probably not be using it anyway...
I thought that graphics.h was only in old versions of Borland?
closed account (zb0S216C)
Until he/she specifies the IDE he/she is using, what he/she is trying to accomplish, and what errors he/she is receiving, we can only guess.

Wazzak
The OP is talking about the old <graphics.h> BGI stuff for the CGA/EGA/VGA/Herc/etc cards under DOS.

Google around "WinBGIm".
king214 wrote:
I thought that graphics.h was only in old versions of Borland

Correct.

However, there are many BGI implementations based on windows API out there.

Here's one of them -> http://www.garret.ru/cpp.html (scroll down)
Here's another one -> http://csci.biola.edu/csci105/using_winbgi.html

EDIT: Damn... Hadn't I decided to google for the stuff above, I would have posted before Duoas...
Last edited on
Graphics.h is a graphics library from borland.

I ran a program which included included graphics header file and it didn't compile on latest borland c++ ide.It worked for my in turbo c++ environment.

Now that we have shifted from Windows XP to Windows 7 you can see that Turbo c++ doesn't work on this operating system.

So for this I downloaded DOS emulator(DOSBOX) installed it in Windows 7 and ran Turbo c++ in this emulator.

I then tested the graphics program which worked fine.

Topic archived. No new replies allowed.