I have tried putting my image in a multitude of different directories related to my project, but I cannot seem to get it to display. I only see a checkerboard with a red X. (image attached) Where do the image files need to be?
I am using Visual Studio 2010. I have been putting the image in the project directory (and tried all of the related directories.)
// Includes
#include "template.h"
// Namespace
using namespace AGK;
app App;
void app::Begin(void)
{
agk::SetVirtualResolution (640, 480);
agk::SetClearColor( 0,0,0 );
agk::SetSyncRate(60,0);
agk::SetScissor(0,0,0,0);
// Load a Sprite at index 1
agk::LoadSprite(1,"smiley.png");
// Scale the sprite to 25% of it's size
agk::SetSpriteScale(1, 0.25, 0.25);
}
void app::Loop(void)
{
agk::Print(agk::ScreenFPS());
// On gamepad press, spacebar hit, touch or left click enable
//physics on our sprite
// And make that sucker bouncy, gravity does the rest
if (agk::GetButtonPressed(1) || agk::GetPointerPressed()){
agk::SetSpritePhysicsOn(1, 2);
agk::SetSpritePhysicsRestitution(1, 0.8);
}
agk::Sync();
}
void app::End (void)
{
}