Updated,100% working.
First of all you need to Download Graphics Header File Setup for CodeBlocks and Dev cpp.zip(all the files are provided)
Instruction for adding graphics file in Code::Blocks
-
Copy "graphics.h" and "winbgim.h" files to "include" folder of CodeBlocks directory. Default location is ("C:\Program Files (x86)\CodeBlocks\MinGW\include")
-
Copy "libbgi.a" to file to "lib" folder of CodeBlocks directory. Default location is ("C:\Program Files (x86)\CodeBlocks\MinGW\lib")
-
Open CodeBlocks and go to (Settings > Compiler > Linker Settings)
-
Link Libraries (left), Click on "Add" button, then click "Browse" and select the "libbbgi.a" file that you have copied in CodeBlocks directory.. Default location is (C:\Program Files (x86)\CodeBlocks\MinGW\lib\libbgi.a) and then click "Open" button.
-
Other linker option (right), copy the text below and paste there -lbgi -lgdi32 -lcomdlg32 -luuid -loleaut32 -lole32
-
Click "OK"
Done...
Instruction for adding graphics file in Dev C++
-
Copy "graphics.h" and "winbgim.h" files to "include" folder of CodeBlocks directory. Default location is ("C:\Program Files (x86)\Dev-Cpp\MinGW\include")
-
Copy "libbgi.a" to file to "lib" folder of CodeBlocks directory. Default location is ("C:\Program Files (x86)\Dev-Cpp\MinGW\lib")
-
Open Dev-Cpp and go to (Tools > Compiler Options > Compiler)
-
Yo can see this command -lglu32 -lglut32 -lopengl32
-
After the -lopengl32,add space and copy the text below and paste there -lbgi -lgdi32 -lcomdlg32 -luuid -loleaut32 -lole32
-
Click "OK"
Done...