-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding WVuMeterGL as alternative for WVuMeter #10893
Conversation
I thought you worked on top of 2.3, if this is still true please rebase. or otherwiese resolve the conflicts. |
Shade: Put all VU meters in a fixed size parent widget
FYI with Tango I can shutdown cleanly -- with the other skins I get this segfault BacktraceDebug [Main]: 0 ms stopping pending Library tasks Debug [Main]: Destroying MixxxMainWindow Debug [Main]: 0 ms saving configuration Debug [Main]: 0 ms deleting skin Debug [Main]: ~DlgAutoDJ() Debug [Main]: 348 ms deleting menubar Debug [Main]: 372 ms deleting SoundManager [Thread 0x7ffe28fe9700 (LWP 92906) exited] Debug [Main]: 475 ms deleting ControllerManager Debug [Controller]: Controller polling stopped. Debug [Controller]: Deleting PortMIDI devices... Debug [Controller]: ControllerEngine shutting down... Debug [Controller]: Invoking shutdown() hook in scripts Debug [Controller]: Clearing function wrapper cache Debug [Controller]: Deleting ControlObjectScript "[Channel2]" "repeat" Debug [Controller]: Deleting ControlObjectScript "[Channel2]" "slip_enabled" Debug [Controller]: Deleting ControlObjectScript "[Channel2]" "beats_translate_curpos" Debug [Controller]: Deleting USB Bulk devices... Debug [Controller]: Deleting HID devices... [Thread 0x7ffef0826700 (LWP 92839) exited] [Thread 0x7ffef2ffd700 (LWP 92836) exited] Debug [Main]: 477 ms deleting VinylControlManager [Thread 0x7fffbe255700 (LWP 92820) exited] Debug [Main]: 477 ms deleting PlayerManager Debug [Main]: PlayerManager - Destroying Debug [Main]: TrackAnalysisScheduler - Stopping Debug [Main]: TrackAnalysisScheduler - Stopping Debug [AnalyzerThread 3 #4]: AnalyzerWaveform - ~AnalyzerWaveform(): Debug [AnalyzerThread 3 #4]: AnalyzerThread - Exiting worker thread Debug [AnalyzerThread 2 #3]: AnalyzerWaveform - ~AnalyzerWaveform(): Debug [AnalyzerThread 1 #2]: AnalyzerWaveform - ~AnalyzerWaveform(): Debug [AnalyzerThread 2 #3]: AnalyzerThread - Exiting worker thread Debug [AnalyzerThread 1 #2]: AnalyzerThread - Exiting worker thread Debug [AnalyzerThread 0 #1]: AnalyzerWaveform - ~AnalyzerWaveform(): Debug [AnalyzerThread 0 #1]: AnalyzerThread - Exiting worker thread Debug [AnalyzerThread 1 #2]: DbConnection - Closing database connection: "MIXXX-4" QSqlDatabase(driver="QSQLITE", database="file:///home/ronso/.mixxx_dev/mixxxdb.sqlite", host="", port=-1, user="mixxx", open=true) Debug [AnalyzerThread 3 #4]: DbConnection - Closing database connection: "MIXXX-6" QSqlDatabase(driver="QSQLITE", database="file:///home/ronso/.mixxx_dev/mixxxdb.sqlite", host="", port=-1, user="mixxx", open=true) Debug [AnalyzerThread 2 #3]: DbConnection - Closing database connection: "MIXXX-5" QSqlDatabase(driver="QSQLITE", database="file:///home/ronso/.mixxx_dev/mixxxdb.sqlite", host="", port=-1, user="mixxx", open=true) Debug [AnalyzerThread 0 #1]: DbConnection - Closing database connection: "MIXXX-3" QSqlDatabase(driver="QSQLITE", database="file:///home/ronso/.mixxx_dev/mixxxdb.sqlite", host="", port=-1, user="mixxx", open=true) Debug [AnalyzerThread 1 #2]: AnalyzerThread 1 - Exiting Debug [AnalyzerThread 2 #3]: AnalyzerThread 2 - Exiting Debug [AnalyzerThread 3 #4]: AnalyzerThread 3 - Exiting Debug [AnalyzerThread 0 #1]: AnalyzerThread 0 - Exiting [Thread 0x7ffef3fff700 (LWP 92834) exited] [Thread 0x7ffef37fe700 (LWP 92835) exited] [Thread 0x7fff04e81700 (LWP 92833) exited] [Thread 0x7fff05682700 (LWP 92832) exited] Debug [Main]: 480 ms deleting Library Debug [Main]: Wait to finish browser background thread Debug [Main]: Browser background thread terminated! [Thread 0x7fff05e83700 (LWP 92831) exited] Debug [Main]: Committing transaction on "MIXXX-1" result: true Debug [Main]: PlaylistDAO::getHiddenType returns PLHT_UNKNOWN for playlistId 44 Debug [Main]: Dropping Rekordbox table: "rekordbox_playlist_tracks" Debug [Main]: Dropping Rekordbox table: "rekordbox_playlists" Debug [Main]: Dropping Rekordbox table: "rekordbox_library" Debug [Main]: Committing transaction on "MIXXX-1" result: true Debug [Main]: Dropping Serato table: "serato_playlist_tracks" Debug [Main]: Dropping Serato table: "serato_playlists" Debug [Main]: Dropping Serato table: "serato_library" Debug [Main]: Committing transaction on "MIXXX-1" result: true Debug [Main]: 512 ms deleting RecordingManager Debug [Main]: Delete RecordingManager Debug [Main]: 512 ms deleting BroadcastManager Debug [Main]: DlgPrefBroadcast - broadcastEnabledChanged() 0 Debug [Main]: 512 ms deleting EngineMaster [Thread 0x7fffc8ce1700 (LWP 92807) exited] [Thread 0x7fffc9d63700 (LWP 92806) exited] [Thread 0x7fffbccbf700 (LWP 92821) exited] [Thread 0x7fff2788a700 (LWP 92822) exited] [Thread 0x7fff26460700 (LWP 92823) exited] [Thread 0x7fff25036700 (LWP 92824) exited] [Thread 0x7fff17afe700 (LWP 92825) exited] [Thread 0x7fff16aeb700 (LWP 92826) exited] [Thread 0x7fff15a3b700 (LWP 92827) exited] [Thread 0x7fff1498b700 (LWP 92828) exited] [Thread 0x7fff0788a700 (LWP 92829) exited] [Thread 0x7ffed7fff700 (LWP 92840) exited] [Thread 0x7ffed77fe700 (LWP 92841) exited] [Thread 0x7ffed6ffd700 (LWP 92842) exited] [Thread 0x7ffed67fc700 (LWP 92843) exited] [Thread 0x7ffed5ffb700 (LWP 92844) exited] [Thread 0x7ffed57fa700 (LWP 92845) exited] [Thread 0x7ffed4ff9700 (LWP 92846) exited] [Thread 0x7ffeb3fff700 (LWP 92848) exited] [Thread 0x7ffeb37fe700 (LWP 92849) exited] [Thread 0x7ffeb2ffd700 (LWP 92850) exited] [Thread 0x7ffeb27fc700 (LWP 92851) exited] [Thread 0x7ffeb1ffb700 (LWP 92852) exited] Debug [Main]: 553 ms deleting DlgPreferences Debug [Main]: 567 ms deleting EffectsManager [Thread 0x7ffef1ffb700 (LWP 92838) exited] Debug [Main]: 682 ms detaching all track collections Info [Main]: TrackCollectionManager - Stopping library scanner thread Debug [LibraryScanner 1]: LibraryScanner - Event loop stopped Debug [LibraryScanner 1]: DbConnection - Closing database connection: "MIXXX-2" QSqlDatabase(driver="QSQLITE", database="file:///home/ronso/.mixxx_dev/mixxxdb.sqlite", host="", port=-1, user="mixxx", open=true) Warning [LibraryScanner 1]: QSqlDatabasePrivate::removeDatabase: connection 'MIXXX-2' is still in use, all queries will cease to work. Debug [LibraryScanner 1]: LibraryScanner - Exiting thread Info [Main]: TrackCollectionManager - Stopped library scanner thread Debug [Main]: ~TrackDAO() Info [Main]: TrackCollection - Disconnecting track source [Thread 0x7fff06684700 (LWP 92830) exited] Info [Main]: TrackCollection - Disconnecting database Debug [Main]: TrackDAO::finish() Debug [Main]: Clearing played information for this session Debug [Main]: Cleaning LibraryHashes/track_locations tables. Debug [Main]: SqlTransaction - Started new SQL database transaction on "MIXXX-1" Debug [Main]: SqlTransaction - Committed SQL database transaction on "MIXXX-1" Info [Main]: GlobalTrackCache - Destroying instanceThread 1 "mixxx" received signal SIGSEGV, Segmentation fault. Thread 106 (Thread 0x7ffe27fe7700 (LWP 92908)): Thread 105 (Thread 0x7ffe287e8700 (LWP 92907)): Thread 10 (Thread 0x7fffcac98700 (LWP 92801)): Thread 9 (Thread 0x7fffcbfff700 (LWP 92800)): Thread 8 (Thread 0x7fffda7fc700 (LWP 92799)): Thread 7 (Thread 0x7fffdaffd700 (LWP 92798)): Thread 5 (Thread 0x7fffdbfff700 (LWP 92796)): Thread 4 (Thread 0x7fffe8e6d700 (LWP 92795)): Thread 3 (Thread 0x7fffe966e700 (LWP 92794)): Thread 2 (Thread 0x7fffea9b1700 (LWP 92793)): Thread 1 (Thread 0x7fffeb653140 (LWP 92786)): Thread 106 (Thread 0x7ffe27fe7700 (LWP 92908)): Thread 105 (Thread 0x7ffe287e8700 (LWP 92907)): Thread 10 (Thread 0x7fffcac98700 (LWP 92801)): Thread 9 (Thread 0x7fffcbfff700 (LWP 92800)): Thread 8 (Thread 0x7fffda7fc700 (LWP 92799)): Thread 7 (Thread 0x7fffdaffd700 (LWP 92798)): Thread 5 (Thread 0x7fffdbfff700 (LWP 92796)): Thread 4 (Thread 0x7fffe8e6d700 (LWP 92795)): Thread 3 (Thread 0x7fffe966e700 (LWP 92794)): Thread 2 (Thread 0x7fffea9b1700 (LWP 92793)): Thread 1 (Thread 0x7fffeb653140 (LWP 92786)): Thread 106 (Thread 0x7ffe27fe7700 (LWP 92908)): Thread 105 (Thread 0x7ffe287e8700 (LWP 92907)): Thread 10 (Thread 0x7fffcac98700 (LWP 92801)): Thread 9 (Thread 0x7fffcbfff700 (LWP 92800)): Thread 8 (Thread 0x7fffda7fc700 (LWP 92799)): Thread 7 (Thread 0x7fffdaffd700 (LWP 92798)): Thread 5 (Thread 0x7fffdbfff700 (LWP 92796)): Thread 4 (Thread 0x7fffe8e6d700 (LWP 92795)): Thread 3 (Thread 0x7fffe966e700 (LWP 92794)): Thread 2 (Thread 0x7fffea9b1700 (LWP 92793)): Thread 1 (Thread 0x7fffeb653140 (LWP 92786)):
|
Btw I don't see the translucent level artifacts anymore. |
Shade is fixed with b3559f8 |
Qt 5.12.8 btw |
only draw peak when actually visible and not overlapped by signal level Co-authored-by: ronso0 <[email protected]>
Tested on Windows, the build generated by github actions. ( https://github.com/mixxxdj/mixxx/actions/runs/3151963589 ) It works and the CPU usage seems to be the same than previously (compared with task manager both CPU and GPU) |
Gràcies, @JosepMaJAZ ! I'd say this confirms that we can safely make it the default. I'll make the change. |
Unfortunately there must have been happen a wrong rebase/merge. See: I have rebated your branch again to get rid of the duplicated commits and added my commit that makes the workaround conditionally. I suggest to merge m0dB#3 and after that reset you branch to b8dff32 and force push. I have decided to not limit the fix tho <= 5.15.3, because it is unlikely that the issue will be fixed in future versions. |
@daschuer just to make sure, is this expected?
Should I add and commit those before I force push? |
Yes, this is a left over from the 2.3 branch. Since we merge to main they can be removed. |
8a15a63
to
b8dff32
Compare
done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect! Thank you.
Thank you very much @ronso0 ! Did your changes fix all issues you were seeing ? If not, let me know and I will have a look. On a side note, I have another branch in the works that uses QOpenGL classes, also for the VU meters. It would be great if you can have a look at that as well. No hurry, it's still work in progress (e.g. things like switching skins or clean shutdown is not something I am worrying about yet). It runs pretty smooth on macOS (occasional dropped frames at 60 fps, no UI lag) but I haven't tried on linux. (It could very well be that linux requires setting up the QSurface in a particular way, or that a QOpenGLWidget implementation is better than my QOpenGLWindow based widget, which is something I want to try too). In any case, I have made an effort to make it coexist (currently with a compile time option) with the QGLWidget code. I have experimented with a way to make it perfectly smooth (no dropped frames at all), by rendering directly from the vsyncthread, but I first want to finish the rest. If you (or anyone) want to give it a try: |
#10978 I'd appreciate if you could take a look at the other issues. |
Ok, I see! Yes, on macOS I have the same yellow CPU meter, I thought this was because the skin changed 😅 . I'll fix it ASAP. |
@ronso0 Luckily it was just a very stupid mistake:
I'll create a PR in a moment. |
In our forum, a 2.3.4 regression is reported, with a custom skin, which uses horizontal VU-Meters: https://mixxx.discourse.group/t/2-3-4-causes-black-squares-on-level-meter-traktmixxx-skin/26808/ |
I will try to look into this in the weekend. |
I ran into several segfaults while trying to debug https://mixxx.discourse.group/t/2-3-4-causes-black-squares-on-level-meter-traktmixxx-skin/26808/, see #11360 I'm afraid I'm not of much help figuring out the root cause... |
Under load, the WVuMeter paint events, triggered constantly by the WaveformWidgetFactory, would cause the Qt event queue to become extremely laggy (up to more than a second before a mouse or keyboard event was handled). I changed WVuMeter to be a QGlWidget, just like WSpinny, and also called its render & swap in the same way. This solves the responsiveness issues I was seeing on MacOS.
(Note that there is room for additional improvements. Instead of using QPainter to draw the PixMaps, it is likely faster to use QGLWidget's texture rendering. Also I would like the clip light to be part of the vumeter.)