ericrk | 41a1579e | 2017-02-10 20:56:28 | [diff] [blame] | 1 | // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | #include "gpu/config/gpu_finch_features.h" |
| 5 | |
ericrk | 41a1579e | 2017-02-10 20:56:28 | [diff] [blame] | 6 | namespace features { |
| 7 | |
| 8 | // Enable GPU Rasterization by default. This can still be overridden by |
| 9 | // --force-gpu-rasterization or --disable-gpu-rasterization. |
Eric Karl | ba990bf | 2018-01-03 00:19:35 | [diff] [blame] | 10 | #if defined(OS_MACOSX) || defined(OS_WIN) || defined(OS_CHROMEOS) || \ |
| 11 | defined(OS_ANDROID) |
| 12 | // DefaultEnableGpuRasterization has launched on Mac, Windows, ChromeOS, and |
| 13 | // Android. |
ericrk | 41a1579e | 2017-02-10 20:56:28 | [diff] [blame] | 14 | const base::Feature kDefaultEnableGpuRasterization{ |
| 15 | "DefaultEnableGpuRasterization", base::FEATURE_ENABLED_BY_DEFAULT}; |
| 16 | #else |
| 17 | const base::Feature kDefaultEnableGpuRasterization{ |
| 18 | "DefaultEnableGpuRasterization", base::FEATURE_DISABLED_BY_DEFAULT}; |
| 19 | #endif |
| 20 | |
Adrienne Walker | c87477e | 2018-06-06 22:28:21 | [diff] [blame] | 21 | // Enable out of process rasterization by default. This can still be overridden |
| 22 | // by --enable-oop-rasterization or --disable-oop-rasterization. |
| 23 | const base::Feature kDefaultEnableOopRasterization{ |
| 24 | "DefaultEnableOopRasterization", base::FEATURE_DISABLED_BY_DEFAULT}; |
| 25 | |
Geoff Lang | 94cb946 | 2017-10-25 21:54:02 | [diff] [blame] | 26 | // Use the passthrough command decoder by default. This can be overridden with |
| 27 | // the --use-cmd-decoder=passthrough or --use-cmd-decoder=validating flags. |
| 28 | const base::Feature kDefaultPassthroughCommandDecoder{ |
Sunny Sachanandani | 9456e9b | 2018-09-08 02:30:53 | [diff] [blame^] | 29 | "DefaultPassthroughCommandDecoder", base::FEATURE_DISABLED_BY_DEFAULT}; |
Geoff Lang | 94cb946 | 2017-10-25 21:54:02 | [diff] [blame] | 30 | |
Sunny Sachanandani | 1b64d7a | 2018-05-18 02:08:06 | [diff] [blame] | 31 | // Use DirectComposition layers (overlays) for video if supported. Overridden by |
| 32 | // --enable-direct-composition-layers and --disable-direct-composition-layers. |
| 33 | const base::Feature kDirectCompositionOverlays{ |
| 34 | "DirectCompositionOverlays", base::FEATURE_ENABLED_BY_DEFAULT}; |
| 35 | |
Vikas Soni | 882982e1 | 2018-08-05 19:50:58 | [diff] [blame] | 36 | #if defined(OS_ANDROID) |
| 37 | // Use android AImageReader when playing videos with MediaPlayer. |
| 38 | const base::Feature kAImageReaderMediaPlayer{"AImageReaderMediaPlayer", |
| 39 | base::FEATURE_DISABLED_BY_DEFAULT}; |
| 40 | #endif |
| 41 | |
Sunny Sachanandani | 729164b | 2018-08-10 00:45:14 | [diff] [blame] | 42 | // Overrides preferred overlay format to NV12 instead of YUY2. |
| 43 | const base::Feature kDirectCompositionPreferNV12Overlays{ |
| 44 | "DirectCompositionPreferNV12Overlays", base::FEATURE_DISABLED_BY_DEFAULT}; |
| 45 | |
Andres Calderon Jaramillo | 605253d | 2018-09-05 15:46:35 | [diff] [blame] | 46 | // Controls the decode acceleration of JPEG images (as opposed to camera |
| 47 | // captures) in Chrome OS using the VA-API. |
| 48 | // TODO(andrescj): remove or enable by default in Chrome OS once |
| 49 | // https://crbug.com/868400 is resolved. |
| 50 | const base::Feature kVaapiJpegImageDecodeAcceleration{ |
| 51 | "VaapiJpegImageDecodeAcceleration", base::FEATURE_DISABLED_BY_DEFAULT}; |
| 52 | |
ericrk | 41a1579e | 2017-02-10 20:56:28 | [diff] [blame] | 53 | } // namespace features |