Bug 1002857 - stop disabling GL layers for 10.6.2 and below. r=mstange
authorBenoit Girard <b56girard@gmail.com>
Wed, 18 May 2016 18:10:04 -0400
changeset 298283 ca3135fa04fc4df03bf91b1a88216729d16c9944
parent 298282 6471cf751c2dc966c1c6fa171f78fcd1fed6d711
child 298284 169369e8ef8a9fb5eab92a9f94161f3d9d0ac128
push id30281
push usercbook@mozilla.com
push dateTue, 24 May 2016 12:54:02 +0000
treeherdermozilla-central@829d3be6ba64 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmstange
bugs1002857
milestone49.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1002857 - stop disabling GL layers for 10.6.2 and below. r=mstange MozReview-Commit-ID: ITqcQNdolQ
gfx/thebes/gfxPlatformMac.cpp
widget/cocoa/nsCocoaFeatures.h
widget/cocoa/nsCocoaFeatures.mm
--- a/gfx/thebes/gfxPlatformMac.cpp
+++ b/gfx/thebes/gfxPlatformMac.cpp
@@ -376,22 +376,17 @@ gfxPlatformMac::UseProgressivePaint()
   // Progressive painting requires cross-process mutexes, which don't work so
   // well on OS X 10.6 so we disable there.
   return nsCocoaFeatures::OnLionOrLater() && gfxPlatform::UseProgressivePaint();
 }
 
 bool
 gfxPlatformMac::AccelerateLayersByDefault()
 {
-  // 10.6.2 and lower have a bug involving textures and pixel buffer objects
-  // that caused bug 629016, so we don't allow OpenGL-accelerated layers on
-  // those versions of the OS.
-  // This will still let full-screen video be accelerated on OpenGL, because
-  // that XUL widget opts in to acceleration, but that's probably OK.
-  return nsCocoaFeatures::AccelerateByDefault();
+  return true;
 }
 
 // This is the renderer output callback function, called on the vsync thread
 static CVReturn VsyncCallback(CVDisplayLinkRef aDisplayLink,
                               const CVTimeStamp* aNow,
                               const CVTimeStamp* aOutputTime,
                               CVOptionFlags aFlagsIn,
                               CVOptionFlags* aFlagsOut,
--- a/widget/cocoa/nsCocoaFeatures.h
+++ b/widget/cocoa/nsCocoaFeatures.h
@@ -18,17 +18,16 @@ public:
   static int32_t OSXVersionMajor();
   static int32_t OSXVersionMinor();
   static int32_t OSXVersionBugFix();
   static bool OnLionOrLater();
   static bool OnMountainLionOrLater();
   static bool OnMavericksOrLater();
   static bool OnYosemiteOrLater();
   static bool OnElCapitanOrLater();
-  static bool AccelerateByDefault();
 
   static bool IsAtLeastVersion(int32_t aMajor, int32_t aMinor, int32_t aBugFix=0);
 
   // These are utilities that do not change or depend on the value of mOSXVersion
   // and instead just encapsulate the encoding algorithm.  Note that GetVersion
   // actually adjusts to the lowest supported OS, so it will always return
   // a "supported" version.  GetSystemVersion does not make any modifications.
   static void GetSystemVersion(int &aMajor, int &aMinor, int &aBugFix);
--- a/widget/cocoa/nsCocoaFeatures.mm
+++ b/widget/cocoa/nsCocoaFeatures.mm
@@ -175,18 +175,12 @@ nsCocoaFeatures::OnYosemiteOrLater()
 
 /* static */ bool
 nsCocoaFeatures::OnElCapitanOrLater()
 {
     return (OSXVersion() >= MAC_OS_X_VERSION_10_11_HEX);
 }
 
 /* static */ bool
-nsCocoaFeatures::AccelerateByDefault()
-{
-    return IsAtLeastVersion(10, 6, 3);
-}
-
-/* static */ bool
 nsCocoaFeatures::IsAtLeastVersion(int32_t aMajor, int32_t aMinor, int32_t aBugFix)
 {
     return OSXVersion() >= GetVersion(aMajor, aMinor, aBugFix);
 }