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.


Messages - phild

Pages: [1]
1
Graphics / Re: build error with sf::Shape
« on: February 10, 2013, 04:50:40 pm »
Thanks for your help.
I'm off to study abstract types and hopefully learn a little bit more about c++. A never ending story: ;D

2
Graphics / build error with sf::Shape
« on: February 10, 2013, 12:00:19 am »
Hi,
I've just started with SFML 2.0 . I.m trying to draw a polygon using the following code

#include <cstdlib>
#include <iostream>
#include <SFML/Graphics.hpp>
#include <SFML/System.hpp>

using namespace std;

/*
 *
 */
int main(int argc, char** argv) {
    sf::Shape poly;
    return 0;
}

When I build the code I get this error

c:/SFML/SFML2/include/SFML/Graphics/Shape.hpp:246:5: error: 'sf::Shape::Shape()' is protected
main.cpp:19:15: error: within this context
main.cpp:19:15: error: cannot declare variable 'poly' to be of abstract type 'sf::Shape'

What have I missed?

I'm useing Netbeans and Vista.

Any help gratefully received.

Pages: [1]
anything