Last Nvidia drivers (372.70) and Blender (2.77a) turn off Windows Aero #49215

Closed
opened 2016-08-31 21:00:48 +02:00 by David · 12 comments

System Information
Windows 7 Ult x64
780GTX Drivers 720.70

Blender Version
Broken: 2.77a with drivers 372.70 or 372.54 (Not tested with this one, but I read somewhere is broken too)
Worked: I used an older version but I read this work until 368.81 without problems

Short description of error
At open Blender with the last Nvidia drivers (372.70 ), Blender (2.77a) turn the Windows 7 Aero off.

Exact steps for others to reproduce the error
Install the last Nvidia drivers 372.70 restart or no then open Blender 2.77a, then the whole desktop turn Aero off.

**System Information** Windows 7 Ult x64 780GTX Drivers 720.70 **Blender Version** Broken: 2.77a with drivers 372.70 or 372.54 (Not tested with this one, but I read somewhere is broken too) Worked: I used an older version but I read this work until 368.81 without problems **Short description of error** At open Blender with the last Nvidia drivers (372.70 ), Blender (2.77a) turn the Windows 7 Aero off. **Exact steps for others to reproduce the error** Install the last Nvidia drivers 372.70 restart or no then open Blender 2.77a, then the whole desktop turn Aero off.
Author

Changed status to: 'Open'

Changed status to: 'Open'
Author

Added subscriber: @Hgdavidy

Added subscriber: @Hgdavidy
Member

Added subscribers: @MikeErwin, @Sergey, @MartijnBerger, @LazyDodo

Added subscribers: @MikeErwin, @Sergey, @MartijnBerger, @LazyDodo
Member

