1 // Licensed under the Apache License, Version 2.0
2 // <LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
3 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your option.
4 // All files in the project carrying such notice may not be copied, modified, or distributed
5 // except according to those terms.
6 //! Mappings for the contents of d2d1_3.h
8 use shared
::basetsd
::{UINT16, UINT32, UINT64}
;
9 use shared
::dxgi
::{IDXGIDevice, IDXGISurface}
;
10 use shared
::dxgitype
::DXGI_COLOR_SPACE_TYPE
;
11 use shared
::minwindef
::{BOOL, BYTE, DWORD, FLOAT}
;
12 use shared
::ntdef
::WCHAR
;
13 use shared
::winerror
::HRESULT
;
15 D2D1_BITMAP_INTERPOLATION_MODE
, D2D1_COLOR_F
, D2D1_DRAW_TEXT_OPTIONS
, D2D1_GAMMA_1_0
,
16 D2D1_GAMMA_2_2
, D2D1_MATRIX_3X2_F
, D2D1_POINT_2F
, D2D1_RECT_F
, D2D1_RECT_U
, D2D1_SIZE_F
,
17 ID2D1Bitmap
, ID2D1Brush
, ID2D1Image
, ID2D1ImageVtbl
, ID2D1Resource
, ID2D1ResourceVtbl
,
18 ID2D1SimplifiedGeometrySink
,
21 D2D1_BUFFER_PRECISION
, D2D1_DEVICE_CONTEXT_OPTIONS
, D2D1_INTERPOLATION_MODE
,
22 D2D1_PRIMITIVE_BLEND
, ID2D1ColorContext
, ID2D1ColorContextVtbl
, ID2D1CommandList
,
23 ID2D1GdiMetafile
, ID2D1GdiMetafileSink
, ID2D1GdiMetafileSinkVtbl
, ID2D1GdiMetafileVtbl
,
26 ID2D1CommandSink1
, ID2D1CommandSink1Vtbl
, ID2D1Device1
, ID2D1Device1Vtbl
, ID2D1DeviceContext1
,
27 ID2D1DeviceContext1Vtbl
, ID2D1Factory2
, ID2D1Factory2Vtbl
,
29 use um
::d2d1effects
::D2D1_BLEND_MODE
;
30 use um
::d2d1svg
::ID2D1SvgDocument
;
31 use um
::dcommon
::{D2D1_ALPHA_MODE, DWRITE_GLYPH_IMAGE_FORMATS, DWRITE_MEASURING_MODE}
;
32 use um
::dwrite
::{DWRITE_GLYPH_RUN, IDWriteFontFace, IDWriteTextFormat, IDWriteTextLayout}
;
33 use um
::objidlbase
::IStream
;
34 use um
::wincodec
::IWICBitmapSource
;
35 ENUM
!{enum D2D1_INK_NIB_SHAPE
{
36 D2D1_INK_NIB_SHAPE_ROUND
= 0,
37 D2D1_INK_NIB_SHAPE_SQUARE
= 1,
39 ENUM
!{enum D2D1_ORIENTATION
{
40 D2D1_ORIENTATION_DEFAULT
= 1,
41 D2D1_ORIENTATION_FLIP_HORIZONTAL
= 2,
42 D2D1_ORIENTATION_ROTATE_CLOCKWISE180
= 3,
43 D2D1_ORIENTATION_ROTATE_CLOCKWISE180_FLIP_HORIZONTAL
= 4,
44 D2D1_ORIENTATION_ROTATE_CLOCKWISE90_FLIP_HORIZONTAL
= 5,
45 D2D1_ORIENTATION_ROTATE_CLOCKWISE270
= 6,
46 D2D1_ORIENTATION_ROTATE_CLOCKWISE270_FLIP_HORIZONTAL
= 7,
47 D2D1_ORIENTATION_ROTATE_CLOCKWISE90
= 8,
49 ENUM
!{enum D2D1_IMAGE_SOURCE_LOADING_OPTIONS
{
50 D2D1_IMAGE_SOURCE_LOADING_OPTIONS_NONE
= 0,
51 D2D1_IMAGE_SOURCE_LOADING_OPTIONS_RELEASE_SOURCE
= 1,
52 D2D1_IMAGE_SOURCE_LOADING_OPTIONS_CACHE_ON_DEMAND
= 2,
54 ENUM
!{enum D2D1_IMAGE_SOURCE_FROM_DXGI_OPTIONS
{
55 D2D1_IMAGE_SOURCE_FROM_DXGI_OPTIONS_NONE
= 0,
56 D2D1_IMAGE_SOURCE_FROM_DXGI_OPTIONS_LOW_QUALITY_PRIMARY_CONVERSION
= 1,
58 ENUM
!{enum D2D1_TRANSFORMED_IMAGE_SOURCE_OPTIONS
{
59 D2D1_TRANSFORMED_IMAGE_SOURCE_OPTIONS_NONE
= 0,
60 D2D1_TRANSFORMED_IMAGE_SOURCE_OPTIONS_DISABLE_DPI_SCALE
= 1,
62 STRUCT
!{struct D2D1_TRANSFORMED_IMAGE_SOURCE_PROPERTIES
{
63 orientation
: D2D1_ORIENTATION
,
66 interpolationMode
: D2D1_INTERPOLATION_MODE
,
67 options
: D2D1_TRANSFORMED_IMAGE_SOURCE_OPTIONS
,
69 STRUCT
!{struct D2D1_INK_POINT
{
74 STRUCT
!{struct D2D1_INK_BEZIER_SEGMENT
{
75 point1
: D2D1_INK_POINT
,
76 point2
: D2D1_INK_POINT
,
77 point3
: D2D1_INK_POINT
,
79 STRUCT
!{struct D2D1_INK_STYLE_PROPERTIES
{
80 nibShape
: D2D1_INK_NIB_SHAPE
,
81 nibTransform
: D2D1_MATRIX_3X2_F
,
83 ENUM
!{enum D2D1_PATCH_EDGE_MODE
{
84 D2D1_PATCH_EDGE_MODE_ALIASED
= 0,
85 D2D1_PATCH_EDGE_MODE_ANTIALIASED
= 1,
86 D2D1_PATCH_EDGE_MODE_ALIASED_INFLATED
= 2,
88 STRUCT
!{struct D2D1_GRADIENT_MESH_PATCH
{
89 point00
: D2D1_POINT_2F
,
90 point01
: D2D1_POINT_2F
,
91 point02
: D2D1_POINT_2F
,
92 point03
: D2D1_POINT_2F
,
93 point10
: D2D1_POINT_2F
,
94 point11
: D2D1_POINT_2F
,
95 point12
: D2D1_POINT_2F
,
96 point13
: D2D1_POINT_2F
,
97 point20
: D2D1_POINT_2F
,
98 point21
: D2D1_POINT_2F
,
99 point22
: D2D1_POINT_2F
,
100 point23
: D2D1_POINT_2F
,
101 point30
: D2D1_POINT_2F
,
102 point31
: D2D1_POINT_2F
,
103 point32
: D2D1_POINT_2F
,
104 point33
: D2D1_POINT_2F
,
105 color00
: D2D1_COLOR_F
,
106 color03
: D2D1_COLOR_F
,
107 color30
: D2D1_COLOR_F
,
108 color33
: D2D1_COLOR_F
,
109 topEdgeMode
: D2D1_PATCH_EDGE_MODE
,
110 leftEdgeMode
: D2D1_PATCH_EDGE_MODE
,
111 bottomEdgeMode
: D2D1_PATCH_EDGE_MODE
,
112 rightEdgeMode
: D2D1_PATCH_EDGE_MODE
,
114 ENUM
!{enum D2D1_SPRITE_OPTIONS
{
115 D2D1_SPRITE_OPTIONS_NONE
= 0,
116 D2D1_SPRITE_OPTIONS_CLAMP_TO_SOURCE_RECTANGLE
= 1,
118 ENUM
!{enum D2D1_COLOR_BITMAP_GLYPH_SNAP_OPTION
{
119 D2D1_COLOR_BITMAP_GLYPH_SNAP_OPTION_DEFAULT
= 0,
120 D2D1_COLOR_BITMAP_GLYPH_SNAP_OPTION_DISABLE
= 1,
122 ENUM
!{enum D2D1_GAMMA1
{
123 D2D1_GAMMA1_G22
= D2D1_GAMMA_2_2
,
124 D2D1_GAMMA1_G10
= D2D1_GAMMA_1_0
,
125 D2D1_GAMMA1_G2084
= 2,
127 STRUCT
!{struct D2D1_SIMPLE_COLOR_PROFILE
{
128 redPrimary
: D2D1_POINT_2F
,
129 greenPrimary
: D2D1_POINT_2F
,
130 bluePrimary
: D2D1_POINT_2F
,
131 whitePointXZ
: D2D1_POINT_2F
,
134 ENUM
!{enum D2D1_COLOR_CONTEXT_TYPE
{
135 D2D1_COLOR_CONTEXT_TYPE_ICC
= 0,
136 D2D1_COLOR_CONTEXT_TYPE_SIMPLE
= 1,
137 D2D1_COLOR_CONTEXT_TYPE_DXGI
= 2,
139 DEFINE_GUID
!{IID_ID2D1InkStyle
,
140 0xbae8b344, 0x23fc, 0x4071, 0x8c, 0xb5, 0xd0, 0x5d, 0x6f, 0x07, 0x38, 0x48}
141 DEFINE_GUID
!{IID_ID2D1Ink
,
142 0xb499923b, 0x7029, 0x478f, 0xa8, 0xb3, 0x43, 0x2c, 0x7c, 0x5f, 0x53, 0x12}
143 DEFINE_GUID
!{IID_ID2D1GradientMesh
,
144 0xf292e401, 0xc050, 0x4cde, 0x83, 0xd7, 0x04, 0x96, 0x2d, 0x3b, 0x23, 0xc2}
145 DEFINE_GUID
!{IID_ID2D1ImageSource
,
146 0xc9b664e5, 0x74a1, 0x4378, 0x9a, 0xc2, 0xee, 0xfc, 0x37, 0xa3, 0xf4, 0xd8}
147 DEFINE_GUID
!{IID_ID2D1ImageSourceFromWic
,
148 0x77395441, 0x1c8f, 0x4555, 0x86, 0x83, 0xf5, 0x0d, 0xab, 0x0f, 0xe7, 0x92}
149 DEFINE_GUID
!{IID_ID2D1TransformedImageSource
,
150 0x7f1f79e5, 0x2796, 0x416c, 0x8f, 0x55, 0x70, 0x0f, 0x91, 0x14, 0x45, 0xe5}
151 DEFINE_GUID
!{IID_ID2D1LookupTable3D
,
152 0x53dd9855, 0xa3b0, 0x4d5b, 0x82, 0xe1, 0x26, 0xe2, 0x5c, 0x5e, 0x57, 0x97}
153 DEFINE_GUID
!{IID_ID2D1DeviceContext2
,
154 0x394ea6a3, 0x0c34, 0x4321, 0x95, 0x0b, 0x6c, 0xa2, 0x0f, 0x0b, 0xe6, 0xc7}
155 DEFINE_GUID
!{IID_ID2D1Device2
,
156 0xa44472e1, 0x8dfb, 0x4e60, 0x84, 0x92, 0x6e, 0x28, 0x61, 0xc9, 0xca, 0x8b}
157 DEFINE_GUID
!{IID_ID2D1Factory3
,
158 0x0869759f, 0x4f00, 0x413f, 0xb0, 0x3e, 0x2b, 0xda, 0x45, 0x40, 0x4d, 0x0f}
159 DEFINE_GUID
!{IID_ID2D1CommandSink2
,
160 0x3bab440e, 0x417e, 0x47df, 0xa2, 0xe2, 0xbc, 0x0b, 0xe6, 0xa0, 0x09, 0x16}
161 DEFINE_GUID
!{IID_ID2D1GdiMetafile1
,
162 0x2e69f9e8, 0xdd3f, 0x4bf9, 0x95, 0xba, 0xc0, 0x4f, 0x49, 0xd7, 0x88, 0xdf}
163 DEFINE_GUID
!{IID_ID2D1GdiMetafileSink1
,
164 0xfd0ecb6b, 0x91e6, 0x411e, 0x86, 0x55, 0x39, 0x5e, 0x76, 0x0f, 0x91, 0xb4}
165 DEFINE_GUID
!{IID_ID2D1SpriteBatch
,
166 0x4dc583bf, 0x3a10, 0x438a, 0x87, 0x22, 0xe9, 0x76, 0x52, 0x24, 0xf1, 0xf1}
167 DEFINE_GUID
!{IID_ID2D1DeviceContext3
,
168 0x235a7496, 0x8351, 0x414c, 0xbc, 0xd4, 0x66, 0x72, 0xab, 0x2d, 0x8e, 0x00}
169 DEFINE_GUID
!{IID_ID2D1Device3
,
170 0x852f2087, 0x802c, 0x4037, 0xab, 0x60, 0xff, 0x2e, 0x7e, 0xe6, 0xfc, 0x01}
171 DEFINE_GUID
!{IID_ID2D1Factory4
,
172 0xbd4ec2d2, 0x0662, 0x4bee, 0xba, 0x8e, 0x6f, 0x29, 0xf0, 0x32, 0xe0, 0x96}
173 DEFINE_GUID
!{IID_ID2D1CommandSink3
,
174 0x18079135, 0x4cf3, 0x4868, 0xbc, 0x8e, 0x06, 0x06, 0x7e, 0x6d, 0x24, 0x2d}
175 DEFINE_GUID
!{IID_ID2D1SvgGlyphStyle
,
176 0xaf671749, 0xd241, 0x4db8, 0x8e, 0x41, 0xdc, 0xc2, 0xe5, 0xc1, 0xa4, 0x38}
177 DEFINE_GUID
!{IID_ID2D1DeviceContext4
,
178 0x8c427831, 0x3d90, 0x4476, 0xb6, 0x47, 0xc4, 0xfa, 0xe3, 0x49, 0xe4, 0xdb}
179 DEFINE_GUID
!{IID_ID2D1Device4
,
180 0xd7bdb159, 0x5683, 0x4a46, 0xbc, 0x9c, 0x72, 0xdc, 0x72, 0x0b, 0x85, 0x8b}
181 DEFINE_GUID
!{IID_ID2D1Factory5
,
182 0xc4349994, 0x838e, 0x4b0f, 0x8c, 0xab, 0x44, 0x99, 0x7d, 0x9e, 0xea, 0xcc}
183 DEFINE_GUID
!{IID_ID2D1CommandSink4
,
184 0xc78a6519, 0x40d6, 0x4218, 0xb2, 0xde, 0xbe, 0xee, 0xb7, 0x44, 0xbb, 0x3e}
185 DEFINE_GUID
!{IID_ID2D1ColorContext1
,
186 0x1ab42875, 0xc57f, 0x4be9, 0xbd, 0x85, 0x9c, 0xd7, 0x8d, 0x6f, 0x55, 0xee}
187 DEFINE_GUID
!{IID_ID2D1DeviceContext5
,
188 0x7836d248, 0x68cc, 0x4df6, 0xb9, 0xe8, 0xde, 0x99, 0x1b, 0xf6, 0x2e, 0xb7}
189 DEFINE_GUID
!{IID_ID2D1Device5
,
190 0xd55ba0a4, 0x6405, 0x4694, 0xae, 0xf5, 0x08, 0xee, 0x1a, 0x43, 0x58, 0xb4}
191 DEFINE_GUID
!{IID_ID2D1Factory6
,
192 0xf9976f46, 0xf642, 0x44c1, 0x97, 0xca, 0xda, 0x32, 0xea, 0x2a, 0x26, 0x35}
193 DEFINE_GUID
!{IID_ID2D1CommandSink5
,
194 0x7047dd26, 0xb1e7, 0x44a7, 0x95, 0x9a, 0x83, 0x49, 0xe2, 0x14, 0x4f, 0xa8}
195 DEFINE_GUID
!{IID_ID2D1DeviceContext6
,
196 0x985f7e37, 0x4ed0, 0x4a19, 0x98, 0xa3, 0x15, 0xb0, 0xed, 0xfd, 0xe3, 0x06}
197 DEFINE_GUID
!{IID_ID2D1Device6
,
198 0x7bfef914, 0x2d75, 0x4bad, 0xbe, 0x87, 0xe1, 0x8d, 0xdb, 0x07, 0x7b, 0x6d}
199 DEFINE_GUID
!{IID_ID2D1Factory7
,
200 0xbdc2bdd3, 0xb96c, 0x4de6, 0xbd, 0xf7, 0x99, 0xd4, 0x74, 0x54, 0x54, 0xde}
201 RIDL
!{#[uuid(0xbae8b344, 0x23fc, 0x4071, 0x8c, 0xb5, 0xd0, 0x5d, 0x6f, 0x07, 0x38, 0x48)]
202 interface
ID2D1InkStyle(ID2D1InkStyleVtbl
): ID2D1Resource(ID2D1ResourceVtbl
) {
204 transform
: *const D2D1_MATRIX_3X2_F
,
207 transform
: *mut D2D1_MATRIX_3X2_F
,
210 nibShape
: D2D1_INK_NIB_SHAPE
,
212 fn GetNibShape() -> D2D1_INK_NIB_SHAPE
,
214 RIDL
!{#[uuid(0xb499923b, 0x7029, 0x478f, 0xa8, 0xb3, 0x43, 0x2c, 0x7c, 0x5f, 0x53, 0x12)]
215 interface
ID2D1Ink(ID2D1InkVtbl
): ID2D1Resource(ID2D1ResourceVtbl
) {
217 startPoint
: *const D2D1_INK_POINT
,
219 fn GetStartPoint() -> D2D1_INK_POINT
,
221 segments
: *const D2D1_INK_BEZIER_SEGMENT
,
222 segmentsCount
: UINT32
,
224 fn RemoveSegmentsAtEnd(
225 segmentsCount
: UINT32
,
228 startSegment
: UINT32
,
229 segments
: *const D2D1_INK_BEZIER_SEGMENT
,
230 segmentsCount
: UINT32
,
233 segment
: *const D2D1_INK_BEZIER_SEGMENT
,
235 fn GetSegmentCount() -> UINT32
,
237 startSegment
: UINT32
,
238 segments
: *mut D2D1_INK_BEZIER_SEGMENT
,
239 segmentsCount
: UINT32
,
242 inkStyle
: *mut ID2D1InkStyle
,
243 worldTransform
: *const D2D1_MATRIX_3X2_F
,
244 flatteningTolerance
: FLOAT
,
245 geometrySink
: *mut ID2D1SimplifiedGeometrySink
,
248 inkStyle
: *mut ID2D1InkStyle
,
249 worldTransform
: *const D2D1_MATRIX_3X2_F
,
250 bounds
: *mut D2D1_RECT_F
,
253 RIDL
!{#[uuid(0xf292e401, 0xc050, 0x4cde, 0x83, 0xd7, 0x04, 0x96, 0x2d, 0x3b, 0x23, 0xc2)]
254 interface
ID2D1GradientMesh(ID2D1GradientMeshVtbl
): ID2D1Resource(ID2D1ResourceVtbl
) {
255 fn GetPatchCount() -> UINT32
,
258 patches
: *mut D2D1_GRADIENT_MESH_PATCH
,
259 patchesCount
: UINT32
,
262 RIDL
!{#[uuid(0xc9b664e5, 0x74a1, 0x4378, 0x9a, 0xc2, 0xee, 0xfc, 0x37, 0xa3, 0xf4, 0xd8)]
263 interface
ID2D1ImageSource(ID2D1ImageSourceVtbl
): ID2D1Image(ID2D1ImageVtbl
) {
264 fn OfferResources() -> HRESULT
,
265 fn TryReclaimResources(
266 resourcesDiscarded
: *mut BOOL
,
269 RIDL
!{#[uuid(0x77395441, 0x1c8f, 0x4555, 0x86, 0x83, 0xf5, 0x0d, 0xab, 0x0f, 0xe7, 0x92)]
270 interface
ID2D1ImageSourceFromWic(ID2D1ImageSourceFromWicVtbl
):
271 ID2D1ImageSource(ID2D1ImageSourceVtbl
) {
273 rectangleToFill
: *const D2D1_RECT_U
,
276 rectangleToPreserve
: *const D2D1_RECT_U
,
279 wicBitmapSource
: *mut *mut IWICBitmapSource
,
282 RIDL
!{#[uuid(0x7f1f79e5, 0x2796, 0x416c, 0x8f, 0x55, 0x70, 0x0f, 0x91, 0x14, 0x45, 0xe5)]
283 interface
ID2D1TransformedImageSource(ID2D1TransformedImageSourceVtbl
):
284 ID2D1Image(ID2D1ImageVtbl
) {
286 imageSource
: *mut *mut ID2D1ImageSource
,
289 properties
: *mut D2D1_TRANSFORMED_IMAGE_SOURCE_PROPERTIES
,
292 RIDL
!{#[uuid(0x53dd9855, 0xa3b0, 0x4d5b, 0x82, 0xe1, 0x26, 0xe2, 0x5c, 0x5e, 0x57, 0x97)]
293 interface
ID2D1LookupTable3D(ID2D1LookupTable3DVtbl
): ID2D1Resource(ID2D1ResourceVtbl
) {}
}
294 RIDL
!{#[uuid(0x394ea6a3, 0x0c34, 0x4321, 0x95, 0x0b, 0x6c, 0xa2, 0x0f, 0x0b, 0xe6, 0xc7)]
295 interface
ID2D1DeviceContext2(ID2D1DeviceContext2Vtbl
):
296 ID2D1DeviceContext1(ID2D1DeviceContext1Vtbl
) {
298 startPoint
: *const D2D1_INK_POINT
,
299 ink
: *mut *mut ID2D1Ink
,
302 inkStyleProperties
: *const D2D1_INK_STYLE_PROPERTIES
,
303 inkStyle
: *mut *mut ID2D1InkStyle
,
305 fn CreateGradientMesh(
306 patches
: *const D2D1_GRADIENT_MESH_PATCH
,
307 patchesCount
: UINT32
,
308 gradientMesh
: *mut *mut ID2D1GradientMesh
,
310 fn CreateImageSourceFromWic(
311 wicBitmapSource
: *mut IWICBitmapSource
,
312 loadingOptions
: D2D1_IMAGE_SOURCE_LOADING_OPTIONS
,
313 alphaMode
: D2D1_ALPHA_MODE
,
314 imageSource
: *mut *mut ID2D1ImageSourceFromWic
,
316 fn CreateLookupTable3D(
317 precision
: D2D1_BUFFER_PRECISION
,
318 extents
: *const UINT32
,
321 strides
: *const UINT32
,
322 lookupTable
: *mut *mut ID2D1LookupTable3D
,
324 fn CreateImageSourceFromDxgi(
325 surfaces
: *const *mut IDXGISurface
,
326 surfaceCount
: UINT32
,
327 colorSpace
: DXGI_COLOR_SPACE_TYPE
,
328 options
: D2D1_IMAGE_SOURCE_FROM_DXGI_OPTIONS
,
329 imageSource
: *mut *mut ID2D1ImageSource
,
331 fn GetGradientMeshWorldBounds(
332 gradientMesh
: *mut ID2D1GradientMesh
,
333 pBounds
: *mut D2D1_RECT_F
,
337 brush
: *mut ID2D1Brush
,
338 inkStyle
: *mut ID2D1InkStyle
,
341 gradientMesh
: *mut ID2D1GradientMesh
,
344 gdiMetafile
: *mut ID2D1GdiMetafile
,
345 destinationRectangle
: *const D2D1_RECT_F
,
346 sourceRectangle
: *const D2D1_RECT_F
,
348 fn CreateTransformedImageSource(
349 imageSource
: *mut ID2D1ImageSource
,
350 properties
: *const D2D1_TRANSFORMED_IMAGE_SOURCE_PROPERTIES
,
351 transformedImageSource
: *mut *mut ID2D1TransformedImageSource
,
354 RIDL
!{#[uuid(0xa44472e1, 0x8dfb, 0x4e60, 0x84, 0x92, 0x6e, 0x28, 0x61, 0xc9, 0xca, 0x8b)]
355 interface
ID2D1Device2(ID2D1Device2Vtbl
): ID2D1Device1(ID2D1Device1Vtbl
) {
356 fn CreateDeviceContext(
357 options
: D2D1_DEVICE_CONTEXT_OPTIONS
,
358 deviceContext2
: *mut *mut ID2D1DeviceContext2
,
360 fn FlushDeviceContexts(
361 bitmap
: *mut ID2D1Bitmap
,
364 dxgiDevice
: *mut *mut IDXGIDevice
,
367 RIDL
!{#[uuid(0x0869759f, 0x4f00, 0x413f, 0xb0, 0x3e, 0x2b, 0xda, 0x45, 0x40, 0x4d, 0x0f)]
368 interface
ID2D1Factory3(ID2D1Factory3Vtbl
): ID2D1Factory2(ID2D1Factory2Vtbl
) {
370 dxgiDevice
: *mut IDXGIDevice
,
371 d2dDevice2
: *mut *mut ID2D1Device2
,
374 RIDL
!{#[uuid(0x3bab440e, 0x417e, 0x47df, 0xa2, 0xe2, 0xbc, 0x0b, 0xe6, 0xa0, 0x09, 0x16)]
375 interface
ID2D1CommandSink2(ID2D1CommandSink2Vtbl
): ID2D1CommandSink1(ID2D1CommandSink1Vtbl
) {
378 brush
: *mut ID2D1Brush
,
379 inkStyle
: *mut ID2D1InkStyle
,
382 gradientMesh
: *mut ID2D1GradientMesh
,
385 gdiMetafile
: *mut ID2D1GdiMetafile
,
386 destinationRectangle
: *const D2D1_RECT_F
,
387 sourceRectangle
: *const D2D1_RECT_F
,
390 RIDL
!{#[uuid(0x2e69f9e8, 0xdd3f, 0x4bf9, 0x95, 0xba, 0xc0, 0x4f, 0x49, 0xd7, 0x88, 0xdf)]
391 interface
ID2D1GdiMetafile1(ID2D1GdiMetafile1Vtbl
): ID2D1GdiMetafile(ID2D1GdiMetafileVtbl
) {
397 bounds
: *mut D2D1_RECT_F
,
400 RIDL
!{#[uuid(0xfd0ecb6b, 0x91e6, 0x411e, 0x86, 0x55, 0x39, 0x5e, 0x76, 0x0f, 0x91, 0xb4)]
401 interface
ID2D1GdiMetafileSink1(ID2D1GdiMetafileSink1Vtbl
):
402 ID2D1GdiMetafileSink(ID2D1GdiMetafileSinkVtbl
) {
405 recordData
: *const c_void
,
406 recordDataSize
: DWORD
,
410 RIDL
!{#[uuid(0x4dc583bf, 0x3a10, 0x438a, 0x87, 0x22, 0xe9, 0x76, 0x52, 0x24, 0xf1, 0xf1)]
411 interface
ID2D1SpriteBatch(ID2D1SpriteBatchVtbl
): ID2D1Resource(ID2D1ResourceVtbl
) {
414 destinationRectangle
: *const D2D1_RECT_F
,
415 sourceRectangles
: *const D2D1_RECT_U
,
416 colors
: *const D2D1_COLOR_F
,
417 transforms
: *const D2D1_MATRIX_3X2_F
,
418 destinationRectanglesStride
: UINT32
,
419 sourceRectanglesStride
: UINT32
,
420 colorsStride
: UINT32
,
421 transformsStride
: D2D1_MATRIX_3X2_F
,
426 destinationRectangle
: *const D2D1_RECT_F
,
427 sourceRectangles
: *const D2D1_RECT_U
,
428 colors
: *const D2D1_COLOR_F
,
429 transforms
: *const D2D1_MATRIX_3X2_F
,
430 destinationRectanglesStride
: UINT32
,
431 sourceRectanglesStride
: UINT32
,
432 colorsStride
: UINT32
,
433 transformsStride
: D2D1_MATRIX_3X2_F
,
438 destinationRectangle
: *mut D2D1_RECT_F
,
439 sourceRectangles
: *mut D2D1_RECT_U
,
440 colors
: *mut D2D1_COLOR_F
,
441 transforms
: *mut D2D1_MATRIX_3X2_F
,
443 fn GetSpriteCount() -> UINT32
,
446 RIDL
!{#[uuid(0x235a7496, 0x8351, 0x414c, 0xbc, 0xd4, 0x66, 0x72, 0xab, 0x2d, 0x8e, 0x00)]
447 interface
ID2D1DeviceContext3(ID2D1DeviceContext3Vtbl
):
448 ID2D1DeviceContext2(ID2D1DeviceContext2Vtbl
) {
449 fn CreateSpriteBatch(
450 spriteBatch
: *mut *mut ID2D1SpriteBatch
,
453 spriteBatch
: *mut ID2D1SpriteBatch
,
456 bitmap
: *mut ID2D1Bitmap
,
457 interpolationMode
: D2D1_BITMAP_INTERPOLATION_MODE
,
458 spriteOptions
: D2D1_SPRITE_OPTIONS
,
461 RIDL
!{#[uuid(0x852f2087, 0x802c, 0x4037, 0xab, 0x60, 0xff, 0x2e, 0x7e, 0xe6, 0xfc, 0x01)]
462 interface
ID2D1Device3(ID2D1Device3Vtbl
): ID2D1Device2(ID2D1Device2Vtbl
) {
463 fn CreateDeviceContext(
464 options
: D2D1_DEVICE_CONTEXT_OPTIONS
,
465 deviceContext3
: *mut *mut ID2D1DeviceContext3
,
468 RIDL
!{#[uuid(0xbd4ec2d2, 0x0662, 0x4bee, 0xba, 0x8e, 0x6f, 0x29, 0xf0, 0x32, 0xe0, 0x96)]
469 interface
ID2D1Factory4(ID2D1Factory4Vtbl
): ID2D1Factory3(ID2D1Factory3Vtbl
) {
471 dxgiDevice
: *mut IDXGIDevice
,
472 d2dDevice3
: *mut *mut ID2D1Device3
,
475 RIDL
!{#[uuid(0x18079135, 0x4cf3, 0x4868, 0xbc, 0x8e, 0x06, 0x06, 0x7e, 0x6d, 0x24, 0x2d)]
476 interface
ID2D1CommandSink3(ID2D1CommandSink3Vtbl
): ID2D1CommandSink2(ID2D1CommandSink2Vtbl
) {
478 spriteBatch
: *mut ID2D1SpriteBatch
,
481 bitmap
: *mut ID2D1Bitmap
,
482 interpolationMode
: D2D1_BITMAP_INTERPOLATION_MODE
,
483 spriteOptions
: D2D1_SPRITE_OPTIONS
,
486 RIDL
!{#[uuid(0xaf671749, 0xd241, 0x4db8, 0x8e, 0x41, 0xdc, 0xc2, 0xe5, 0xc1, 0xa4, 0x38)]
487 interface
ID2D1SvgGlyphStyle(ID2D1SvgGlyphStyleVtbl
): ID2D1Resource(ID2D1ResourceVtbl
) {
489 brush
: *mut ID2D1Brush
,
492 brush
: *mut *mut ID2D1Brush
,
495 brush
: *mut ID2D1Brush
,
497 dashes
: *const FLOAT
,
501 fn GetStrokeDashesCount() -> UINT32
,
503 brush
: *mut *mut ID2D1Brush
,
504 strokeWidth
: *mut FLOAT
,
507 dashOffset
: *mut FLOAT
,
510 RIDL
!{#[uuid(0x8c427831, 0x3d90, 0x4476, 0xb6, 0x47, 0xc4, 0xfa, 0xe3, 0x49, 0xe4, 0xdb)]
511 interface
ID2D1DeviceContext4(ID2D1DeviceContext4Vtbl
):
512 ID2D1DeviceContext3(ID2D1DeviceContext3Vtbl
) {
513 fn CreateSvgGlyphStyle(
514 svgGlyphStyle
: *mut *mut ID2D1SvgGlyphStyle
,
517 string
: *const WCHAR
,
518 stringLength
: UINT32
,
519 textFormat
: *mut IDWriteTextFormat
,
520 layoutRect
: *const D2D1_RECT_F
,
521 defaultFillBrush
: *mut ID2D1Brush
,
522 svgGlyphStyle
: *mut ID2D1SvgGlyphStyle
,
523 colorPaletteIndex
: UINT32
,
524 options
: D2D1_DRAW_TEXT_OPTIONS
,
525 measuringMode
: DWRITE_MEASURING_MODE
,
528 origin
: D2D1_POINT_2F
,
529 textLayout
: *mut IDWriteTextLayout
,
530 defaultFillBrush
: *mut ID2D1Brush
,
531 svgGlyphStyle
: *mut ID2D1SvgGlyphStyle
,
532 colorPaletteIndex
: UINT32
,
533 options
: D2D1_DRAW_TEXT_OPTIONS
,
535 fn DrawColorBitmapGlyphRun(
536 glyphImageFormat
: DWRITE_GLYPH_IMAGE_FORMATS
,
537 baselineOrigin
: D2D1_POINT_2F
,
538 glyphRun
: *const DWRITE_GLYPH_RUN
,
539 measuringMode
: DWRITE_MEASURING_MODE
,
540 bitmapSnapOption
: D2D1_COLOR_BITMAP_GLYPH_SNAP_OPTION
,
543 baselineOrigin
: D2D1_POINT_2F
,
544 glyphRun
: *const DWRITE_GLYPH_RUN
,
545 defaultFillBrush
: *mut ID2D1Brush
,
546 svgGlyphStyle
: *mut ID2D1SvgGlyphStyle
,
547 colorPaletteIndex
: UINT32
,
548 measuringMode
: DWRITE_MEASURING_MODE
,
550 fn GetColorBitmapGlyphImage(
551 glyphImageFormat
: DWRITE_GLYPH_IMAGE_FORMATS
,
552 glyphOrigin
: D2D1_POINT_2F
,
553 fontFace
: *mut IDWriteFontFace
,
557 worldTransform
: *const D2D1_MATRIX_3X2_F
,
560 glyphTransform
: *mut D2D1_MATRIX_3X2_F
,
561 glyphImage
: *mut *mut ID2D1Image
,
564 glyphImageFormat
: DWRITE_GLYPH_IMAGE_FORMATS
,
565 glyphOrigin
: D2D1_POINT_2F
,
566 fontFace
: *mut IDWriteFontFace
,
570 worldTransform
: *const D2D1_MATRIX_3X2_F
,
571 defaultFillBrush
: *mut ID2D1Brush
,
572 svgGlyphStyle
: *mut ID2D1SvgGlyphStyle
,
573 colorPaletteIndex
: UINT32
,
574 glyphTransform
: *mut D2D1_MATRIX_3X2_F
,
575 glyphImage
: *mut *mut ID2D1CommandList
,
578 RIDL
!{#[uuid(0xd7bdb159, 0x5683, 0x4a46, 0xbc, 0x9c, 0x72, 0xdc, 0x72, 0x0b, 0x85, 0x8b)]
579 interface
ID2D1Device4(ID2D1Device4Vtbl
): ID2D1Device3(ID2D1Device3Vtbl
) {
580 fn CreateDeviceContext(
581 options
: D2D1_DEVICE_CONTEXT_OPTIONS
,
582 deviceContext4
: *mut *mut ID2D1DeviceContext4
,
584 fn SetMaximumColorGlyphCacheMemory(
585 maximumInBytes
: UINT64
,
587 fn GetMaximumColorGlyphCacheMemory() -> UINT64
,
589 RIDL
!{#[uuid(0xc4349994, 0x838e, 0x4b0f, 0x8c, 0xab, 0x44, 0x99, 0x7d, 0x9e, 0xea, 0xcc)]
590 interface
ID2D1Factory5(ID2D1Factory5Vtbl
): ID2D1Factory4(ID2D1Factory4Vtbl
) {
592 dxgiDevice
: *mut IDXGIDevice
,
593 d2dDevice4
: *mut *mut ID2D1Device4
,
596 RIDL
!{#[uuid(0xc78a6519, 0x40d6, 0x4218, 0xb2, 0xde, 0xbe, 0xee, 0xb7, 0x44, 0xbb, 0x3e)]
597 interface
ID2D1CommandSink4(ID2D1CommandSink4Vtbl
): ID2D1CommandSink3(ID2D1CommandSink3Vtbl
) {
598 fn SetPrimitiveBlend2(
599 primitiveBlend
: D2D1_PRIMITIVE_BLEND
,
602 RIDL
!{#[uuid(0x1ab42875, 0xc57f, 0x4be9, 0xbd, 0x85, 0x9c, 0xd7, 0x8d, 0x6f, 0x55, 0xee)]
603 interface
ID2D1ColorContext1(ID2D1ColorContext1Vtbl
): ID2D1ColorContext(ID2D1ColorContextVtbl
) {
604 fn GetColorContextType() -> D2D1_COLOR_CONTEXT_TYPE
,
605 fn GetDXGIColorSpace() -> DXGI_COLOR_SPACE_TYPE
,
606 fn GetSimpleColorProfile(
607 simpleProfile
: *mut D2D1_SIMPLE_COLOR_PROFILE
,
610 RIDL
!{#[uuid(0x7836d248, 0x68cc, 0x4df6, 0xb9, 0xe8, 0xde, 0x99, 0x1b, 0xf6, 0x2e, 0xb7)]
611 interface
ID2D1DeviceContext5(ID2D1DeviceContext5Vtbl
):
612 ID2D1DeviceContext4(ID2D1DeviceContext4Vtbl
) {
613 fn CreateSvgDocument(
614 inputXmlStream
: *mut IStream
,
615 viewportSize
: D2D1_SIZE_F
,
616 svgDocument
: *mut *mut ID2D1SvgDocument
,
619 svgDocument
: *mut ID2D1SvgDocument
,
621 fn CreateColorContextFromDxgiColorSpace(
622 colorSpace
: DXGI_COLOR_SPACE_TYPE
,
623 colorContext
: *mut *mut ID2D1ColorContext1
,
625 fn CreateColorContextFromSimpleColorProfile(
626 simpleProfile
: *const D2D1_SIMPLE_COLOR_PROFILE
,
627 colorContext
: *mut *mut ID2D1ColorContext1
,
630 RIDL
!{#[uuid(0xd55ba0a4, 0x6405, 0x4694, 0xae, 0xf5, 0x08, 0xee, 0x1a, 0x43, 0x58, 0xb4)]
631 interface
ID2D1Device5(ID2D1Device5Vtbl
): ID2D1Device4(ID2D1Device4Vtbl
) {
632 fn CreateDeviceContext(
633 options
: D2D1_DEVICE_CONTEXT_OPTIONS
,
634 deviceContext5
: *mut *mut ID2D1DeviceContext5
,
637 RIDL
!{#[uuid(0xf9976f46, 0xf642, 0x44c1, 0x97, 0xca, 0xda, 0x32, 0xea, 0x2a, 0x26, 0x35)]
638 interface
ID2D1Factory6(ID2D1Factory6Vtbl
): ID2D1Factory5(ID2D1Factory5Vtbl
) {
640 dxgiDevice
: *mut IDXGIDevice
,
641 d2dDevice5
: *mut *mut ID2D1Device5
,
644 RIDL
!{#[uuid(0x7047dd26, 0xb1e7, 0x44a7, 0x95, 0x9a, 0x83, 0x49, 0xe2, 0x14, 0x4f, 0xa8)]
645 interface
ID2D1CommandSink5(ID2D1CommandSink5Vtbl
): ID2D1CommandSink4(ID2D1CommandSink4Vtbl
) {
647 image
: *mut ID2D1Image
,
648 blendMode
: D2D1_BLEND_MODE
,
649 targetOffset
: *const D2D1_POINT_2F
,
650 imageRectangle
: *const D2D1_RECT_F
,
651 interpolationMode
: D2D1_INTERPOLATION_MODE
,
654 RIDL
!{#[uuid(0x985f7e37, 0x4ed0, 0x4a19, 0x98, 0xa3, 0x15, 0xb0, 0xed, 0xfd, 0xe3, 0x06)]
655 interface
ID2D1DeviceContext6(ID2D1DeviceContext6Vtbl
):
656 ID2D1DeviceContext5(ID2D1DeviceContext5Vtbl
) {
658 image
: *mut ID2D1Image
,
659 blendMode
: D2D1_BLEND_MODE
,
660 targetOffset
: *const D2D1_POINT_2F
,
661 imageRectangle
: *const D2D1_RECT_F
,
662 interpolationMode
: D2D1_INTERPOLATION_MODE
,
665 RIDL
!{#[uuid(0x7bfef914, 0x2d75, 0x4bad, 0xbe, 0x87, 0xe1, 0x8d, 0xdb, 0x07, 0x7b, 0x6d)]
666 interface
ID2D1Device6(ID2D1Device6Vtbl
): ID2D1Device5(ID2D1Device5Vtbl
) {
667 fn CreateDeviceContext(
668 options
: D2D1_DEVICE_CONTEXT_OPTIONS
,
669 deviceContext6
: *mut *mut ID2D1DeviceContext6
,
672 RIDL
!{#[uuid(0xbdc2bdd3, 0xb96c, 0x4de6, 0xbd, 0xf7, 0x99, 0xd4, 0x74, 0x54, 0x54, 0xde)]
673 interface
ID2D1Factory7(ID2D1Factory7Vtbl
): ID2D1Factory6(ID2D1Factory6Vtbl
) {
675 dxgiDevice
: *mut IDXGIDevice
,
676 d2dDevice6
: *mut *mut ID2D1Device6
,
680 pub fn D2D1GetGradientMeshInteriorPointsFromCoonsPatch(
681 pPoint0
: *const D2D1_POINT_2F
,
682 pPoint1
: *const D2D1_POINT_2F
,
683 pPoint2
: *const D2D1_POINT_2F
,
684 pPoint3
: *const D2D1_POINT_2F
,
685 pPoint4
: *const D2D1_POINT_2F
,
686 pPoint5
: *const D2D1_POINT_2F
,
687 pPoint6
: *const D2D1_POINT_2F
,
688 pPoint7
: *const D2D1_POINT_2F
,
689 pPoint8
: *const D2D1_POINT_2F
,
690 pPoint9
: *const D2D1_POINT_2F
,
691 pPoint10
: *const D2D1_POINT_2F
,
692 pPoint11
: *const D2D1_POINT_2F
,
693 pTensorPoint11
: *mut D2D1_POINT_2F
,
694 pTensorPoint12
: *mut D2D1_POINT_2F
,
695 pTensorPoint21
: *mut D2D1_POINT_2F
,
696 pTensorPoint22
: *mut D2D1_POINT_2F
,