Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Blakeasd

macrumors 6502a
Original poster
Dec 29, 2009
643
0
Hello!
I am following along with the Video Tutorials Rock OpenGL tutorials and I am having an issue with the Terrain tutorial. Whenever I run the program I get an "image not found error". I create the project by
1) Creating a C++ Console Project

2) Deleting the default main.cpp file

3) Dragging in the files from the tutorial

4) Adding OpenGL and GLUT

The writer of the tutorial wrote a C++ image loader, so OpenGL can see the height map I am using.

Here is the code in PasteBin:

imageloader.cpp: http://pastebin.com/aHBAAMrY

imageloader.h http://pastebin.com/NSdb2xHP

main.cpp http://pastebin.com/QdwCuRZS

I wish I could figure out the image loader code, but I only know Objectve-C and enough C++ to use OpenGL.. :D

Thanks!
 

lloyddean

macrumors 65816
May 10, 2009
1,047
19
Des Moines, WA
Product Menu -> Edit Scheme
View Tab -> Options
Working Directory -> Use custom working directory

Point to your projects supporting data folder!
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.