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

Author Topic: [Ubuntu] Resizing a window hangs up app and system  (Read 5294 times)

0 Members and 1 Guest are viewing this topic.

BlueCobold

  • Full Member
  • ***
  • Posts: 105
    • View Profile
[Ubuntu] Resizing a window hangs up app and system
« on: September 02, 2015, 03:02:12 pm »
Hey. My game uses resizeable windows and they can be resized properly on Windows and OS X, but when trying to resize them on Ubuntu, everything goes very bad. I pick the window-border, move the mouse a little and the window size changes, *but* a blink later it switches right back to the previous size and even worse, when releasing the mouse-button, the window *keeps* resizing with every mouse move (and switching back and forth) all the time. That results in the app basically hanging up and my system too. Rendering is getting totally messy overall and becoming unresponsive until I kill the app via CTRL+C in the terminal it was launched from. The more I move the mouse, the worse the overall system performance gets.
Any ideas?

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11035
    • View Profile
    • development blog
    • Email
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #1 on: September 10, 2015, 12:47:11 am »
Are you testing things still in a VM or is it a native system?
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

BlueCobold

  • Full Member
  • ***
  • Posts: 105
    • View Profile
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #2 on: September 10, 2015, 10:42:59 am »
VM, but I got same behavior reported from others on native systems.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11035
    • View Profile
    • development blog
    • Email
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #3 on: September 10, 2015, 11:23:23 am »
What Ubuntu version, what window manager and which SFML version?
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

BlueCobold

  • Full Member
  • ***
  • Posts: 105
    • View Profile
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #4 on: September 21, 2015, 02:00:22 pm »
Ubuntu 14.04
Window Manager Compiz (CURRENT_DESKTOP/SESSION -> Unity 3D)
SFML 2.3.2
« Last Edit: September 21, 2015, 02:03:34 pm by BlueCobold »

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #5 on: September 21, 2015, 02:20:06 pm »
Please provide a minimal example that reproduces the problem.

BlueCobold

  • Full Member
  • ***
  • Posts: 105
    • View Profile
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #6 on: September 21, 2015, 02:36:54 pm »
The SFML-sample is a minimal example.

binary1248

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1405
  • I am awesome.
    • View Profile
    • The server that really shouldn't be running
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #7 on: September 21, 2015, 03:21:26 pm »
Build both SFML and your application in debug and see if anything shows up on the console. If nothing shows up, you can try using a system profiler to see where the system spends most of its time while running your application.
SFGUI # SFNUL # GLS # Wyrm <- Why do I waste my time on such a useless project? Because I am awesome (first meaning).

BlueCobold

  • Full Member
  • ***
  • Posts: 105
    • View Profile
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #8 on: September 21, 2015, 03:28:53 pm »
Can't debug, because it messes up my entire system. I will build in debug and monitor the console and error log when I have the time and report back,

Jesper Juhl

  • Hero Member
  • *****
  • Posts: 1405
    • View Profile
    • Email
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #9 on: September 21, 2015, 03:30:42 pm »
Can't debug, because it messes up my entire system.
That sounds like a problem you might want to fix first. Development qithout being able to use a debugger is going to be a pain in the neck going forward.

BlueCobold

  • Full Member
  • ***
  • Posts: 105
    • View Profile
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #10 on: September 21, 2015, 04:32:41 pm »
I can use a debugger in general, but I can't debug this specific bug, because the bug causes my system to get messed up. See the original report in the first comment in this topic.

binary1248

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1405
  • I am awesome.
    • View Profile
    • The server that really shouldn't be running
Re: [Ubuntu] Resizing a window hangs up app and system
« Reply #11 on: September 23, 2015, 04:36:08 am »
Build the application in debug with profiling (gprof) enabled. Let it run a bit, do stuff to your system, then close/kill it. The profiling data should still be saved AFAIK. You can then use gprof to process it and see where most of the time (if any) is spent inside your application and SFML.

If it gets really bad, you can always just SSH into your machine from another and run something like oprofile from the command line while the application is running. Just like gprof, you can process the collected data in peace after you kill the application once you think enough samples have been collected.
SFGUI # SFNUL # GLS # Wyrm <- Why do I waste my time on such a useless project? Because I am awesome (first meaning).