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

Pages: 1 ... 3 4 [5] 6 7 ... 16
61
SFML projects / Re: My last and best Super Mario game version
« on: November 16, 2017, 06:27:34 am »
That's why i have about 5-6 abandoned projects :D
And you're already a good example of someone who *does* finish games. :-)

thank you :)

62
Window / Re: Problem with Joystick Axis
« on: November 16, 2017, 06:16:39 am »
if (sf::Joystick::getAxisPosition(joyID, joyAxis) >  GAMEPAD_THRESHOLD)

63
Graphics / Re: unhandled exception in sfml 2.4.2 but not 2.4.1
« on: November 14, 2017, 05:55:47 pm »
you can use new and delete to manage the order.

64
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 14, 2017, 03:10:46 pm »
also why clang and libc++ isn't set as default in CMake?  :)

'Cause I haven't got around creating a PR for that. If you want to do it, your help is more than welcomed!

Sorry, i'm not familiar with Mac OS at all and i'm afraid to do something wrong.

And about the issue - may be if someone familiar with OpenGL debugging could get trace of my example with and without the line i specified - it possibly help with fixing that  :)

65
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 14, 2017, 01:13:27 pm »
have a look at the options presented in §C++11 and Mac OS X of https://www.sfml-dev.org/tutorials/2.4/compile-with-cmake.php.

thanks, that works  :)

but, unfortunately issue still exists and this branch didn't helped.

also why clang and libc++ isn't set as default in CMake?  :)

66
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 14, 2017, 11:09:03 am »
I don't know what you mean by "precompile", but this error is most likely due to a mismatch in standard library used to compile your project and SFML. The nightly build are compiled with libstdc++ at the moment but the official release are compiled with libc++. Don't mix those two or you'll get such linker errors.

oh, sorry, not precompiled. i meant compiled binaries  :) how can i build it with libc++ instead of libstdc++?

67
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 14, 2017, 11:02:10 am »
PS: i guess i compile it with same standart libraries, because i do not specify it

68
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 14, 2017, 10:59:15 am »
make sure you're compiling your project and SFML with the same standard library.

but why I can compile 2.4.1 and it works. i can use precompiled 2.4.2, 2.4.1 and it works. but it fails if i use precompiled nightly build or compile that branch by myself?

69
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 14, 2017, 10:27:15 am »
Tried night build from here https://www.sfml-dev.org/artifacts/by-branch/bugfix/osx_render_target/
 got same linker error

70
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 14, 2017, 10:11:39 am »
I tried this patch on sfml 2.4.1 - it doesn't help, everything is the same.

I tried to compile branch bugfix/osx_render_target, but got this on compiling my project (i had no such issue with 2.4.1, that's why tested this patch on this version)

Undefined symbols for architecture x86_64:
  "sf::String::String(char const*, std::__1::locale const&)", referenced from:
 

Used simple "cmake . && make" to compile.

71
Audio / Re: I need Music restarting on an specific offset from 2nd loop
« on: November 14, 2017, 05:55:01 am »
if (getPos() > endLoop) setPos(startLoop + (getPos() - endLoop))

72
Graphics / Re: Mac OS X - High Sierra - RenderTexture::clear
« on: November 13, 2017, 04:10:26 pm »
thanks for reply, Lukas :) i'll try tomorrow (have no own mac, so use one from my work)

73
Graphics / Mac OS X - High Sierra - RenderTexture::clear
« on: November 13, 2017, 03:58:50 pm »
Hey guys! I have some troubles with clearing render textures (or may be RenderWindow). And made some investigations. Here's the code:

#include "include/SFML/Graphics.hpp"

int main() {
        sf::RenderWindow app(sf::VideoMode(400,400), "test");
        sf::RectangleShape a(sf::Vector2f(10,10)), b(sf::Vector2f(1,1));

        sf::RenderTexture tex;
        sf::Sprite spr;

        tex.create(400,400);
        tex.setActive();
        tex.clear(sf::Color(0,0,0,0));
        int pos = 10;
        spr.setTexture(tex.getTexture());

        while (app.isOpen()) {
                sf::Event event;
                while (app.pollEvent(event)) {
                        if (event.type == sf::Event::Closed)
                                app.close();
                }

                pos += 1;
                a.setPosition(sf::Vector2f(pos, 10));

                app.clear();

                // Uncomment this to fix
                //app.draw(b);

                tex.draw(a);
                tex.display();
                app.draw(spr);

                tex.clear();
                app.display();
        }
}

 

If there's no draw calls on RenderWindow except the one with drawing RenderTexture it leads to some artifacts.
I attached the image from my game and from the example. As you can see - there's kinda trail, but it is not the same as without "clear" call.

And there were no such issues before High Sierra update.

74
Graphics / Re: One Big Image VS Lot Little
« on: November 13, 2017, 12:07:55 pm »
just use different Rectangle for collision check

75
Graphics / Re: Shape is disappearing when i try to move it
« on: November 12, 2017, 09:04:30 pm »
you use move wrong way, so use setPosition instead.
move(arg) = setPosition(getPosition() + arg)

Pages: 1 ... 3 4 [5] 6 7 ... 16