Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - zivkovic

Pages: [1]
1
Graphics / White sprite
« on: May 31, 2012, 09:43:00 pm »
Okay, im having this problem and don't quite know how to fix it.

I have a class that implements/extends the class Sprite.
class Background: public Sprite {
public:
        Background();
        virtual ~Background();
};
Then in the constructor I got it like this:
Background::Background() {
        Image image;
        image.LoadFromFile("Sprites/BitRed.png");
        SetImage(image);
}

And I'm using it like this:

Background sprite;
        win.draw(sprite);

But I'm always getting white box in the same size as the image without anything else.
Can someone please tell me how to  fix it or give me an example usage.

Thanks!

2
General / SFML gets terminated right away?
« on: May 18, 2012, 06:52:46 pm »
Okay, I'm new to this and firts thing I encountered is this. No mater what sample program I choose, it never runs as it should.

I'm using Eclipse C/C++ CDT and SFML 1.6. And for the compiler im using mingW.

Here are my settings in Eclipse C++ :

http://screensnapr.com/v/rt2Spy.png
http://screensnapr.com/v/oqPWxg.png
http://screensnapr.com/v/31mNQT.png

And here is the example i tried:

Source file:
http://screensnapr.com/v/8nv3tn.png

Header file:
http://screensnapr.com/v/0uoX3u.png

And after I run the program it immediatly does this:
http://screensnapr.com/v/drKR2b.png

Id appreciate any help. Thanks !

Pages: [1]
anything