Slow fade in and out in Qt applications - c++

Did someone else experience slow fading in Qt applications, for example when opening a new dialog from a main window? I'm running Ubuntu 12.04. LTS and Qt 4.8.1.
The application where I noticed that does some opengl rendering in a qglwidget. When the application runs, also other windows not belonging to the qt app are affected by slow fading in/out. The thing is that the qt app only uses 20% CPU load (also compiz) so I assume it's not caused by a high CPU load...

Are yours videocard drivers up to date?I had the same problem (using opengl through QGLWidget) and updating solved the problem.
If this isn't the solution,paste us some code.
Hope it helps.

Related

Qt video playback with libmpv makes QtWebEngine jquery content unsmooth - Ubuntu

I have a project that uses libmpv with the opengl widget (as per the examples that come with libmpv) along with a QtWebEngine widget that displays information, graphics and animations (a scrolling ticker for example).
I found that of the video playback options in Qt, mpv was the smoothest and most reliable. It will play back perfectly smoothly any video up to 1080p.
However while video is playing, any animations in QtWebEngine are unsmooth and jittery. Video is also slightly less smooth when something is moving in the webpage.
The system I'm testing with is not struggling for resources (cpu use is around 45%). There is also not any video decoding, as it's playing back raw video (but while it plays back encoded video, the effect is the same, regardless if hardware acceleration is enabled or not).
I figure that the mpv widget is interrupting the MainWindow thread while it processes frames and causing it to freeze every few milliseconds.
As far as I know there is no way to separate the mpv thread from the MainWindow thread though.
I don't know if it'll be possible to make mpv and webengine work together smoothly. I feel like there must be some way to run two widgets at once in one window and not have them mess with each other.
I'm testing with Ubuntu 18.04, QT 5.11 and the latest mpv from git.
Does anyone have any advice or pointers for what to try first? I realise this is somewhat of a broad question but my knowledge of graphics is limited. If anyone has advice on a conceptual level (I don't need someone to code me a fix) I can investigate myself.
Thank you.

All QT applications on my windows machine have garbled GUI

Starting recently, all QT applications have problems with window sizing and offset, f.i. the window origin (0,0) seems to be moved left and up, so that the menu disappears.
This is how it should look:
And this is how it looks with the problem:
Any idea what setting might have gone haywire ?
I suspect this has happened after an update of Intel HD Graphics Drivers. Anyway, since I have NVIDIA graphics aswell I tried to force the use of it instead of the default Intel HD Graphics, and voila!, it works perfectly. I had the same problem within Qt Creator, and this solved that as well.
It should be noted that I changed the default choice to NVIDIA, and now all applications using Qt work fine.

Alt-tab from fullscreen SDL

When I run a fullscreen window (C++ with SDL using the SDL_FULLSCREEN flag), alt-tab has no effect. Researching it, I only found posts of people having problems with it. Is there a way to do it consistently across different machines? (I'm running Ubuntu now, but I'd like portability) Does OpenGL handle this better? (considering switching)
SDL likes to XGrabKeyboard() when fullscreened on X11. This tends to lock out your window manager's hotkeys.
Fix SDL or fix your window manager.

Parts of GUI goes black e.g. while resizing

My application uses Gtkmm and gtkglextmm. It loads pictures form HDD and shows them using OpenGL capabilities. However when I (for example) resize mainwindow some parts of GUI goes black and I don't know why. On Ubuntu this problem doesn't exist.
Here is a video illustrating what I am talking about: http://youtu.be/XGNJmddh_m4
Without seeing your code, and assuming it does nothing arcane I'd attribute this to some bug in the GTK+ port for Windows itself. I suspect the doublebuffering built into GTK+ getting tangles up with the inherent doublebuffering of the composition process (Aero), and having a set a background erasure brush in the WNDCLASSEX of the windows GTK+ creates.
I'd file this as a bug with GTK+

Qt QML/C++ translucent window has glitches and performance problems on Mac OS X

I've developed a Qt/QML application which I display with a translucent QDeclarativeView in a translucent frameless QMainWindow (see this). The application is fairly complex with a a few ListViews inside and some threads that poll a remote server for data and feed the views. The program runs flawlessly and at full speed without glitches on Windows 7. But when I compile and run it on Snow Leopard I've got the following problems;
GUI rendering is slow in general
When I scroll the ListView with the mouse wheel, the wheel actions affect the underlying window and my GUI flickers as if it can't render fast enough. Also often when I click something on my GUI, the mouse click just passes through my window onto the underlying window and brings it in front.
Mouse actions feel awkward. There is a significant delay.
These problems are present on both the Release and Debug builds with/without gdb attached.
The problems sound related to me but I'm confused. Why would an application running perfectly on Win7 perform badly on Snow Leopard ? Am I missing some specific configuration ?