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 - AbuIbrahim

Pages: [1]
1
Network / SFML networking and me
« on: November 13, 2011, 06:07:29 am »
After using this great lib for things like games I thought of using it for the sole purpose of networking, like making a program that has nothing to do with games. A network analyzer would be a good example. Would this be a stupid choice or should I use a more dedicated lib like boost?

2
General / Program not working properly?
« on: August 05, 2011, 08:51:42 am »
Quote from: "Laurent"
Oh, so that's a very different problem. SFML 1.6 doesn't work with ATI cards on Windows with dynamic SFML libraries.


Alright so I will link them  Staticly Tommorow.

Thank you for all your help and taking your time and helping me.

3
General / Program not working properly?
« on: August 05, 2011, 08:23:53 am »
Quote from: "Laurent"
Sometimes IDEs leave the console alive at the end of the program. Try to run your program directly by double-clicking it, and see if it still happens.


double clicked the program in my debug folder of my project and same thing happend. The Insertion point is blinking and I can't close the window with my escape key.

Also I have tried telling SFML to display a rectangle but the same thing happens


***IMPORTANT**

I would also like to add that I can only get one window to display, and their are suppose to be 2 windows displaying. The window that does display itself is the console window but not the other window.


Code: [Select]
#include <SFML/Graphics.hpp>

int main()
{
 sf::RenderWindow App(sf::VideoMode(400, 300, 32), "Pokemon Prototype");  //render window
 sf::Shape Rect   = sf::Shape::Rectangle(100, 100, 200, 200, sf::Color::White);

 while (App.IsOpened()){

  sf::Event Event;
        while (App.GetEvent(Event))
        {
            // Close window : exit
            if (Event.Type == sf::Event::Closed)
                App.Close();
   if ((Event.Type == sf::Event::KeyPressed) && (Event.Key.Code == sf::Key::Escape))
                App.Close();

        }
  App.Draw(Rect);
        App.Display();
 }

    return 0;
}

4
General / Program not working properly?
« on: August 05, 2011, 08:12:48 am »
Quote from: "Laurent"
How do you launch your app? What's your OS?


Thank you for your quick reply, it's much appreciated.

My Graphic Card is a ATI  5750
My OS is a Windows 7 64 bit

I go to code blocks

1.) New Project
2.) Put in a CPP file
3.) I enter the code stated above
4.) I hit build and run.

This is how my linker settings look



-lsfml-graphics
-lsfml-window
-lsfml-system
-lopengl32
-lglu32


C:\Users\Ibrahim\Pictures\SFML-1.6\include

C:\Users\Ibrahim\Pictures\SFML-1.6\lib

SFML_DYNAMIC

5
General / Program not working properly?
« on: August 05, 2011, 03:52:25 am »
I have read over the TUT and did everything it wanted me to do. How ever when ever I put in the code to close a window by hitting escape it does not work, and all I get is a console window with a blinking white insertion point.


Code: [Select]
////////////////////////////////////////////////////////////
// Headers
////////////////////////////////////////////////////////////
#include <SFML/Window.hpp>


////////////////////////////////////////////////////////////
/// Entry point of application
///
/// \return Application exit code
///
////////////////////////////////////////////////////////////
int main()
{
    // Create the main window
    sf::Window App(sf::VideoMode(800, 600, 32), "SFML Events");

    // Get a reference to the input manager associated to our window, and store it for later use
    const sf::Input& Input = App.GetInput();

    // Start main loop
    while (App.IsOpened())
    {
        // Process events
        sf::Event Event;
        while (App.GetEvent(Event))
        {
            // Close window : exit
            if (Event.Type == sf::Event::Closed)
                App.Close();

            // Escape key : exit
            if ((Event.Type == sf::Event::KeyPressed) && (Event.Key.Code == sf::Key::Escape))
                App.Close();
        }

        // Get some useless input states, just to illustrate the tutorial
        bool         LeftKeyDown     = Input.IsKeyDown(sf::Key::Left);
        bool         RightButtonDown = Input.IsMouseButtonDown(sf::Mouse::Right);
        bool         JoyButton1Down  = Input.IsJoystickButtonDown(0, 1);
        unsigned int MouseX          = Input.GetMouseX();
        unsigned int MouseY          = Input.GetMouseY();
        int          JoystickX       = Input.GetJoystickAxis(1, sf::Joy::AxisZ);
        int          JoystickY       = Input.GetJoystickAxis(1, sf::Joy::AxisY);
        int          JoystickPOV     = Input.GetJoystickAxis(1, sf::Joy::AxisPOV);

        // Display window on screen
        App.Display();
    }

    return EXIT_SUCCESS;
}

Pages: [1]