[includes] Remove more includes of SkColorSpace
While I was fixing up Chrome's uses, I found some failures there that I did not see in Skia, and tracked them down to a few other places where we include SkColorSpace and it is not strictly necessary - SkCustomMesh.h - GrColorInfo.h - GrColorSpaceXform.h - SkColorSpaceXformSteps.h For these files (and their .cpp files), I added enforcement of include-what-you-use, and then fixed the myriad of places which were depending on these transitive includes. One change to help Chrome is the manual overloads of SkImage::MakeFromAdoptedTexture instead of using default parameters. This makes it so callers of that function do not need to include SkColorSpace if they were going to pass nullptr for it anyway. Bug: skia:13052 Change-Id: I16bf8ed5e258225d887f562f2c189623b1ca9c23 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/527056 Reviewed-by: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Kevin Lubick <kjlubick@google.com>
This commit is contained in:
parent
e4fbfa6a90
commit
8499e372ce
@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
#include "bench/Benchmark.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkFont.h"
|
||||
#include "include/core/SkTypeface.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
|
@ -1922,6 +1922,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":gm_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkPoint_hdr",
|
||||
"//include/core:SkRect_hdr",
|
||||
"//include/private:SkColorData_hdr",
|
||||
@ -3224,6 +3225,7 @@ generated_cc_atom(
|
||||
":gm_hdr",
|
||||
"//include/core:SkBlender_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkCustomMesh_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/effects:SkGradientShader_hdr",
|
||||
@ -4659,6 +4661,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":gm_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/effects:SkGradientShader_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
"//src/core:SkCanvasPriv_hdr",
|
||||
@ -6597,6 +6600,7 @@ generated_cc_atom(
|
||||
"//include/core:SkTypes_hdr",
|
||||
"//include/effects:SkDashPathEffect_hdr",
|
||||
"//include/effects:SkGradientShader_hdr",
|
||||
"//include/private:SkImageInfoPriv_hdr",
|
||||
"//include/private:SkTPin_hdr",
|
||||
"//src/core:SkColorSpaceXformSteps_hdr",
|
||||
],
|
||||
|
@ -6,6 +6,8 @@
|
||||
*/
|
||||
|
||||
#include "gm/gm.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkPoint.h"
|
||||
#include "include/core/SkRect.h"
|
||||
#include "include/private/SkColorData.h"
|
||||
|
@ -8,6 +8,7 @@
|
||||
#include "gm/gm.h"
|
||||
#include "include/core/SkBlender.h"
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkCustomMesh.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/effects/SkGradientShader.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "gm/gm.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/effects/SkGradientShader.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/core/SkCanvasPriv.h"
|
||||
|
@ -24,6 +24,7 @@
|
||||
#include "include/core/SkTypes.h"
|
||||
#include "include/effects/SkDashPathEffect.h"
|
||||
#include "include/effects/SkGradientShader.h"
|
||||
#include "include/private/SkImageInfoPriv.h"
|
||||
#include "include/private/SkTPin.h"
|
||||
#include "src/core/SkColorSpaceXformSteps.h"
|
||||
|
||||
|
@ -111,6 +111,7 @@ skia_gpu_sources = [
|
||||
"$_src/gpu/GrHashMapWithCache.h",
|
||||
"$_src/gpu/GrImageContext.cpp",
|
||||
"$_src/gpu/GrImageContextPriv.h",
|
||||
"$_src/gpu/GrImageInfo.cpp",
|
||||
"$_src/gpu/GrImageInfo.h",
|
||||
"$_src/gpu/GrManagedResource.cpp",
|
||||
"$_src/gpu/GrManagedResource.h",
|
||||
|
@ -933,10 +933,10 @@ generated_cc_atom(
|
||||
generated_cc_atom(
|
||||
name = "SkCustomMesh_hdr",
|
||||
hdrs = ["SkCustomMesh.h"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":SkColorSpace_hdr",
|
||||
":SkImageInfo_hdr",
|
||||
":SkAlphaType_hdr",
|
||||
":SkRect_hdr",
|
||||
":SkRefCnt_hdr",
|
||||
":SkSpan_hdr",
|
||||
|
@ -11,15 +11,17 @@
|
||||
#include "include/core/SkTypes.h"
|
||||
|
||||
#ifdef SK_ENABLE_SKSL
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkImageInfo.h"
|
||||
#include "include/core/SkAlphaType.h"
|
||||
#include "include/core/SkRect.h"
|
||||
#include "include/core/SkRefCnt.h"
|
||||
#include "include/core/SkSpan.h"
|
||||
#include "include/core/SkString.h"
|
||||
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
class SkColorSpace;
|
||||
|
||||
namespace SkSL { struct Program; }
|
||||
|
||||
/**
|
||||
@ -111,13 +113,24 @@ public:
|
||||
* @param at The alpha type of the color produced by 'fs'. Ignored if 'fs's main()
|
||||
* function does not have a color out param. Cannot be kUnknown.
|
||||
*/
|
||||
static Result Make(SkSpan<const Attribute> attributes,
|
||||
size_t vertexStride,
|
||||
SkSpan<const Varying> varyings,
|
||||
const SkString& vs,
|
||||
const SkString& fs);
|
||||
static Result Make(SkSpan<const Attribute> attributes,
|
||||
size_t vertexStride,
|
||||
SkSpan<const Varying> varyings,
|
||||
const SkString& vs,
|
||||
const SkString& fs,
|
||||
sk_sp<SkColorSpace> cs = SkColorSpace::MakeSRGB(),
|
||||
SkAlphaType at = kPremul_SkAlphaType);
|
||||
sk_sp<SkColorSpace> cs);
|
||||
static Result Make(SkSpan<const Attribute> attributes,
|
||||
size_t vertexStride,
|
||||
SkSpan<const Varying> varyings,
|
||||
const SkString& vs,
|
||||
const SkString& fs,
|
||||
sk_sp<SkColorSpace> cs,
|
||||
SkAlphaType at);
|
||||
|
||||
SkSpan<const Attribute> attributes() const { return SkMakeSpan(fAttributes); }
|
||||
|
||||
|
@ -401,12 +401,21 @@ public:
|
||||
@param colorSpace range of colors; may be nullptr
|
||||
@return created SkImage, or nullptr
|
||||
*/
|
||||
static sk_sp<SkImage> MakeFromAdoptedTexture(GrRecordingContext* context,
|
||||
const GrBackendTexture& backendTexture,
|
||||
GrSurfaceOrigin textureOrigin,
|
||||
SkColorType colorType);
|
||||
static sk_sp<SkImage> MakeFromAdoptedTexture(GrRecordingContext* context,
|
||||
const GrBackendTexture& backendTexture,
|
||||
GrSurfaceOrigin textureOrigin,
|
||||
SkColorType colorType,
|
||||
SkAlphaType alphaType = kPremul_SkAlphaType,
|
||||
sk_sp<SkColorSpace> colorSpace = nullptr);
|
||||
SkAlphaType alphaType);
|
||||
static sk_sp<SkImage> MakeFromAdoptedTexture(GrRecordingContext* context,
|
||||
const GrBackendTexture& backendTexture,
|
||||
GrSurfaceOrigin textureOrigin,
|
||||
SkColorType colorType,
|
||||
SkAlphaType alphaType,
|
||||
sk_sp<SkColorSpace> colorSpace);
|
||||
|
||||
/** Creates an SkImage from YUV[A] planar textures. This requires that the textures stay valid
|
||||
for the lifetime of the image. The ReleaseContext can be used to know when it is safe to
|
||||
|
@ -1186,24 +1186,28 @@ generated_cc_atom(
|
||||
generated_cc_atom(
|
||||
name = "SkColorSpaceXformSteps_hdr",
|
||||
hdrs = ["SkColorSpaceXformSteps.h"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":SkVM_fwd_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkImageInfo_hdr",
|
||||
"//include/private:SkImageInfoPriv_hdr",
|
||||
":SkVM_hdr",
|
||||
"//include/core:SkAlphaType_hdr",
|
||||
"//include/third_party/skcms:skcms_hdr",
|
||||
],
|
||||
)
|
||||
|
||||
generated_cc_atom(
|
||||
name = "SkColorSpaceXformSteps_src",
|
||||
srcs = ["SkColorSpaceXformSteps.cpp"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":SkColorSpacePriv_hdr",
|
||||
":SkColorSpaceXformSteps_hdr",
|
||||
":SkRasterPipeline_hdr",
|
||||
":SkVM_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkTypes_hdr",
|
||||
"//include/private:SkFloatingPoint_hdr",
|
||||
"//include/third_party/skcms:skcms_hdr",
|
||||
],
|
||||
)
|
||||
@ -2245,6 +2249,7 @@ generated_cc_atom(
|
||||
":SkGpuBlurUtils_hdr",
|
||||
":SkMathPriv_hdr",
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkRect_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
"//src/gpu:GrCaps_hdr",
|
||||
@ -4563,6 +4568,7 @@ generated_cc_atom(
|
||||
":SkSpecialSurface_hdr",
|
||||
":SkSurfacePriv_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkMallocPixelRef_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
"//src/gpu:GrRecordingContextPriv_hdr",
|
||||
@ -5569,16 +5575,25 @@ generated_cc_atom(
|
||||
generated_cc_atom(
|
||||
name = "SkCustomMesh_src",
|
||||
srcs = ["SkCustomMesh.cpp"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":SkCustomMeshPriv_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkCustomMesh_hdr",
|
||||
"//src/gpu:GrShaderCaps_hdr",
|
||||
"//include/core:SkMath_hdr",
|
||||
"//include/private:SkOpts_spi_hdr",
|
||||
"//include/private:SkSLProgramElement_hdr",
|
||||
"//include/private:SkSLProgramKind_hdr",
|
||||
"//src/sksl:SkSLAnalysis_hdr",
|
||||
"//src/sksl:SkSLBuiltinTypes_hdr",
|
||||
"//src/sksl:SkSLCompiler_hdr",
|
||||
"//src/sksl:SkSLSharedCompiler_hdr",
|
||||
"//src/sksl/ir:SkSLFunctionDeclaration_hdr",
|
||||
"//src/sksl/ir:SkSLFunctionDefinition_hdr",
|
||||
"//src/sksl/ir:SkSLProgram_hdr",
|
||||
"//src/sksl/ir:SkSLVarDeclarations_hdr",
|
||||
"//src/sksl/ir:SkSLType_hdr",
|
||||
"//src/sksl/ir:SkSLVariable_hdr",
|
||||
],
|
||||
)
|
||||
|
||||
|
@ -5,9 +5,13 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "src/core/SkColorSpaceXformSteps.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkTypes.h"
|
||||
#include "include/private/SkFloatingPoint.h"
|
||||
#include "include/third_party/skcms/skcms.h"
|
||||
#include "src/core/SkColorSpacePriv.h"
|
||||
#include "src/core/SkColorSpaceXformSteps.h"
|
||||
#include "src/core/SkRasterPipeline.h"
|
||||
#include "src/core/SkVM.h"
|
||||
|
||||
|
@ -8,11 +8,12 @@
|
||||
#ifndef SkColorSpaceXformSteps_DEFINED
|
||||
#define SkColorSpaceXformSteps_DEFINED
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkImageInfo.h"
|
||||
#include "include/private/SkImageInfoPriv.h"
|
||||
#include "src/core/SkVM_fwd.h"
|
||||
#include "include/core/SkAlphaType.h"
|
||||
#include "include/third_party/skcms/skcms.h"
|
||||
#include "src/core/SkVM.h"
|
||||
#include <stdint.h>
|
||||
|
||||
class SkColorSpace;
|
||||
class SkRasterPipeline;
|
||||
|
||||
struct SkColorSpaceXformSteps {
|
||||
|
@ -8,16 +8,27 @@
|
||||
#include "include/core/SkCustomMesh.h"
|
||||
|
||||
#ifdef SK_ENABLE_SKSL
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkMath.h"
|
||||
#include "include/private/SkOpts_spi.h"
|
||||
#include "include/private/SkSLProgramElement.h"
|
||||
#include "include/private/SkSLProgramKind.h"
|
||||
#include "src/core/SkCustomMeshPriv.h"
|
||||
#include "src/gpu/GrShaderCaps.h"
|
||||
#include "src/sksl/SkSLAnalysis.h"
|
||||
#include "src/sksl/SkSLBuiltinTypes.h"
|
||||
#include "src/sksl/SkSLCompiler.h"
|
||||
#include "src/sksl/SkSLSharedCompiler.h"
|
||||
#include "src/sksl/ir/SkSLFunctionDeclaration.h"
|
||||
#include "src/sksl/ir/SkSLFunctionDefinition.h"
|
||||
#include "src/sksl/ir/SkSLProgram.h"
|
||||
#include "src/sksl/ir/SkSLVarDeclarations.h"
|
||||
#include "src/sksl/ir/SkSLType.h"
|
||||
#include "src/sksl/ir/SkSLVariable.h"
|
||||
|
||||
#include <locale>
|
||||
#include <string>
|
||||
#include <tuple>
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
|
||||
using Attribute = SkCustomMeshSpecification::Attribute;
|
||||
using Varying = SkCustomMeshSpecification::Varying;
|
||||
@ -170,6 +181,27 @@ check_vertex_offsets_and_stride(SkSpan<const Attribute> attributes,
|
||||
RETURN_SUCCESS;
|
||||
}
|
||||
|
||||
SkCustomMeshSpecification::Result SkCustomMeshSpecification::Make(
|
||||
SkSpan<const Attribute> attributes,
|
||||
size_t vertexStride,
|
||||
SkSpan<const Varying> varyings,
|
||||
const SkString& vs,
|
||||
const SkString& fs) {
|
||||
return Make(attributes, vertexStride, varyings, vs, fs,
|
||||
SkColorSpace::MakeSRGB(), kPremul_SkAlphaType);
|
||||
}
|
||||
|
||||
SkCustomMeshSpecification::Result SkCustomMeshSpecification::Make(
|
||||
SkSpan<const Attribute> attributes,
|
||||
size_t vertexStride,
|
||||
SkSpan<const Varying> varyings,
|
||||
const SkString& vs,
|
||||
const SkString& fs,
|
||||
sk_sp<SkColorSpace> cs) {
|
||||
return Make(attributes, vertexStride, varyings, vs, fs,
|
||||
std::move(cs), kPremul_SkAlphaType);
|
||||
}
|
||||
|
||||
SkCustomMeshSpecification::Result SkCustomMeshSpecification::Make(
|
||||
SkSpan<const Attribute> attributes,
|
||||
size_t vertexStride,
|
||||
|
@ -12,6 +12,7 @@
|
||||
#include "src/core/SkMathPriv.h"
|
||||
|
||||
#if SK_SUPPORT_GPU
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/gpu/GrCaps.h"
|
||||
#include "src/gpu/GrRecordingContextPriv.h"
|
||||
|
@ -10,6 +10,7 @@
|
||||
#include <memory>
|
||||
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "src/core/SkSpecialImage.h"
|
||||
#include "src/core/SkSurfacePriv.h"
|
||||
|
||||
|
@ -45,6 +45,7 @@ cc_library(
|
||||
":GrGpuResource_src",
|
||||
":GrGpu_src",
|
||||
":GrImageContext_src",
|
||||
":GrImageInfo_src",
|
||||
":GrManagedResource_src",
|
||||
":GrMemoryPool_src",
|
||||
":GrMeshDrawTarget_src",
|
||||
@ -401,6 +402,7 @@ generated_cc_atom(
|
||||
":GrSurfaceProxyView_hdr",
|
||||
":SurfaceContext_hdr",
|
||||
":SurfaceFillContext_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
],
|
||||
)
|
||||
@ -636,6 +638,7 @@ generated_cc_atom(
|
||||
":GrTextureProxyPriv_hdr",
|
||||
":GrTexture_hdr",
|
||||
":SkGr_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
"//src/core:SkMessageBus_hdr",
|
||||
@ -703,6 +706,7 @@ generated_cc_atom(
|
||||
":GrUtil_hdr",
|
||||
":SkGr_hdr",
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkPaint_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
@ -830,21 +834,25 @@ generated_cc_atom(
|
||||
generated_cc_atom(
|
||||
name = "GrColorInfo_hdr",
|
||||
hdrs = ["GrColorInfo.h"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":GrColorSpaceXform_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkAlphaType_hdr",
|
||||
"//include/core:SkRefCnt_hdr",
|
||||
"//include/gpu:GrTypes_hdr",
|
||||
"//include/private:GrTypesPriv_hdr",
|
||||
],
|
||||
)
|
||||
|
||||
generated_cc_atom(
|
||||
name = "GrColorInfo_src",
|
||||
srcs = ["GrColorInfo.cpp"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":GrColorInfo_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkImageInfo_hdr",
|
||||
"//src/core:SkColorSpacePriv_hdr",
|
||||
],
|
||||
)
|
||||
@ -852,11 +860,14 @@ generated_cc_atom(
|
||||
generated_cc_atom(
|
||||
name = "GrColorSpaceXform_hdr",
|
||||
hdrs = ["GrColorSpaceXform.h"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":GrFragmentProcessor_hdr",
|
||||
"//include/core:SkAlphaType_hdr",
|
||||
"//include/core:SkColor_hdr",
|
||||
"//include/core:SkRefCnt_hdr",
|
||||
"//src/core:SkColorSpacePriv_hdr",
|
||||
"//include/private:SkColorData_hdr",
|
||||
"//src/core:SkColorSpaceXformSteps_hdr",
|
||||
],
|
||||
)
|
||||
@ -864,12 +875,15 @@ generated_cc_atom(
|
||||
generated_cc_atom(
|
||||
name = "GrColorSpaceXform_src",
|
||||
srcs = ["GrColorSpaceXform.cpp"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":GrColorInfo_hdr",
|
||||
":GrColorSpaceXform_hdr",
|
||||
":GrProcessor_hdr",
|
||||
":KeyBuilder_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkString_hdr",
|
||||
"//include/third_party/skcms:skcms_hdr",
|
||||
"//src/core:SkColorSpacePriv_hdr",
|
||||
"//src/gpu/glsl:GrGLSLColorSpaceXformHelper_hdr",
|
||||
"//src/gpu/glsl:GrGLSLFragmentShaderBuilder_hdr",
|
||||
@ -1025,6 +1039,7 @@ generated_cc_atom(
|
||||
":GrImageInfo_hdr",
|
||||
":GrPixmap_hdr",
|
||||
":Swizzle_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/private:SkTPin_hdr",
|
||||
"//include/third_party/skcms:skcms_hdr",
|
||||
"//src/core:SkColorSpaceXformSteps_hdr",
|
||||
@ -1680,14 +1695,29 @@ generated_cc_atom(
|
||||
generated_cc_atom(
|
||||
name = "GrImageInfo_hdr",
|
||||
hdrs = ["GrImageInfo.h"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":GrColorInfo_hdr",
|
||||
"//include/core:SkImageInfo_hdr",
|
||||
"//include/core:SkAlphaType_hdr",
|
||||
"//include/core:SkRefCnt_hdr",
|
||||
"//include/core:SkSize_hdr",
|
||||
"//include/private:GrTypesPriv_hdr",
|
||||
],
|
||||
)
|
||||
|
||||
generated_cc_atom(
|
||||
name = "GrImageInfo_src",
|
||||
srcs = ["GrImageInfo.cpp"],
|
||||
enforce_iwyu = True,
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":GrImageInfo_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkImageInfo_hdr",
|
||||
],
|
||||
)
|
||||
|
||||
generated_cc_atom(
|
||||
name = "GrManagedResource_hdr",
|
||||
hdrs = ["GrManagedResource.h"],
|
||||
@ -1834,6 +1864,7 @@ generated_cc_atom(
|
||||
":GrProgramInfo_hdr",
|
||||
":GrResourceProvider_hdr",
|
||||
":GrTexture_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/core:SkConvertPixels_hdr",
|
||||
],
|
||||
@ -2211,6 +2242,7 @@ generated_cc_atom(
|
||||
":GrRecordingContextPriv_hdr",
|
||||
":GrRenderTargetProxy_hdr",
|
||||
":GrSurfaceProxyView_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//src/gpu/v1:Device_v1_hdr",
|
||||
"//src/gpu/v1:SurfaceDrawContext_v1_hdr",
|
||||
"//src/gpu/v1:SurfaceFillContext_v1_hdr",
|
||||
@ -2538,6 +2570,7 @@ generated_cc_atom(
|
||||
":GrTexture_hdr",
|
||||
":ResourceKey_hdr",
|
||||
":SkGr_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrBackendSemaphore_hdr",
|
||||
"//include/private:SingleOwner_hdr",
|
||||
"//src/core:SkConvertPixels_hdr",
|
||||
@ -2867,6 +2900,7 @@ generated_cc_atom(
|
||||
":GrTextureRenderTargetProxy_hdr",
|
||||
":GrTexture_hdr",
|
||||
":SurfaceFillContext_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
"//src/core:SkMathPriv_hdr",
|
||||
@ -2941,6 +2975,7 @@ generated_cc_atom(
|
||||
":GrProcessorUnitTest_hdr",
|
||||
":GrStyle_hdr",
|
||||
":GrTestUtils_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkMatrix_hdr",
|
||||
"//include/core:SkPathBuilder_hdr",
|
||||
"//include/core:SkRRect_hdr",
|
||||
@ -3473,6 +3508,7 @@ generated_cc_atom(
|
||||
":SkGr_hdr",
|
||||
":SurfaceContext_hdr",
|
||||
":SurfaceFillContext_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
"//src/core:SkAutoPixmapStorage_hdr",
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/BaseDevice.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/gpu/GrProxyProvider.h"
|
||||
#include "src/gpu/GrRecordingContextPriv.h"
|
||||
|
@ -5,6 +5,7 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/core/SkMessageBus.h"
|
||||
|
@ -10,6 +10,7 @@
|
||||
#if SK_GPU_V1
|
||||
|
||||
#include "include/core/SkBitmap.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkPaint.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
|
@ -7,8 +7,12 @@
|
||||
|
||||
#include "src/gpu/GrColorInfo.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkImageInfo.h"
|
||||
#include "src/core/SkColorSpacePriv.h"
|
||||
|
||||
#include <utility>
|
||||
|
||||
GrColorInfo::GrColorInfo(
|
||||
GrColorType colorType, SkAlphaType alphaType, sk_sp<SkColorSpace> colorSpace)
|
||||
: fColorSpace(std::move(colorSpace)), fColorType(colorType), fAlphaType(alphaType) {
|
||||
@ -22,5 +26,24 @@ GrColorInfo::GrColorInfo(const SkColorInfo& ci)
|
||||
ci.alphaType(),
|
||||
ci.refColorSpace()) {}
|
||||
|
||||
GrColorInfo::GrColorInfo() = default;
|
||||
GrColorInfo::GrColorInfo(const GrColorInfo&) = default;
|
||||
GrColorInfo& GrColorInfo::operator=(const GrColorInfo&) = default;
|
||||
GrColorInfo::~GrColorInfo() = default;
|
||||
|
||||
bool GrColorInfo::operator==(const GrColorInfo& that) const {
|
||||
return fColorType == that.fColorType &&
|
||||
fAlphaType == that.fAlphaType &&
|
||||
SkColorSpace::Equals(fColorSpace.get(), that.fColorSpace.get());
|
||||
}
|
||||
|
||||
GrColorInfo GrColorInfo::makeColorType(GrColorType ct) const {
|
||||
return GrColorInfo(ct, fAlphaType, this->refColorSpace());
|
||||
}
|
||||
|
||||
bool GrColorInfo::isLinearlyBlended() const {
|
||||
return fColorSpace && fColorSpace->gammaIsLinear();
|
||||
}
|
||||
|
||||
SkColorSpace* GrColorInfo::colorSpace() const { return fColorSpace.get(); }
|
||||
sk_sp<SkColorSpace> GrColorInfo::refColorSpace() const { return fColorSpace; }
|
||||
|
@ -8,37 +8,34 @@
|
||||
#ifndef GrColorInfo_DEFINED
|
||||
#define GrColorInfo_DEFINED
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkAlphaType.h"
|
||||
#include "include/core/SkRefCnt.h"
|
||||
#include "include/gpu/GrTypes.h"
|
||||
#include "include/private/GrTypesPriv.h"
|
||||
#include "src/gpu/GrColorSpaceXform.h"
|
||||
|
||||
class SkColorInfo;
|
||||
class SkColorSpace;
|
||||
/**
|
||||
* All the info needed to interpret a color: Color type + alpha type + color space. Also caches
|
||||
* the GrColorSpaceXform from sRGB. */
|
||||
class GrColorInfo {
|
||||
public:
|
||||
GrColorInfo() = default;
|
||||
GrColorInfo();
|
||||
GrColorInfo(const GrColorInfo&);
|
||||
GrColorInfo& operator=(const GrColorInfo&);
|
||||
GrColorInfo(GrColorType, SkAlphaType, sk_sp<SkColorSpace>);
|
||||
/* implicit */ GrColorInfo(const SkColorInfo&);
|
||||
~GrColorInfo();
|
||||
|
||||
bool operator==(const GrColorInfo& that) const {
|
||||
return fColorType == that.fColorType &&
|
||||
fAlphaType == that.fAlphaType &&
|
||||
SkColorSpace::Equals(fColorSpace.get(), that.fColorSpace.get());
|
||||
}
|
||||
bool operator==(const GrColorInfo& that) const;
|
||||
bool operator!=(const GrColorInfo& that) const { return !(*this == that); }
|
||||
|
||||
GrColorInfo makeColorType(GrColorType ct) const {
|
||||
return GrColorInfo(ct, fAlphaType, this->refColorSpace());
|
||||
}
|
||||
GrColorInfo makeColorType(GrColorType ct) const;
|
||||
|
||||
bool isLinearlyBlended() const { return fColorSpace && fColorSpace->gammaIsLinear(); }
|
||||
bool isLinearlyBlended() const;
|
||||
|
||||
SkColorSpace* colorSpace() const { return fColorSpace.get(); }
|
||||
sk_sp<SkColorSpace> refColorSpace() const { return fColorSpace; }
|
||||
SkColorSpace* colorSpace() const;
|
||||
sk_sp<SkColorSpace> refColorSpace() const;
|
||||
|
||||
GrColorSpaceXform* colorSpaceXformFromSRGB() const { return fColorXformFromSRGB.get(); }
|
||||
sk_sp<GrColorSpaceXform> refColorSpaceXformFromSRGB() const { return fColorXformFromSRGB; }
|
||||
|
@ -7,12 +7,20 @@
|
||||
|
||||
#include "src/gpu/GrColorSpaceXform.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkString.h"
|
||||
#include "include/third_party/skcms/skcms.h"
|
||||
#include "src/core/SkColorSpacePriv.h"
|
||||
#include "src/gpu/GrColorInfo.h"
|
||||
#include "src/gpu/GrProcessor.h"
|
||||
#include "src/gpu/KeyBuilder.h"
|
||||
#include "src/gpu/glsl/GrGLSLColorSpaceXformHelper.h"
|
||||
#include "src/gpu/glsl/GrGLSLFragmentShaderBuilder.h"
|
||||
#include <string.h>
|
||||
#include <utility>
|
||||
|
||||
class GrGLSLProgramDataManager;
|
||||
class GrGLSLUniformHandler;
|
||||
struct GrShaderCaps;
|
||||
|
||||
sk_sp<GrColorSpaceXform> GrColorSpaceXform::Make(SkColorSpace* src, SkAlphaType srcAT,
|
||||
SkColorSpace* dst, SkAlphaType dstAT) {
|
||||
@ -27,6 +35,22 @@ sk_sp<GrColorSpaceXform> GrColorSpaceXform::Make(const GrColorInfo& srcInfo,
|
||||
dstInfo.colorSpace(), dstInfo.alphaType());
|
||||
}
|
||||
|
||||
uint32_t GrColorSpaceXform::XformKey(const GrColorSpaceXform* xform) {
|
||||
// Code generation depends on which steps we apply,
|
||||
// and the kinds of transfer functions (if we're applying those).
|
||||
if (!xform) { return 0; }
|
||||
|
||||
const SkColorSpaceXformSteps& steps(xform->fSteps);
|
||||
uint32_t key = steps.flags.mask();
|
||||
if (steps.flags.linearize) {
|
||||
key |= classify_transfer_fn(steps.srcTF) << 8;
|
||||
}
|
||||
if (steps.flags.encode) {
|
||||
key |= classify_transfer_fn(steps.dstTFInv) << 16;
|
||||
}
|
||||
return key;
|
||||
}
|
||||
|
||||
bool GrColorSpaceXform::Equals(const GrColorSpaceXform* a, const GrColorSpaceXform* b) {
|
||||
if (a == b) {
|
||||
return true;
|
||||
|
@ -8,13 +8,21 @@
|
||||
#ifndef GrColorSpaceXform_DEFINED
|
||||
#define GrColorSpaceXform_DEFINED
|
||||
|
||||
#include "include/core/SkAlphaType.h"
|
||||
#include "include/core/SkColor.h"
|
||||
#include "include/core/SkRefCnt.h"
|
||||
#include "src/core/SkColorSpacePriv.h"
|
||||
#include "include/private/SkColorData.h"
|
||||
#include "src/core/SkColorSpaceXformSteps.h"
|
||||
#include "src/gpu/GrFragmentProcessor.h"
|
||||
|
||||
#include <stdint.h>
|
||||
#include <memory>
|
||||
|
||||
class GrColorInfo;
|
||||
class SkColorSpace;
|
||||
struct GrShaderCaps;
|
||||
|
||||
namespace skgpu { class KeyBuilder; }
|
||||
|
||||
/**
|
||||
* Represents a color space transformation
|
||||
@ -34,21 +42,7 @@ public:
|
||||
* GrFragmentProcessor::addToKey() must call this and include the returned value in its
|
||||
* computed key.
|
||||
*/
|
||||
static uint32_t XformKey(const GrColorSpaceXform* xform) {
|
||||
// Code generation depends on which steps we apply,
|
||||
// and the kinds of transfer functions (if we're applying those).
|
||||
if (!xform) { return 0; }
|
||||
|
||||
const SkColorSpaceXformSteps& steps(xform->fSteps);
|
||||
uint32_t key = steps.flags.mask();
|
||||
if (steps.flags.linearize) {
|
||||
key |= classify_transfer_fn(steps.srcTF) << 8;
|
||||
}
|
||||
if (steps.flags.encode) {
|
||||
key |= classify_transfer_fn(steps.dstTFInv) << 16;
|
||||
}
|
||||
return key;
|
||||
}
|
||||
static uint32_t XformKey(const GrColorSpaceXform* xform);
|
||||
|
||||
static bool Equals(const GrColorSpaceXform* a, const GrColorSpaceXform* b);
|
||||
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/GrDataUtils.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/private/SkTPin.h"
|
||||
#include "include/third_party/skcms/skcms.h"
|
||||
#include "src/core/SkColorSpaceXformSteps.h"
|
||||
|
58
src/gpu/GrImageInfo.cpp
Normal file
58
src/gpu/GrImageInfo.cpp
Normal file
@ -0,0 +1,58 @@
|
||||
/*
|
||||
* Copyright 2022 Google LLC
|
||||
*
|
||||
* Use of this source code is governed by a BSD-style license that can be
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "src/gpu/GrImageInfo.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkImageInfo.h"
|
||||
|
||||
#include <utility>
|
||||
|
||||
GrImageInfo::GrImageInfo() = default;
|
||||
|
||||
GrImageInfo::GrImageInfo(const SkImageInfo& info)
|
||||
: fColorInfo(info.colorInfo()), fDimensions(info.dimensions()) {}
|
||||
|
||||
GrImageInfo::GrImageInfo(GrColorType ct, SkAlphaType at, sk_sp<SkColorSpace> cs, int w, int h)
|
||||
: fColorInfo(ct, at, std::move(cs)), fDimensions{w,h} {}
|
||||
|
||||
GrImageInfo::GrImageInfo(GrColorType ct, SkAlphaType at, sk_sp<SkColorSpace> cs,
|
||||
const SkISize& dimensions)
|
||||
: fColorInfo(ct, at, std::move(cs)), fDimensions(dimensions) {}
|
||||
|
||||
GrImageInfo::GrImageInfo(const GrColorInfo& info, const SkISize& dimensions)
|
||||
: fColorInfo(info), fDimensions(dimensions) {}
|
||||
|
||||
GrImageInfo::GrImageInfo(GrColorInfo&& info, const SkISize& dimensions)
|
||||
: fColorInfo(std::move(info)), fDimensions(dimensions) {}
|
||||
|
||||
GrImageInfo::GrImageInfo(const GrImageInfo&) = default;
|
||||
GrImageInfo::GrImageInfo(GrImageInfo&&) = default;
|
||||
GrImageInfo& GrImageInfo::operator=(const GrImageInfo&) = default;
|
||||
GrImageInfo& GrImageInfo::operator=(GrImageInfo&&) = default;
|
||||
|
||||
GrImageInfo GrImageInfo::makeColorType(GrColorType ct) const {
|
||||
return {this->colorInfo().makeColorType(ct), this->dimensions()};
|
||||
}
|
||||
|
||||
GrImageInfo GrImageInfo::makeAlphaType(SkAlphaType at) const {
|
||||
return {this->colorType(), at, this->refColorSpace(), this->width(), this->height()};
|
||||
}
|
||||
|
||||
GrImageInfo GrImageInfo::makeColorSpace(sk_sp<SkColorSpace> cs) const {
|
||||
return {this->colorType(), this->alphaType(), std::move(cs), this->width(), this->height()};
|
||||
}
|
||||
|
||||
GrImageInfo GrImageInfo::makeDimensions(SkISize dimensions) const {
|
||||
return {this->colorType(), this->alphaType(), this->refColorSpace(), dimensions};
|
||||
}
|
||||
|
||||
GrImageInfo GrImageInfo::makeWH(int width, int height) const {
|
||||
return {this->colorType(), this->alphaType(), this->refColorSpace(), width, height};
|
||||
}
|
||||
|
||||
sk_sp<SkColorSpace> GrImageInfo::refColorSpace() const { return fColorInfo.refColorSpace(); }
|
@ -8,53 +8,36 @@
|
||||
#ifndef GrImageInfo_DEFINED
|
||||
#define GrImageInfo_DEFINED
|
||||
|
||||
#include "include/core/SkImageInfo.h"
|
||||
#include "include/core/SkAlphaType.h"
|
||||
#include "include/core/SkRefCnt.h"
|
||||
#include "include/core/SkSize.h"
|
||||
#include "include/private/GrTypesPriv.h"
|
||||
#include "src/gpu/GrColorInfo.h"
|
||||
|
||||
#include <stddef.h>
|
||||
|
||||
class SkColorSpace;
|
||||
struct SkImageInfo;
|
||||
|
||||
class GrImageInfo {
|
||||
public:
|
||||
GrImageInfo() = default;
|
||||
GrImageInfo();
|
||||
GrImageInfo(const SkImageInfo& info);
|
||||
GrImageInfo(GrColorType ct, SkAlphaType at, sk_sp<SkColorSpace> cs, int w, int h);
|
||||
GrImageInfo(GrColorType ct, SkAlphaType at, sk_sp<SkColorSpace> cs, const SkISize& dimensions);
|
||||
GrImageInfo(const GrColorInfo& info, const SkISize& dimensions);
|
||||
GrImageInfo(GrColorInfo&& info, const SkISize& dimensions);
|
||||
|
||||
/* implicit */ GrImageInfo(const SkImageInfo& info)
|
||||
: fColorInfo(info.colorInfo()), fDimensions(info.dimensions()) {}
|
||||
GrImageInfo(const GrImageInfo&);
|
||||
GrImageInfo(GrImageInfo&&);
|
||||
GrImageInfo& operator=(const GrImageInfo&);
|
||||
GrImageInfo& operator=(GrImageInfo&&);
|
||||
|
||||
GrImageInfo(GrColorType ct, SkAlphaType at, sk_sp<SkColorSpace> cs, int w, int h)
|
||||
: fColorInfo(ct, at, std::move(cs)), fDimensions{w,h} {}
|
||||
|
||||
GrImageInfo(GrColorType ct, SkAlphaType at, sk_sp<SkColorSpace> cs, const SkISize& dimensions)
|
||||
: fColorInfo(ct, at, std::move(cs)), fDimensions(dimensions) {}
|
||||
|
||||
GrImageInfo(const GrColorInfo& info, const SkISize& dimensions)
|
||||
: fColorInfo(info), fDimensions(dimensions) {}
|
||||
|
||||
GrImageInfo(GrColorInfo&& info, const SkISize& dimensions)
|
||||
: fColorInfo(std::move(info)), fDimensions(dimensions) {}
|
||||
|
||||
GrImageInfo(const GrImageInfo&) = default;
|
||||
GrImageInfo(GrImageInfo&&) = default;
|
||||
GrImageInfo& operator=(const GrImageInfo&) = default;
|
||||
GrImageInfo& operator=(GrImageInfo&&) = default;
|
||||
|
||||
GrImageInfo makeColorType(GrColorType ct) const {
|
||||
return {this->colorInfo().makeColorType(ct), this->dimensions()};
|
||||
}
|
||||
|
||||
GrImageInfo makeAlphaType(SkAlphaType at) const {
|
||||
return {this->colorType(), at, this->refColorSpace(), this->width(), this->height()};
|
||||
}
|
||||
|
||||
GrImageInfo makeColorSpace(sk_sp<SkColorSpace> cs) const {
|
||||
return {this->colorType(), this->alphaType(), std::move(cs), this->width(), this->height()};
|
||||
}
|
||||
|
||||
GrImageInfo makeDimensions(SkISize dimensions) const {
|
||||
return {this->colorType(), this->alphaType(), this->refColorSpace(), dimensions};
|
||||
}
|
||||
|
||||
GrImageInfo makeWH(int width, int height) const {
|
||||
return {this->colorType(), this->alphaType(), this->refColorSpace(), width, height};
|
||||
}
|
||||
GrImageInfo makeColorType(GrColorType ct) const;
|
||||
GrImageInfo makeAlphaType(SkAlphaType at) const;
|
||||
GrImageInfo makeColorSpace(sk_sp<SkColorSpace> cs) const;
|
||||
GrImageInfo makeDimensions(SkISize dimensions) const ;
|
||||
GrImageInfo makeWH(int width, int height) const;
|
||||
|
||||
const GrColorInfo& colorInfo() const { return fColorInfo; }
|
||||
|
||||
@ -64,7 +47,7 @@ public:
|
||||
|
||||
SkColorSpace* colorSpace() const { return fColorInfo.colorSpace(); }
|
||||
|
||||
sk_sp<SkColorSpace> refColorSpace() const { return fColorInfo.refColorSpace(); }
|
||||
sk_sp<SkColorSpace> refColorSpace() const;
|
||||
|
||||
SkISize dimensions() const { return fDimensions; }
|
||||
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/GrOpFlushState.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/core/SkConvertPixels.h"
|
||||
#include "src/gpu/GrDataUtils.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/GrRecordingContextPriv.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "src/gpu/GrCaps.h"
|
||||
#include "src/gpu/GrDrawingManager.h"
|
||||
#include "src/gpu/GrProxyProvider.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/GrResourceProvider.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrBackendSemaphore.h"
|
||||
#include "include/private/SingleOwner.h"
|
||||
#include "src/core/SkConvertPixels.h"
|
||||
|
@ -8,6 +8,7 @@
|
||||
#include "src/gpu/GrSurfaceProxy.h"
|
||||
#include "src/gpu/GrSurfaceProxyPriv.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/core/SkMathPriv.h"
|
||||
#include "src/gpu/GrAttachment.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/GrTestUtils.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkMatrix.h"
|
||||
#include "include/core/SkPathBuilder.h"
|
||||
#include "include/core/SkRRect.h"
|
||||
|
@ -7,8 +7,7 @@
|
||||
|
||||
#include "src/gpu/SurfaceContext.h"
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/core/SkAutoPixmapStorage.h"
|
||||
@ -30,6 +29,8 @@
|
||||
#include "src/gpu/effects/GrBicubicEffect.h"
|
||||
#include "src/gpu/effects/GrTextureEffect.h"
|
||||
|
||||
#include <memory>
|
||||
|
||||
#define ASSERT_SINGLE_OWNER SKGPU_ASSERT_SINGLE_OWNER(this->singleOwner())
|
||||
#define RETURN_FALSE_IF_ABANDONED if (this->fContext->abandoned()) { return false; }
|
||||
#define RETURN_NULLPTR_IF_ABANDONED if (this->fContext->abandoned()) { return nullptr; }
|
||||
|
@ -503,6 +503,7 @@ generated_cc_atom(
|
||||
"//include/private:GrContext_Base_hdr",
|
||||
"//include/private:SkSLString_hdr",
|
||||
"//src/core:SkColorFilterBase_hdr",
|
||||
"//src/core:SkColorSpacePriv_hdr",
|
||||
"//src/core:SkRuntimeEffectPriv_hdr",
|
||||
"//src/core:SkVM_hdr",
|
||||
"//src/gpu:GrBaseContextPriv_hdr",
|
||||
|
@ -112,7 +112,7 @@ GrMatrixConvolutionEffect::KernelWrapper::Make(GrRecordingContext* rContext,
|
||||
}
|
||||
|
||||
SkBitmap bm;
|
||||
auto info = SkImageInfo::Make({length, 1}, colorType, kPremul_SkAlphaType, nullptr);
|
||||
auto info = SkImageInfo::Make({length, 1}, colorType, kPremul_SkAlphaType);
|
||||
if (!bm.tryAllocPixels(info)) {
|
||||
return {};
|
||||
}
|
||||
|
@ -10,6 +10,7 @@
|
||||
#include "include/effects/SkRuntimeEffect.h"
|
||||
#include "include/private/GrContext_Base.h"
|
||||
#include "include/private/SkSLString.h"
|
||||
#include "src/core/SkColorSpacePriv.h"
|
||||
#include "src/core/SkRuntimeEffectPriv.h"
|
||||
#include "src/core/SkVM.h"
|
||||
#include "src/gpu/GrBaseContextPriv.h"
|
||||
|
@ -250,6 +250,7 @@ generated_cc_atom(
|
||||
":GrGLOpsRenderPass_hdr",
|
||||
":GrGLSemaphore_hdr",
|
||||
":GrGLTextureRenderTarget_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkPixmap_hdr",
|
||||
"//include/core:SkTypes_hdr",
|
||||
"//include/gpu:GrBackendSemaphore_hdr",
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/gl/GrGLGpu.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkPixmap.h"
|
||||
#include "include/core/SkTypes.h"
|
||||
#include "include/gpu/GrBackendSemaphore.h"
|
||||
|
@ -48,6 +48,7 @@ generated_cc_atom(
|
||||
deps = [
|
||||
":GrGradientBitmapCache_hdr",
|
||||
":GrGradientShader_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
"//src/core:SkMathPriv_hdr",
|
||||
"//src/core:SkRuntimeEffectPriv_hdr",
|
||||
|
@ -7,8 +7,7 @@
|
||||
|
||||
#include "src/gpu/gradients/GrGradientShader.h"
|
||||
|
||||
#include "src/gpu/gradients/GrGradientBitmapCache.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/core/SkMathPriv.h"
|
||||
#include "src/core/SkRuntimeEffectPriv.h"
|
||||
@ -20,6 +19,7 @@
|
||||
#include "src/gpu/effects/GrMatrixEffect.h"
|
||||
#include "src/gpu/effects/GrSkSLFP.h"
|
||||
#include "src/gpu/effects/GrTextureEffect.h"
|
||||
#include "src/gpu/gradients/GrGradientBitmapCache.h"
|
||||
|
||||
using Vec4 = skvx::Vec<4, float>;
|
||||
|
||||
|
@ -20,6 +20,7 @@ generated_cc_atom(
|
||||
":GrAtlasManager_hdr",
|
||||
":GrStrikeCache_hdr",
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkImageEncoder_hdr",
|
||||
"//include/core:SkStream_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/text/GrAtlasManager.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "src/codec/SkMasks.h"
|
||||
#include "src/core/SkAutoMalloc.h"
|
||||
#include "src/gpu/GrGlyph.h"
|
||||
|
@ -24,6 +24,7 @@ generated_cc_atom(
|
||||
":ClipStack_hdr",
|
||||
":StencilMaskHelper_hdr",
|
||||
":SurfaceDrawContext_v1_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkMatrix_hdr",
|
||||
"//src/core:SkMatrixProvider_hdr",
|
||||
"//src/core:SkPathPriv_hdr",
|
||||
@ -255,6 +256,7 @@ generated_cc_atom(
|
||||
deps = [
|
||||
":PathRenderer_hdr",
|
||||
":SurfaceDrawContext_v1_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkDrawable_hdr",
|
||||
"//include/core:SkVertices_hdr",
|
||||
"//include/gpu:GrBackendSemaphore_hdr",
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/v1/ClipStack.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkMatrix.h"
|
||||
#include "src/core/SkMatrixProvider.h"
|
||||
#include "src/core/SkPathPriv.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "src/gpu/v1/SurfaceDrawContext_v1.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkDrawable.h"
|
||||
#include "include/core/SkVertices.h"
|
||||
#include "include/gpu/GrBackendSemaphore.h"
|
||||
|
@ -472,6 +472,22 @@ sk_sp<SkImage> SkImage::MakeFromTexture(GrRecordingContext* rContext,
|
||||
kBorrow_GrWrapOwnership, std::move(releaseHelper));
|
||||
}
|
||||
|
||||
sk_sp<SkImage> SkImage::MakeFromAdoptedTexture(GrRecordingContext* context,
|
||||
const GrBackendTexture& backendTexture,
|
||||
GrSurfaceOrigin textureOrigin,
|
||||
SkColorType colorType) {
|
||||
return SkImage::MakeFromAdoptedTexture(context, backendTexture, textureOrigin,
|
||||
colorType, kPremul_SkAlphaType, nullptr);
|
||||
}
|
||||
sk_sp<SkImage> SkImage::MakeFromAdoptedTexture(GrRecordingContext* context,
|
||||
const GrBackendTexture& backendTexture,
|
||||
GrSurfaceOrigin textureOrigin,
|
||||
SkColorType colorType,
|
||||
SkAlphaType alphaType) {
|
||||
return SkImage::MakeFromAdoptedTexture(context, backendTexture, textureOrigin,
|
||||
colorType, alphaType, nullptr);
|
||||
}
|
||||
|
||||
sk_sp<SkImage> SkImage::MakeFromAdoptedTexture(GrRecordingContext* rContext,
|
||||
const GrBackendTexture& tex, GrSurfaceOrigin origin,
|
||||
SkColorType ct, SkAlphaType at,
|
||||
|
@ -690,6 +690,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkImage_hdr",
|
||||
"//include/gpu:GrBackendSurface_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
@ -873,6 +874,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/core:SkBlendModePriv_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
@ -1382,6 +1384,7 @@ generated_cc_atom(
|
||||
":TestUtils_hdr",
|
||||
":Test_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
"//src/core:SkAutoPixmapStorage_hdr",
|
||||
@ -1468,6 +1471,7 @@ generated_cc_atom(
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkVertices_hdr",
|
||||
"//src/core:SkBlendModePriv_hdr",
|
||||
"//src/core:SkMatrixProvider_hdr",
|
||||
@ -1813,6 +1817,7 @@ generated_cc_atom(
|
||||
deps = [
|
||||
":TestUtils_hdr",
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
"//src/gpu:GrProxyProvider_hdr",
|
||||
@ -1900,6 +1905,7 @@ generated_cc_atom(
|
||||
":TestUtils_hdr",
|
||||
":Test_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkImage_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
@ -2028,6 +2034,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/private:SkHalf_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
@ -2186,6 +2193,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkImage_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/core:SkTypes_hdr",
|
||||
@ -2303,6 +2311,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkPath_hdr",
|
||||
"//include/core:SkRRect_hdr",
|
||||
"//include/core:SkRect_hdr",
|
||||
@ -2422,6 +2431,7 @@ generated_cc_atom(
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/gpu:GrCaps_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
@ -2499,6 +2509,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkTypes_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
@ -2624,6 +2635,7 @@ generated_cc_atom(
|
||||
":Test_hdr",
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//src/gpu:GrCaps_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
@ -2639,6 +2651,7 @@ generated_cc_atom(
|
||||
deps = [
|
||||
":TestUtils_hdr",
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/core:SkAutoPixmapStorage_hdr",
|
||||
@ -2745,6 +2758,7 @@ generated_cc_atom(
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorPriv_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkShader_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/effects:SkGradientShader_hdr",
|
||||
@ -3104,6 +3118,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu/mock:GrMockTypes_hdr",
|
||||
"//src/core:SkRectPriv_hdr",
|
||||
"//src/gpu:GrClip_hdr",
|
||||
@ -4464,6 +4479,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkPath_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/gpu:GrRecordingContext_hdr",
|
||||
@ -4668,6 +4684,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkString_hdr",
|
||||
"//include/core:SkTypes_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
@ -4695,6 +4712,7 @@ generated_cc_atom(
|
||||
":TestHarness_hdr",
|
||||
":TestUtils_hdr",
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/gpu:GrClip_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
@ -4720,6 +4738,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkTypes_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//include/private:SkChecksum_hdr",
|
||||
@ -5054,6 +5073,7 @@ generated_cc_atom(
|
||||
deps = [
|
||||
":TestUtils_hdr",
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
"//src/gpu:GrProxyProvider_hdr",
|
||||
@ -5203,6 +5223,7 @@ generated_cc_atom(
|
||||
":TestUtils_hdr",
|
||||
":Test_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/gpu:GrCaps_hdr",
|
||||
@ -5219,6 +5240,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkTypes_hdr",
|
||||
"//src/core:SkColorSpaceXformSteps_hdr",
|
||||
"//src/core:SkRasterPipeline_hdr",
|
||||
@ -6207,6 +6229,7 @@ generated_cc_atom(
|
||||
":Test_hdr",
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkImage_hdr",
|
||||
"//include/core:SkPixmap_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
@ -6371,6 +6394,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
"//src/gpu:GrImageInfo_hdr",
|
||||
@ -6387,6 +6411,7 @@ generated_cc_atom(
|
||||
":Test_hdr",
|
||||
"//include/core:SkBitmap_hdr",
|
||||
"//include/core:SkCanvas_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/gpu:GrBackendSemaphore_hdr",
|
||||
"//include/gpu:GrBackendSurface_hdr",
|
||||
@ -6527,6 +6552,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":TestUtils_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkStream_hdr",
|
||||
"//include/encode:SkPngEncoder_hdr",
|
||||
"//include/utils:SkBase64_hdr",
|
||||
@ -6621,6 +6647,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
"//src/gpu:GrDirectContextPriv_hdr",
|
||||
@ -6750,6 +6777,7 @@ generated_cc_atom(
|
||||
deps = [
|
||||
":TestUtils_hdr",
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkSurface_hdr",
|
||||
"//include/core:SkTypes_hdr",
|
||||
"//include/gpu:GrDirectContext_hdr",
|
||||
@ -6770,6 +6798,7 @@ generated_cc_atom(
|
||||
visibility = ["//:__subpackages__"],
|
||||
deps = [
|
||||
":Test_hdr",
|
||||
"//include/core:SkColorSpace_hdr",
|
||||
"//include/core:SkPath_hdr",
|
||||
"//include/core:SkRect_hdr",
|
||||
"//include/effects:SkGradientShader_hdr",
|
||||
|
@ -5,6 +5,7 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkImage.h"
|
||||
#include "include/gpu/GrBackendSurface.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
|
@ -5,6 +5,7 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/core/SkBlendModePriv.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
|
@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/core/SkAutoPixmapStorage.h"
|
||||
|
@ -8,6 +8,7 @@
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkBitmap.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkVertices.h"
|
||||
#include "src/core/SkBlendModePriv.h"
|
||||
#include "src/core/SkMatrixProvider.h"
|
||||
|
@ -5,6 +5,7 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
#include "src/gpu/GrProxyProvider.h"
|
||||
|
@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkImage.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
|
@ -14,6 +14,7 @@
|
||||
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "include/private/SkHalf.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
|
@ -11,6 +11,7 @@
|
||||
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkImage.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/gpu/GrBackendSurface.h"
|
||||
|
@ -9,6 +9,7 @@
|
||||
#include "src/gpu/v1/ClipStack.h"
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkPath.h"
|
||||
#include "include/core/SkRRect.h"
|
||||
#include "include/core/SkRect.h"
|
||||
|
@ -7,10 +7,9 @@
|
||||
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include <array>
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
#include "include/core/SkBitmap.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/gpu/GrCaps.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
@ -29,6 +28,10 @@
|
||||
#include "src/gpu/ops/GrSimpleMeshDrawOpHelper.h"
|
||||
#include "src/gpu/v1/SurfaceDrawContext_v1.h"
|
||||
|
||||
#include <array>
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
#if 0
|
||||
#include "tools/ToolUtils.h"
|
||||
#define WRITE_PNG_CONTEXT_TYPE kANGLE_D3D11_ES3_ContextType
|
||||
|
@ -8,6 +8,7 @@
|
||||
#include "include/core/SkTypes.h"
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
#include "src/gpu/GrColor.h"
|
||||
|
@ -9,6 +9,7 @@
|
||||
|
||||
#include "include/core/SkBitmap.h"
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "src/gpu/GrCaps.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
|
@ -5,7 +5,7 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include <set>
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/core/SkAutoPixmapStorage.h"
|
||||
@ -26,6 +26,8 @@
|
||||
#include "tools/gpu/BackendTextureImageFactory.h"
|
||||
#include "tools/gpu/ManagedBackendTexture.h"
|
||||
|
||||
#include <set>
|
||||
|
||||
// Tests that GrSurface::asTexture(), GrSurface::asRenderTarget(), and static upcasting of texture
|
||||
// and render targets to GrSurface all work as expected.
|
||||
DEF_GPUTEST_FOR_MOCK_CONTEXT(GrSurface, reporter, ctxInfo) {
|
||||
|
@ -8,6 +8,7 @@
|
||||
#include "include/core/SkBitmap.h"
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorPriv.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkShader.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/effects/SkGradientShader.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/mock/GrMockTypes.h"
|
||||
#include "src/core/SkRectPriv.h"
|
||||
#include "src/gpu/GrClip.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkPath.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "include/gpu/GrRecordingContext.h"
|
||||
|
@ -7,11 +7,9 @@
|
||||
|
||||
// This is a GPU-backend specific test. It relies on static initializers to work
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "include/core/SkTypes.h"
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkString.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/core/SkPointPriv.h"
|
||||
@ -27,6 +25,9 @@
|
||||
#include "src/gpu/ops/GrMeshDrawOp.h"
|
||||
#include "src/gpu/ops/GrSimpleMeshDrawOpHelper.h"
|
||||
#include "src/gpu/v1/SurfaceDrawContext_v1.h"
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include <memory>
|
||||
|
||||
namespace {
|
||||
class Op : public GrMeshDrawOp {
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/gpu/GrClip.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
|
@ -9,6 +9,7 @@
|
||||
|
||||
#include "include/core/SkTypes.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "include/private/SkChecksum.h"
|
||||
#include "include/utils/SkRandom.h"
|
||||
|
@ -8,6 +8,7 @@
|
||||
#include "tests/Test.h"
|
||||
#include "tests/TestUtils.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
#include "src/gpu/GrProxyProvider.h"
|
||||
|
@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/gpu/GrCaps.h"
|
||||
|
@ -5,6 +5,7 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkTypes.h"
|
||||
#include "src/core/SkColorSpaceXformSteps.h"
|
||||
#include "src/core/SkRasterPipeline.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "include/core/SkBitmap.h"
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkImage.h"
|
||||
#include "include/core/SkPixmap.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
|
@ -9,6 +9,7 @@
|
||||
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
#include "src/gpu/GrImageInfo.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "include/core/SkBitmap.h"
|
||||
#include "include/core/SkCanvas.h"
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/gpu/GrBackendSemaphore.h"
|
||||
#include "include/gpu/GrBackendSurface.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "tests/TestUtils.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkStream.h"
|
||||
#include "include/encode/SkPngEncoder.h"
|
||||
#include "include/utils/SkBase64.h"
|
||||
|
@ -5,6 +5,7 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
|
@ -5,10 +5,11 @@
|
||||
* found in the LICENSE file.
|
||||
*/
|
||||
|
||||
// This is a GPU-backend specific test. It relies on static intializers to work
|
||||
// This is a GPU-backend specific test. It relies on static initializers to work
|
||||
|
||||
#include "include/core/SkTypes.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkSurface.h"
|
||||
#include "include/gpu/GrDirectContext.h"
|
||||
#include "src/gpu/GrDirectContextPriv.h"
|
||||
|
@ -7,6 +7,7 @@
|
||||
|
||||
#include "tests/Test.h"
|
||||
|
||||
#include "include/core/SkColorSpace.h"
|
||||
#include "include/core/SkPath.h"
|
||||
#include "include/core/SkRect.h"
|
||||
#include "include/effects/SkGradientShader.h"
|
||||
|
Loading…
Reference in New Issue
Block a user