Nvidia added a pixel format with 64 bit color in it (supports 64 bit color, but doesn't support PFD_SUPPORT_COMPOSITION) giving this format a huge advantage in weight_pixel_format. (and disables aero in the process)

This does the trick for me, Mike? Thoughts?

 intern/ghost/intern/GHOST_ContextWGL.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/intern/ghost/intern/GHOST_ContextWGL.cpp b/intern/ghost/intern/GHOST_ContextWGL.cpp
index abce3ea..e27065e 100644
--- a/intern/ghost/intern/GHOST_ContextWGL.cpp
+++ b/intern/ghost/intern/GHOST_ContextWGL.cpp
@@ -194,7 +194,7 @@ static int weight_pixel_format(PIXELFORMATDESCRIPTOR &pfd, PIXELFORMATDESCRIPTOR
 	/* give no weight to a 16-bit depth buffer, because those are crap */
 	weight += pfd.cDepthBits - 16;
 
-	weight += pfd.cColorBits -  8;
+	weight += min(pfd.cColorBits,33) -  8; // clip > 32 bit formats, so they don't get too much of an advantage
 
 	if (preferredPFD.cAlphaBits > 0 && pfd.cAlphaBits > 0)
 		weight++;

Also we don't really rate on PFD_SUPPORT_COMPOSITION unless WIN32_COMPOSITING is defined (which it is not) seems wonky as well.... given vista is now our lowest platform we should be able to enable this?

Nvidia added a pixel format with 64 bit color in it (supports 64 bit color, but doesn't support PFD_SUPPORT_COMPOSITION) giving this format a huge advantage in weight_pixel_format. (and disables aero in the process) This does the trick for me, Mike? Thoughts? ``` intern/ghost/intern/GHOST_ContextWGL.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/intern/ghost/intern/GHOST_ContextWGL.cpp b/intern/ghost/intern/GHOST_ContextWGL.cpp index abce3ea..e27065e 100644 --- a/intern/ghost/intern/GHOST_ContextWGL.cpp +++ b/intern/ghost/intern/GHOST_ContextWGL.cpp @@ -194,7 +194,7 @@ static int weight_pixel_format(PIXELFORMATDESCRIPTOR &pfd, PIXELFORMATDESCRIPTOR /* give no weight to a 16-bit depth buffer, because those are crap */ weight += pfd.cDepthBits - 16; - weight += pfd.cColorBits - 8; + weight += min(pfd.cColorBits,33) - 8; // clip > 32 bit formats, so they don't get too much of an advantage if (preferredPFD.cAlphaBits > 0 && pfd.cAlphaBits > 0) weight++; ``` Also we don't really rate on PFD_SUPPORT_COMPOSITION unless WIN32_COMPOSITING is defined (which it is not) seems wonky as well.... given vista is now our lowest platform we should be able to enable this?
Member

I need to freshen up knowledge of Windows pixel format options, but as a quick fix this looks fine. Minor change: why not this?

min(pfd.cColorBits, 32) - 8

Good & thorough article on "OpenGL and Windows Vista"
https://www.opengl.org/pipeline/article/vol003_7/

^-- based on this I'm not 100% sure we're doing everything necessary for PFD_SUPPORT_COMPOSITION (but we might be). Apply the above fix for 2.78 & we can do PFD_SUPPORT_COMPOSITION properly after.

Lots of magic going on in this pixel format weighting scheme.. I bet we can come up with something simpler for 2.8 or later.

TODO: Support deep display output for people with high-end monitors (10 bits per channel). Opt-in via System user prefs, not automatic.

I need to freshen up knowledge of Windows pixel format options, but as a quick fix this looks fine. Minor change: why not this? min(pfd.cColorBits, **32**) - 8 Good & thorough article on "OpenGL and Windows Vista" https://www.opengl.org/pipeline/article/vol003_7/ ^-- based on this I'm not 100% sure we're doing everything necessary for PFD_SUPPORT_COMPOSITION (but we might be). Apply the above fix for 2.78 & we can do PFD_SUPPORT_COMPOSITION properly after. Lots of magic going on in this pixel format weighting scheme.. I bet we can come up with something simpler for 2.8 or later. TODO: Support deep display output for people with high-end monitors (10 bits per channel). Opt-in via System user prefs, not automatic.
Member

In #49215#389111, @MikeErwin wrote:
I need to freshen up knowledge of Windows pixel format options, but as a quick fix this looks fine. Minor change: why not this?

min(pfd.cColorBits, 32) - 8

Cause i figured, higher color depth, sure, have a +1 on 32 bit color, but not +32, I'm not overly dedicated to this though, awarding no points would be fine with me as well. We could also just flat out reject the 64 bit color profiles, return 0 and be done with it?

Good & thorough article on "OpenGL and Windows Vista"
https://www.opengl.org/pipeline/article/vol003_7/

Yeah i read that yesterday while figuring out why it disabled aero :)

^-- based on this I'm not 100% sure we're doing everything necessary for PFD_SUPPORT_COMPOSITION (but we might be). Apply the above fix for 2.78 & we can do PFD_SUPPORT_COMPOSITION properly after.

I think we're pretty close to doing everything it says , but it's all disabled with that WIN32_COMPOSITING define not being there.
I almost suggested to just turn it on, but then i bumped into some dwm drawing code who's purpose isn't entirely clear to me. (enabled it, didn't seem to do anything)

Lots of magic going on in this pixel format weighting scheme.. I bet we can come up with something simpler for 2.8 or later.

I say make a quick hack for 2.78 by using the patch above (with either 32 or 33, meh, don't care) and see how we can do this better for 2.8?

TODO: Support deep display output for people with high-end monitors (10 bits per channel). Opt-in via System user prefs, not automatic.

> In #49215#389111, @MikeErwin wrote: > I need to freshen up knowledge of Windows pixel format options, but as a quick fix this looks fine. Minor change: why not this? > > min(pfd.cColorBits, **32**) - 8 Cause i figured, higher color depth, sure, have a +1 on 32 bit color, but not +32, I'm not overly dedicated to this though, awarding no points would be fine with me as well. We could also just flat out reject the 64 bit color profiles, return 0 and be done with it? > Good & thorough article on "OpenGL and Windows Vista" > https://www.opengl.org/pipeline/article/vol003_7/ Yeah i read that yesterday while figuring out why it disabled aero :) > ^-- based on this I'm not 100% sure we're doing everything necessary for PFD_SUPPORT_COMPOSITION (but we might be). Apply the above fix for 2.78 & we can do PFD_SUPPORT_COMPOSITION properly after. I think we're pretty close to doing everything it says , but it's all disabled with that WIN32_COMPOSITING define not being there. I almost suggested to just turn it on, but then i bumped into some dwm drawing code who's purpose isn't entirely clear to me. (enabled it, didn't seem to do anything) > Lots of magic going on in this pixel format weighting scheme.. I bet we can come up with something simpler for 2.8 or later. I say make a quick hack for 2.78 by using the patch above (with either 32 or 33, meh, don't care) and see how we can do this better for 2.8? > TODO: Support deep display output for people with high-end monitors (10 bits per channel). Opt-in via System user prefs, not automatic.
Member

I say make a quick hack for 2.78 by using the patch above (with either 32 or 33, meh, don't care) and see how we can do this better for 2.8?

I think any bit depth > 32 will disable Aero.

> I say make a quick hack for 2.78 by using the patch above (with either 32 or 33, meh, don't care) and see how we can do this better for 2.8? I *think* any bit depth > 32 will disable Aero.
Member

You're probably right, how about this is a less risky solution ?

 intern/ghost/intern/GHOST_ContextWGL.cpp | 1 +
 1 file changed, 1 insertion(+)

diff --git a/intern/ghost/intern/GHOST_ContextWGL.cpp b/intern/ghost/intern/GHOST_ContextWGL.cpp
index abce3ea..64ee692 100644
--- a/intern/ghost/intern/GHOST_ContextWGL.cpp
+++ b/intern/ghost/intern/GHOST_ContextWGL.cpp
@@ -183,6 +183,7 @@ static int weight_pixel_format(PIXELFORMATDESCRIPTOR &pfd, PIXELFORMATDESCRIPTOR
 	    !(pfd.dwFlags & PFD_DOUBLEBUFFER)    || /* Blender _needs_ this */
 	    !(pfd.iPixelType == PFD_TYPE_RGBA)   ||
 	     (pfd.cDepthBits < 16)               ||
+	     (pfd.cColorBits > 32)               || /* 64 bit formats disable aero */
 	     (pfd.dwFlags & PFD_GENERIC_FORMAT))    /* no software renderers */
 	{
 		return 0;

You're probably right, how about this is a less risky solution ? ``` intern/ghost/intern/GHOST_ContextWGL.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/intern/ghost/intern/GHOST_ContextWGL.cpp b/intern/ghost/intern/GHOST_ContextWGL.cpp index abce3ea..64ee692 100644 --- a/intern/ghost/intern/GHOST_ContextWGL.cpp +++ b/intern/ghost/intern/GHOST_ContextWGL.cpp @@ -183,6 +183,7 @@ static int weight_pixel_format(PIXELFORMATDESCRIPTOR &pfd, PIXELFORMATDESCRIPTOR !(pfd.dwFlags & PFD_DOUBLEBUFFER) || /* Blender _needs_ this */ !(pfd.iPixelType == PFD_TYPE_RGBA) || (pfd.cDepthBits < 16) || + (pfd.cColorBits > 32) || /* 64 bit formats disable aero */ (pfd.dwFlags & PFD_GENERIC_FORMAT)) /* no software renderers */ { return 0; ```
Member

Yeah, that's better actually -- we don't want 64-bit format tying with a 32-bit one based on score. Better to reject them for now.

Commit!

Yeah, that's better actually -- we don't want 64-bit format tying with a 32-bit one based on score. Better to reject them for now. Commit!

This issue was referenced by f0159d1d48

This issue was referenced by f0159d1d48a141483f61b1ccc262f99016b63570
Member

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Author

This comment was removed by @Hgdavidy

*This comment was removed by @Hgdavidy*
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#49215
No description provided.