@@ -36,32 +36,46 @@ class SK_API GrContextThreadSafeProxy final : public SkNVRefCnt<GrContextThreadS
3636 * that created this proxy. On failure the resulting characterization will be invalid (i.e.,
3737 * "!c.isValid()").
3838 *
39- * @param cacheMaxResourceBytes The max resource bytes limit that will be in effect when the
40- * DDL created with this characterization is replayed.
41- * Note: the contract here is that the DDL will be created as
42- * if it had a full 'cacheMaxResourceBytes' to use. If replayed
43- * into a GrContext that already has locked GPU memory, the
44- * replay can exceed the budget. To rephrase, all resource
45- * allocation decisions are made at record time and at playback
46- * time the budget limits will be ignored.
47- * @param ii The image info specifying properties of the SkSurface that
48- * the DDL created with this characterization will be replayed
49- * into.
50- * Note: Ganesh doesn't make use of the SkImageInfo's alphaType
51- * @param backendFormat Information about the format of the GPU surface that will
52- * back the SkSurface upon replay
53- * @param sampleCount The sample count of the SkSurface that the DDL created with
54- * this characterization will be replayed into
55- * @param origin The origin of the SkSurface that the DDL created with this
56- * characterization will be replayed into
57- * @param surfaceProps The surface properties of the SkSurface that the DDL created
58- * with this characterization will be replayed into
59- * @param isMipMapped Will the surface the DDL will be replayed into have space
60- * allocated for mipmaps?
61- * @param willUseGLFBO0 Will the surface the DDL will be replayed into be backed by GL
62- * FBO 0. This flag is only valid if using an GL backend.
63- * @param isTextureable Will the surface be able to act as a texture?
64- * @param isProtected Will the (Vulkan) surface be DRM protected?
39+ * @param cacheMaxResourceBytes The max resource bytes limit that will be in effect
40+ * when the DDL created with this characterization is
41+ * replayed.
42+ * Note: the contract here is that the DDL will be
43+ * created as if it had a full 'cacheMaxResourceBytes'
44+ * to use. If replayed into a GrContext that already has
45+ * locked GPU memory, the replay can exceed the budget.
46+ * To rephrase, all resource allocation decisions are
47+ * made at record time and at playback time the budget
48+ * limits will be ignored.
49+ * @param ii The image info specifying properties of the SkSurface
50+ * that the DDL created with this characterization will
51+ * be replayed into.
52+ * Note: Ganesh doesn't make use of the SkImageInfo's
53+ * alphaType
54+ * @param backendFormat Information about the format of the GPU surface that
55+ * will back the SkSurface upon replay
56+ * @param sampleCount The sample count of the SkSurface that the DDL
57+ * created with this characterization will be replayed
58+ * into
59+ * @param origin The origin of the SkSurface that the DDL created with
60+ * this characterization will be replayed into
61+ * @param surfaceProps The surface properties of the SkSurface that the DDL
62+ * created with this characterization will be replayed into
63+ * @param isMipMapped Will the surface the DDL will be replayed into have
64+ * space allocated for mipmaps?
65+ * @param willUseGLFBO0 Will the surface the DDL will be replayed into be
66+ * backed by GL FBO 0. This flag is only valid if using
67+ * an GL backend.
68+ * @param isTextureable Will the surface be able to act as a texture?
69+ * @param isProtected Will the (Vulkan) surface be DRM protected?
70+ * @param vkRTSupportsInputAttachment Can the vulkan surface be used as in input
71+ attachment?
72+ * @param forVulkanSecondaryCommandBuffer Will the surface be wrapping a vulkan secondary
73+ * command buffer via a GrVkSecondaryCBDrawContext? If
74+ * this is true then the following is required:
75+ * isTexureable = false
76+ * isMipMapped = false
77+ * willUseGLFBO0 = false
78+ * vkRTSupportsInputAttachment = false
6579 */
6680 SkSurfaceCharacterization createCharacterization (
6781 size_t cacheMaxResourceBytes,
@@ -74,7 +88,8 @@ class SK_API GrContextThreadSafeProxy final : public SkNVRefCnt<GrContextThreadS
7488 bool willUseGLFBO0 = false ,
7589 bool isTextureable = true ,
7690 GrProtected isProtected = GrProtected::kNo ,
77- bool vkRTSupportsInputAttachment = false );
91+ bool vkRTSupportsInputAttachment = false ,
92+ bool forVulkanSecondaryCommandBuffer = false );
7893
7994 /*
8095 * Retrieve the default GrBackendFormat for a given SkColorType and renderability.
0 commit comments