Commit Graph

90 Commits

Author SHA1 Message Date
Terry MacDonald
842854e957 Merged from feature-update-libraries 2022-03-24 22:41:16 +13:00
Terry MacDonald
67c1015730 Updated the NVIDIALibrary and WinLibrary to v1.7.0
This is the version used within NVIDIAInfo v1.7.0
2022-03-24 22:36:42 +13:00
Terry MacDonald
87f62aa322 Made display changes reliable 2022-02-12 09:18:03 +13:00
Terry MacDonald
81b565dfa6 Fixed taskbar move in profiletools 2022-02-05 21:28:51 +13:00
Terry MacDonald
c45e66275a [WIP] Removing manual setting of taskbar location in DM
The idea should be to make the changes directly to windows, and DisplayMagician will set things up the same as it recorded you'd set.
2022-02-03 09:20:06 +13:00
Terry MacDonald
f6e5dbc0b7 [WIP] Refactor for taskbar code
Partially through a different refactor to completely change how the taskbar settigns are stored, and the logic behind the application. Should make the taskbar more robust to apply.
2022-02-01 22:04:08 +13:00
Terry MacDonald
cd25f9a0fa [WIP] Partially working taskbar moving 2022-01-30 20:24:36 +13:00
Terry MacDonald
362088b5e3 Added checks to pause updating displayconfig while display change occurring
Added some checks to temporarily pause any 'getconfig' type activities while we're changing the displayconfig. This should result in less config corruption, and fewer errors when there are timing edge cases.
2022-01-29 15:25:52 +13:00
Terry MacDonald
90149e1d9d Merged develop into feature-taskbar-setting branch 2022-01-25 09:30:23 +13:00
Terry MacDonald
918e3cda04 Initial working TaskBar position changes
Note - doesn't work n Windows 11.
2022-01-23 10:33:14 +13:00
Terry MacDonald
f860b91a72 Enforced update to file format v2.2 2022-01-21 20:37:56 +13:00
Terry MacDonald
f5a8a05e63 Removed unused settings 2022-01-21 18:34:31 +13:00
Terry MacDonald
195820bea6 Make load profile function handle later versions of config file
This change makes the ProfileRepository handle loading json config files from later versions of DM without causing an exception. This will mean that you can install later model config files and still have them work ok.
2022-01-21 18:09:04 +13:00
Terry MacDonald
d24b15d37a [WIP] Threading improvements
Found that I was combining Threads and Tasks together...never a good idea. Have moved fully over to a Task based model. Now still having issues with parallelism.
2022-01-10 21:06:02 +13:00
Terry MacDonald
ddd48b577d Changed notification icon handling
Made the code more robust and able to work using the new threaded instances
2022-01-06 09:05:55 +13:00
Terry MacDonald
f72fc6feea Attempted to reduce the number of video card library calls
Found some calls that were bypassing the video library state buffering I'd put in place earlier. This should generally make DisplayMagician faster and minimise the number of log entries written to DisplayMagician.log.
2021-10-31 12:50:57 +13:00
Terry MacDonald
5743cd377b Fixed bug in ApplyingProfile caused by new profile buffering
As I'd changed the profile config to buffer it within the libraries themselves, ApplyProfile wasn't telling the libraries to update their config. Therefore they thought they were still on the original display config, and that meant that ApplyProfile didn't revert the profile after the application had closed. This is now fixed.
2021-10-26 21:19:48 +13:00
Terry MacDonald
6e35825b10 Update ProfileRepository 2021-10-24 21:39:49 +13:00
Terry MacDonald
419969ad5f Changed profile detection
Changed Profiles to use new methods for profiles detection provided by the new video card library updates for NVIDIALibrary, AMDLibrary and WinLibrary. This should make DisplayMagician faster as there is less repetition.
2021-10-24 21:29:53 +13:00
Terry MacDonald
707c43375d Changed DisplayProfile file location to DisplayProfiles_2.1.json
There have been such large changes with v2.1.0 that I've had to move to a new file display profile format again :(. I'm really hopeful this will be the last time, as it seems to cope with all the different display layouts, colour settings, hdr etc.
2021-10-23 15:30:20 +13:00
Terry MacDonald
cf1ff873ef Added patch to convert v2.0.1 displaySource to list
This should help avoid a crash to desktop when using cloned displays. Partially fixes #47
2021-10-16 16:45:49 +13:00
Terry MacDonald
d98372bf39 Patch Profiles that are missing GDI settings
This will ensure that existing display profiles will at least load. Anyone with refresh settings changes or BPC or other device context settings will need to recreate their display profiles.
2021-10-16 09:37:52 +13:00
Terry MacDonald
c5b06988dd Fixed broken apply profile logic
Changed an AND to a NAND and now it works.
2021-10-09 18:42:50 +13:00
Terry MacDonald
b6de9aa85f Partial fix for OriginLibrary v3.x
Note - doesn't work with Origin v2.1 files yet... still troubleshooting those!
2021-10-04 22:40:32 +13:00
Terry MacDonald
8bd3d07fa4 Fixed some UI status messages 2021-10-02 16:22:36 +13:00
Terry MacDonald
8b73a51fe3 Added additional checks to library mode matching 2021-09-22 20:37:10 +12:00
Terry MacDonald
c820c9bac4 Fixed incorrect return value from ApplyProfile
Fixes #41. Silly error from previous return value.
2021-09-22 08:22:57 +12:00
Terry MacDonald
21b121199b Fixed ProfileDisplayIdentifier double up
Now ProfileItem loads properly from JSON file, which means that the profile matching works, so DisplayMagician now matches the profile if it's current.
2021-09-19 21:00:47 +12:00
Terry MacDonald
cd71725617 [WIP] Fixed error loading JSON after save
There was a problem with the unused display config containing null values on save, which meant that the JSON would be invalid when loaded in the next time. The fix was to ensure that both NVIDIA and AMD both were filled with a default config when a new profiles was created. This means that the real config would overwrite whichever config was needed, and the JSON file would work as all objects were populated correctly!
2021-09-19 20:56:58 +12:00
Terry MacDonald
fef3dbf1e0 Part 2 of the move to a single ProfileItem
Mostly works now! Only bit still needing work is the Avtive profile detection to detect the non-surround profile when we return from surround. I think it's to do with the windows display number changing :(. I need to check that.
2021-09-07 22:08:54 +12:00
Terry MacDonald
f8e9eecf81 Removed derived ProfileItem classes
The derived ProfilteItem classes were an unnecessary distraction and wasted time I could be spending on other things. This set of changes are the first part of removing those derived classes and moving to a single ProfilItem class again, but with different configuration slots within it. Makes equality comparison SO MUCH EASIER!
2021-09-07 21:26:42 +12:00
Terry MacDonald
c59f236524 Still vainly trying to get Equals to work
I am a lot closer at the moment, but there is some bit of logic matching that is escaping me. I think I'm just too tired at the moment, and I need a sleep. I bet this will seem simple in the morning.
2021-09-06 22:08:22 +12:00
Terry MacDonald
708acd3c12 Fixed CompareTo and some Profile Repository loading order 2021-09-04 20:58:08 +12:00
Terry MacDonald
a112326e50 Implemented new derived class equality logic
Used new derived class equality class from https://codinghelmet.com/articles/equals-override which helped me understand the logic for deriving equality between base classes and derived classes. It has now exposed another error in the way FORCED_VIDEO_MODE is being applied and that is now something else I need to fix!
2021-09-04 16:32:42 +12:00
Terry MacDonald
65bbd1ab66 Added --force-video-library command line option
This feature will allow users to bypass the automatic driver detection functionality so that they can at least force  the use of the built-in Windows driver if NVIDIA or AMD ever have an issue with their drivers.
2021-09-02 13:47:28 +12:00
Terry MacDonald
9cef45416e First working display background per profile
Added functionality to implement display wallpaper changes with each display profile as per #36 and #10. Tested in Windows 10 ok.
2021-09-02 10:42:26 +12:00
Terry MacDonald
4c8ecc0bf6 Initial completed develop branch merge
Code now compiles, so now it is just some testing to see what is broken!
2021-08-30 12:51:44 +12:00
Terry MacDonald
b374850bfe Merged develop branch to simplify development 2021-08-30 12:35:52 +12:00
Terry MacDonald
cf0a15acdd Add initial wallpaper changing code 2021-08-27 21:15:53 +12:00
Terry MacDonald
012fe76b34 [WIP] Researching broken NVIDIA profile matching 2021-08-27 20:57:02 +12:00
Terry MacDonald
293ca14730 Moved RunProfile to ProfileRepository
It makes WAY more sense here.
2021-08-27 17:53:32 +12:00
Terry MacDonald
ad732d388f Added missing NVAPI Equals tests 2021-08-25 21:45:40 +12:00
Terry MacDonald
90c13c7426 Working profile comparisons 2021-08-24 20:37:32 +12:00
Terry MacDonald
508f3751b9 Fixed AMDProfileItem and WindProfileItem
DisplayMagician starts, but displayprofile form doesn't work at all.
2021-08-22 18:58:08 +12:00
Terry MacDonald
bd89993770 Removed WindowsDisplayAPI
No longer need WindowsDisplayAPI as I've build a Windows CCD library as part of DisplayMagician itself now.
2021-08-22 15:51:13 +12:00
Terry MacDonald
40b8525dd8 [WIP] Added video card detection
Added ability for ProfileRepository to know what mode it is in when DisplayMagician starts.
2021-08-22 15:42:12 +12:00
Terry MacDonald
7753e26917 Commented code tidy up 2021-08-21 22:14:25 +12:00
Terry MacDonald
a4662bed6c Removed prior graphics libraries to enable new lib integration.
Tweaked some easy to fix integration errors.
2021-08-21 22:09:41 +12:00
Terry MacDonald
224b666bba [WIP] Added NVIDIA in using similar structure as AMD
Still a LOT of integration work still left to do, and of course some work to
use the new libraries as part of the getting and setting the config.
2021-08-21 22:01:23 +12:00
Terry MacDonald
0123e061e0 [WIP] initial library integration into DM
Have almost integrated the new CCD, AMD and NVIDIA
libraries into DIsplayMagician. The CCD library is working
fine. The AMD library is partially completed, but is awaiting
some help from AMD, as it appears one of their driver functions
is broken (or at least incorrectly documented). The NVIDIA
library is currently still under development, but I've still copied
it across so that I could work on the additional profile objects
that need to be prepared in order for this to work.

As I am waiting on a response from AMD, the plan is now that
I will swap over to an NVIDIA based video card in my test machines
and I will start work on the NVIDIA library. The NVIDIA library seems
straight forward compared to AMD, so that hopefully won't take too
long to do. Once that library is compete, I'll test it within NVIDIAInfo
application until its working, and then I'll port it back over to
DisplayMagician. That will then let me complete the last bits of the
integration so that I can complete the last of the NVIDIA tests.
Hopefully by the time all this happens I will have heard back from
AMD and I will be able to continue work with that section of code.
2021-07-24 16:05:38 +12:00