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

Pages: 1 2 [3] 4 5 ... 34
31
General / Re: Graphics.hpp Link error
« on: January 09, 2018, 04:37:35 pm »
Your image says you've configured for the x64 Platform, are you building for x64, or x86/Win32?

32
There was discussion about making a general WM_CLASS for all SFML windows, but looks like that fell through.

Otherwise, SFML sets the a window's class to it's initial title, so you'd need to add a for_window[class="my sfml window title"] floating enable to your i3/config.

34
General / Re: Font will not load from file while injected
« on: January 06, 2018, 11:20:40 pm »
And for reference, Visual Studio's default working directory when executing is the project directory

(the setting is <right-click on project> -> Properties -> Configuration Properties -> Debugging -> Working Directory)

35
SFML projects / Re: [Release][GUI] SFML + ImGui lib
« on: January 06, 2018, 11:06:53 pm »
I've just added a #include <imgui-sfml/imconfig-SFML.h> to my imconfig.h.

Make the compiler do the copying for me.

For reference, I have a similar project file structure:

./project-root/
    imgui/
    imgui-sfml/
    project/
        imconfig.h
        ...

36
I can confirm this happens on i3 on Arch Linux.

I made a small change in SFML that corrected the behavior for me.
(click to show/hide)

Slashcash, would you mind checking if it fixes it for you? https://github.com/dabbertorres/SFML/tree/unix-window-fullscreen

If it does, eXpl0it3r, can I go ahead and make a PR for it?

37
Isn't that how the behavior of focus is defined in Windows? A program can be in the foreground, but it doesn't have focus until the user interacts with it? (ie: I can use my mouse's scroll wheel in one window, but be typing in another window)

Looking at the documentation for SwitchToThisWindow
Quote
[This function is not intended for general use. It may be altered or unavailable in subsequent versions of Windows.]
and
Quote
This function is typically called to maintain window z-ordering.
That makes me think it might not do quite what the name says it would.

Does using SetFocus instead change the behavior of your example?
(Also, it's documentation specifically references the events that SFML listens for, WM_KILLFOCUS and WM_SETFOCUS)

38
Has also been tested on Arch Linux.

39
C / Re: Memory Leak CSFML 2.4
« on: November 16, 2017, 07:18:23 pm »
If you're using a tool like valgrind, and you're tracing call stacks (make sure tracing to dynamic library is enabled, if applicable), you should see a call to the library for your graphics driver as the source of the leak.

It could also be memory that is allocated near the beginning of the application, and not freed until the application is closing.

40
C / Re: Memory Leak CSFML 2.4
« on: November 15, 2017, 07:22:01 pm »
Keep in mind that (as has been the case in the past) memory leaks found "in" SFML were found to be caused by the graphics driver.

This may be the case.

41
General / Re: Please how to do to run my poor SFML game on a 64 bit system?
« on: November 12, 2017, 08:01:28 am »
You are correct, the executable, along with any required DLLs, must be the same architecture.

On your space shooter game, I ran a corflags.exe (included in a .NET SDK) command to force your executable (which was built as Any CPU) to run as a 32-bit/x86 process on my 64-bit/x64 machine.

42
General / Re: Please how to do to run my poor SFML game on a 64 bit system?
« on: November 11, 2017, 11:24:35 pm »
Yes, be sure to build as x86, not Any CPU.

43
SFML projects / Re: It Usually Ends In Nuclear War
« on: November 11, 2017, 02:36:49 am »
Yeah that was something I noticed. I ended up rolling my own, and I've been happy with it. Stress testing it was a fun exercise.

At a quick glance, ctpl and my impl seem to be fairly similar funnily enough, except ctpl is header-only (And used by a lot more people it looks like).

Boost was the other thing I noticed, a decent amount of libraries I found just let Boost go and do all the fun stuff!

44
Window / Re: RenderWindow as a parameter of a member function in a thread
« on: November 07, 2017, 11:25:25 pm »
Check your constructor, and the constructors of std::thread. (http://en.cppreference.com/w/cpp/thread/thread/thread)

If you're constructing a std::thread with a function that has non-optional arguments, you must pass them at construction time.

For reference, this is the error that tells you what is going wrong here:
Quote
In file included from main.cpp:4:0:
/usr/include/c++/7/thread: In instantiation of ‘struct std::thread::_Invoker<std::tuple<void (ClassWithThread::*)(sf::RenderWindow&), ClassWithThread*> >’:
/usr/include/c++/7/thread:127:22:   required from ‘std::thread::thread(_Callable&&, _Args&& ...) [with _Callable = void (ClassWithThread::*)(sf::RenderWindow&); _Args = {ClassWithThread*}]’
main.cpp:11:41:   required from here
/usr/include/c++/7/thread:240:2: error: no matching function for call to ‘std::thread::_Invoker<std::tuple<void (ClassWithThread::*)(sf::RenderWindow&), ClassWithThread*> >::_M_invoke(std::thread::_Invoker<std::tuple<void (ClassWithThread::*)(sf::RenderWindow&), ClassWithThread*> >::_Indices)’
  operator()()
  ^~~~~~~
(The arguments in your constructor don't match up with the expected)

45
SFML projects / Re: AchBall
« on: October 21, 2017, 09:54:00 pm »
Feel free to have him proofread it!

Pages: 1 2 [3] 4 5 ... 34
anything