dinput8/tests: Fix inverted winetest_win_skip condition.
[wine.git] / include / d2d1_1.idl
blobfdec8ae5f9cf424e8d14bd89f6372397a321895c
1 /*
2 * Copyright 2017 Lucian Poston
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 import "d2d1.idl";
20 import "d2d1effects.idl";
22 interface ID2D1DeviceContext;
23 interface ID2D1PathGeometry1;
24 interface ID2D1Properties;
25 interface IPrintDocumentPackageTarget;
26 interface ID2D1PrintControl;
27 interface IWICImagingFactory;
28 interface IWICColorContext;
29 interface ID2D1ColorContext;
30 interface ID2D1Effect;
31 interface ID2D1BitmapBrush1;
33 cpp_quote("#ifndef __dwrite_h__")
34 /* already defined in dwrite.h but needed for WIDL */
35 typedef struct DWRITE_GLYPH_RUN_DESCRIPTION DWRITE_GLYPH_RUN_DESCRIPTION;
36 cpp_quote("#endif /* __dwrite_h__ */")
38 typedef enum D2D1_DEVICE_CONTEXT_OPTIONS
40 D2D1_DEVICE_CONTEXT_OPTIONS_NONE = 0x0,
41 D2D1_DEVICE_CONTEXT_OPTIONS_ENABLE_MULTITHREADED_OPTIMIZATIONS = 0x1,
42 D2D1_DEVICE_CONTEXT_OPTIONS_FORCE_DWORD = 0xffffffff,
43 } D2D1_DEVICE_CONTEXT_OPTIONS;
45 typedef enum D2D1_STROKE_TRANSFORM_TYPE
47 D2D1_STROKE_TRANSFORM_TYPE_NORMAL = 0x0,
48 D2D1_STROKE_TRANSFORM_TYPE_FIXED = 0x1,
49 D2D1_STROKE_TRANSFORM_TYPE_HAIRLINE = 0x2,
50 D2D1_STROKE_TRANSFORM_TYPE_FORCE_DWORD = 0xffffffff,
51 } D2D1_STROKE_TRANSFORM_TYPE;
53 typedef enum D2D1_PRIMITIVE_BLEND
55 D2D1_PRIMITIVE_BLEND_SOURCE_OVER = 0x0,
56 D2D1_PRIMITIVE_BLEND_COPY = 0x1,
57 D2D1_PRIMITIVE_BLEND_MIN = 0x2,
58 D2D1_PRIMITIVE_BLEND_ADD = 0x3,
59 D2D1_PRIMITIVE_BLEND_MAX = 0x4,
60 D2D1_PRIMITIVE_BLEND_FORCE_DWORD = 0xffffffff,
61 } D2D1_PRIMITIVE_BLEND;
63 typedef enum D2D1_UNIT_MODE
65 D2D1_UNIT_MODE_DIPS = 0x0,
66 D2D1_UNIT_MODE_PIXELS = 0x1,
67 D2D1_UNIT_MODE_FORCE_DWORD = 0xffffffff,
68 } D2D1_UNIT_MODE;
70 typedef enum D2D1_PRINT_FONT_SUBSET_MODE
72 D2D1_PRINT_FONT_SUBSET_MODE_DEFAULT = 0x0,
73 D2D1_PRINT_FONT_SUBSET_MODE_EACHPAGE = 0x1,
74 D2D1_PRINT_FONT_SUBSET_MODE_NONE = 0x2,
75 D2D1_PRINT_FONT_SUBSET_MODE_FORCE_DWORD = 0xffffffff,
76 } D2D1_PRINT_FONT_SUBSET_MODE;
78 typedef enum D2D1_COLOR_SPACE
80 D2D1_COLOR_SPACE_CUSTOM = 0x0,
81 D2D1_COLOR_SPACE_SRGB = 0x1,
82 D2D1_COLOR_SPACE_SCRGB = 0x2,
83 D2D1_COLOR_SPACE_FORCE_DWORD = 0xffffffff,
84 } D2D1_COLOR_SPACE;
86 typedef enum D2D1_BITMAP_OPTIONS
88 D2D1_BITMAP_OPTIONS_NONE = 0x0,
89 D2D1_BITMAP_OPTIONS_TARGET = 0x1,
90 D2D1_BITMAP_OPTIONS_CANNOT_DRAW = 0x2,
91 D2D1_BITMAP_OPTIONS_CPU_READ = 0x4,
92 D2D1_BITMAP_OPTIONS_GDI_COMPATIBLE = 0x8,
93 D2D1_BITMAP_OPTIONS_FORCE_DWORD = 0xffffffff,
94 } D2D1_BITMAP_OPTIONS;
96 typedef enum D2D1_MAP_OPTIONS
98 D2D1_MAP_OPTIONS_NONE = 0x0,
99 D2D1_MAP_OPTIONS_READ = 0x1,
100 D2D1_MAP_OPTIONS_WRITE = 0x2,
101 D2D1_MAP_OPTIONS_DISCARD = 0x4,
102 D2D1_MAP_OPTIONS_FORCE_DWORD = 0xffffffff,
103 } D2D1_MAP_OPTIONS;
105 typedef enum D2D1_BUFFER_PRECISION
107 D2D1_BUFFER_PRECISION_UNKNOWN = 0x0,
108 D2D1_BUFFER_PRECISION_8BPC_UNORM = 0x1,
109 D2D1_BUFFER_PRECISION_8BPC_UNORM_SRGB = 0x2,
110 D2D1_BUFFER_PRECISION_16BPC_UNORM = 0x3,
111 D2D1_BUFFER_PRECISION_16BPC_FLOAT = 0x4,
112 D2D1_BUFFER_PRECISION_32BPC_FLOAT = 0x5,
113 D2D1_BUFFER_PRECISION_FORCE_DWORD = 0xffffffff,
114 } D2D1_BUFFER_PRECISION;
116 typedef enum D2D1_COLOR_INTERPOLATION_MODE
118 D2D1_COLOR_INTERPOLATION_MODE_STRAIGHT = 0x0,
119 D2D1_COLOR_INTERPOLATION_MODE_PREMULTIPLIED = 0x1,
120 D2D1_COLOR_INTERPOLATION_MODE_FORCE_DWORD = 0xffffffff,
121 } D2D1_COLOR_INTERPOLATION_MODE;
123 typedef enum D2D1_INTERPOLATION_MODE
125 D2D1_INTERPOLATION_MODE_NEAREST_NEIGHBOR = D2D1_INTERPOLATION_MODE_DEFINITION_NEAREST_NEIGHBOR,
126 D2D1_INTERPOLATION_MODE_LINEAR = D2D1_INTERPOLATION_MODE_DEFINITION_LINEAR,
127 D2D1_INTERPOLATION_MODE_CUBIC = D2D1_INTERPOLATION_MODE_DEFINITION_CUBIC,
128 D2D1_INTERPOLATION_MODE_MULTI_SAMPLE_LINEAR = D2D1_INTERPOLATION_MODE_DEFINITION_MULTI_SAMPLE_LINEAR,
129 D2D1_INTERPOLATION_MODE_ANISOTROPIC = D2D1_INTERPOLATION_MODE_DEFINITION_ANISOTROPIC,
130 D2D1_INTERPOLATION_MODE_HIGH_QUALITY_CUBIC = D2D1_INTERPOLATION_MODE_DEFINITION_HIGH_QUALITY_CUBIC,
131 D2D1_INTERPOLATION_MODE_FORCE_DWORD = 0xffffffff,
132 } D2D1_INTERPOLATION_MODE;
134 typedef enum D2D1_COMPOSITE_MODE
136 D2D1_COMPOSITE_MODE_SOURCE_OVER = 0x0,
137 D2D1_COMPOSITE_MODE_DESTINATION_OVER = 0x1,
138 D2D1_COMPOSITE_MODE_SOURCE_IN = 0x2,
139 D2D1_COMPOSITE_MODE_DESTINATION_IN = 0x3,
140 D2D1_COMPOSITE_MODE_SOURCE_OUT = 0x4,
141 D2D1_COMPOSITE_MODE_DESTINATION_OUT = 0x5,
142 D2D1_COMPOSITE_MODE_SOURCE_ATOP = 0x6,
143 D2D1_COMPOSITE_MODE_DESTINATION_ATOP = 0x7,
144 D2D1_COMPOSITE_MODE_XOR = 0x8,
145 D2D1_COMPOSITE_MODE_PLUS = 0x9,
146 D2D1_COMPOSITE_MODE_SOURCE_COPY = 0xa,
147 D2D1_COMPOSITE_MODE_BOUNDED_SOURCE_COPY = 0xb,
148 D2D1_COMPOSITE_MODE_MASK_INVERT = 0xc,
149 D2D1_COMPOSITE_MODE_FORCE_DWORD = 0xffffffff,
150 } D2D1_COMPOSITE_MODE;
152 typedef enum D2D1_LAYER_OPTIONS1
154 D2D1_LAYER_OPTIONS1_NONE = 0x0,
155 D2D1_LAYER_OPTIONS1_INITIALIZE_FROM_BACKGROUND = 0x1,
156 D2D1_LAYER_OPTIONS1_IGNORE_ALPHA = 0x2,
157 D2D1_LAYER_OPTIONS1_FORCE_DWORD = 0xffffffff,
158 } D2D1_LAYER_OPTIONS1;
160 typedef struct D2D1_PROPERTY_BINDING D2D1_PROPERTY_BINDING;
161 typedef D2D_MATRIX_4X4_F D2D1_MATRIX_4X4_F;
163 typedef enum D2D1_PROPERTY_TYPE
165 D2D1_PROPERTY_TYPE_UNKNOWN = 0x0,
166 D2D1_PROPERTY_TYPE_STRING = 0x1,
167 D2D1_PROPERTY_TYPE_BOOL = 0x2,
168 D2D1_PROPERTY_TYPE_UINT32 = 0x3,
169 D2D1_PROPERTY_TYPE_INT32 = 0x4,
170 D2D1_PROPERTY_TYPE_FLOAT = 0x5,
171 D2D1_PROPERTY_TYPE_VECTOR2 = 0x6,
172 D2D1_PROPERTY_TYPE_VECTOR3 = 0x7,
173 D2D1_PROPERTY_TYPE_VECTOR4 = 0x8,
174 D2D1_PROPERTY_TYPE_BLOB = 0x9,
175 D2D1_PROPERTY_TYPE_IUNKNOWN = 0xa,
176 D2D1_PROPERTY_TYPE_ENUM = 0xb,
177 D2D1_PROPERTY_TYPE_ARRAY = 0xc,
178 D2D1_PROPERTY_TYPE_CLSID = 0xd,
179 D2D1_PROPERTY_TYPE_MATRIX_3X2 = 0xe,
180 D2D1_PROPERTY_TYPE_MATRIX_4X3 = 0xf,
181 D2D1_PROPERTY_TYPE_MATRIX_4X4 = 0x10,
182 D2D1_PROPERTY_TYPE_MATRIX_5X4 = 0x11,
183 D2D1_PROPERTY_TYPE_COLOR_CONTEXT = 0x12,
184 D2D1_PROPERTY_TYPE_FORCE_DWORD = 0xffffffff,
185 } D2D1_PROPERTY_TYPE;
187 typedef enum D2D1_PROPERTY
189 D2D1_PROPERTY_CLSID = 0x80000000,
190 D2D1_PROPERTY_DISPLAYNAME = 0x80000001,
191 D2D1_PROPERTY_AUTHOR = 0x80000002,
192 D2D1_PROPERTY_CATEGORY = 0x80000003,
193 D2D1_PROPERTY_DESCRIPTION = 0x80000004,
194 D2D1_PROPERTY_INPUTS = 0x80000005,
195 D2D1_PROPERTY_CACHED = 0x80000006,
196 D2D1_PROPERTY_PRECISION = 0x80000007,
197 D2D1_PROPERTY_MIN_INPUTS = 0x80000008,
198 D2D1_PROPERTY_MAX_INPUTS = 0x80000009,
199 D2D1_PROPERTY_FORCE_DWORD = 0xffffffff
200 } D2D1_PROPERTY;
202 typedef enum D2D1_SUBPROPERTY
204 D2D1_SUBPROPERTY_DISPLAYNAME = 0x80000000,
205 D2D1_SUBPROPERTY_ISREADONLY = 0x80000001,
206 D2D1_SUBPROPERTY_MIN = 0x80000002,
207 D2D1_SUBPROPERTY_MAX = 0x80000003,
208 D2D1_SUBPROPERTY_DEFAULT = 0x80000004,
209 D2D1_SUBPROPERTY_FIELDS = 0x80000005,
210 D2D1_SUBPROPERTY_INDEX = 0x80000006,
211 D2D1_SUBPROPERTY_FORCE_DWORD = 0xffffffff
212 } D2D1_SUBPROPERTY;
214 typedef enum D2D1_THREADING_MODE
216 D2D1_THREADING_MODE_SINGLE_THREADED = D2D1_FACTORY_TYPE_SINGLE_THREADED,
217 D2D1_THREADING_MODE_MULTI_THREADED = D2D1_FACTORY_TYPE_MULTI_THREADED,
218 D2D1_THREADING_MODE_FORCE_DWORD = 0xffffffff,
219 } D2D1_THREADING_MODE;
221 typedef struct D2D1_CREATION_PROPERTIES
223 D2D1_THREADING_MODE threadingMode;
224 D2D1_DEBUG_LEVEL debugLevel;
225 D2D1_DEVICE_CONTEXT_OPTIONS options;
226 } D2D1_CREATION_PROPERTIES;
228 typedef struct D2D1_STROKE_STYLE_PROPERTIES1
230 D2D1_CAP_STYLE startCap;
231 D2D1_CAP_STYLE endCap;
232 D2D1_CAP_STYLE dashCap;
233 D2D1_LINE_JOIN lineJoin;
234 float miterLimit;
235 D2D1_DASH_STYLE dashStyle;
236 float dashOffset;
237 D2D1_STROKE_TRANSFORM_TYPE transformType;
238 } D2D1_STROKE_STYLE_PROPERTIES1;
240 typedef struct D2D1_DRAWING_STATE_DESCRIPTION1
242 D2D1_ANTIALIAS_MODE antialiasMode;
243 D2D1_TEXT_ANTIALIAS_MODE textAntialiasMode;
244 D2D1_TAG tag1;
245 D2D1_TAG tag2;
246 D2D1_MATRIX_3X2_F transform;
247 D2D1_PRIMITIVE_BLEND primitiveBlend;
248 D2D1_UNIT_MODE unitMode;
249 } D2D1_DRAWING_STATE_DESCRIPTION1;
251 typedef struct D2D1_PRINT_CONTROL_PROPERTIES
253 D2D1_PRINT_FONT_SUBSET_MODE fontSubset;
254 float rasterDPI;
255 D2D1_COLOR_SPACE colorSpace;
256 } D2D1_PRINT_CONTROL_PROPERTIES;
258 typedef struct D2D1_MAPPED_RECT
260 UINT32 pitch;
261 BYTE *bits;
262 } D2D1_MAPPED_RECT;
264 typedef struct D2D1_BITMAP_PROPERTIES1
266 D2D1_PIXEL_FORMAT pixelFormat;
267 float dpiX;
268 float dpiY;
269 D2D1_BITMAP_OPTIONS bitmapOptions;
270 ID2D1ColorContext *colorContext;
271 } D2D1_BITMAP_PROPERTIES1;
273 typedef struct D2D1_IMAGE_BRUSH_PROPERTIES
275 D2D1_RECT_F sourceRectangle;
276 D2D1_EXTEND_MODE extendModeX;
277 D2D1_EXTEND_MODE extendModeY;
278 D2D1_INTERPOLATION_MODE interpolationMode;
279 } D2D1_IMAGE_BRUSH_PROPERTIES;
281 typedef struct D2D1_BITMAP_BRUSH_PROPERTIES1
283 D2D1_EXTEND_MODE extendModeX;
284 D2D1_EXTEND_MODE extendModeY;
285 D2D1_INTERPOLATION_MODE interpolationMode;
286 } D2D1_BITMAP_BRUSH_PROPERTIES1;
288 typedef struct D2D1_RENDERING_CONTROLS
290 D2D1_BUFFER_PRECISION bufferPrecision;
291 D2D1_SIZE_U tileSize;
292 } D2D1_RENDERING_CONTROLS;
294 typedef struct D2D1_LAYER_PARAMETERS1
296 D2D1_RECT_F contentBounds;
297 ID2D1Geometry *geometricMask;
298 D2D1_ANTIALIAS_MODE maskAntialiasMode;
299 D2D1_MATRIX_3X2_F maskTransform;
300 float opacity;
301 ID2D1Brush *opacityBrush;
302 D2D1_LAYER_OPTIONS1 layerOptions;
303 } D2D1_LAYER_PARAMETERS1;
305 typedef struct D2D1_EFFECT_INPUT_DESCRIPTION
307 ID2D1Effect *effect;
308 UINT32 inputIndex;
309 D2D1_RECT_F inputRectangle;
310 } D2D1_EFFECT_INPUT_DESCRIPTION;
312 typedef struct D2D1_POINT_DESCRIPTION
314 D2D1_POINT_2F point;
315 D2D1_POINT_2F unitTangentVector;
316 UINT32 endSegment;
317 UINT32 endFigure;
318 float lengthToEndSegment;
319 } D2D1_POINT_DESCRIPTION;
321 typedef HRESULT (__stdcall *PD2D1_EFFECT_FACTORY)(IUnknown **effect);
324 object,
325 uuid(82237326-8111-4f7c-bcf4-b5c1175564fe),
326 local,
328 interface ID2D1GdiMetafileSink : IUnknown
330 HRESULT ProcessRecord(
331 [in] DWORD type,
332 [in, optional] const void *data,
333 [in] DWORD size
338 object,
339 uuid(2f543dc3-cfc1-4211-864f-cfd91c6f3395),
340 local,
342 interface ID2D1GdiMetafile : ID2D1Resource
344 HRESULT Stream(
345 [in] ID2D1GdiMetafileSink *sink
347 HRESULT GetBounds(
348 [out] D2D1_RECT_F *bounds
353 object,
354 uuid(483473d7-cd46-4f9d-9d3a-3112aa80159d),
355 local,
357 interface ID2D1Properties : IUnknown
359 UINT32 GetPropertyCount();
360 HRESULT GetPropertyName(
361 [in] UINT32 index,
362 [out] WCHAR *name,
363 [in] UINT32 name_count
365 UINT32 GetPropertyNameLength(
366 [in] UINT32 index
368 D2D1_PROPERTY_TYPE GetType(
369 [in] UINT32 index
371 UINT32 GetPropertyIndex(
372 [in] const WCHAR *name
374 HRESULT SetValueByName(
375 [in] const WCHAR *name,
376 [in] D2D1_PROPERTY_TYPE type,
377 [in] const BYTE *value,
378 [in] UINT32 value_size
380 HRESULT SetValue(
381 [in] UINT32 index,
382 [in] D2D1_PROPERTY_TYPE type,
383 [in] const BYTE *value,
384 [in] UINT32 value_size
386 HRESULT GetValueByName(
387 [in] const WCHAR *name,
388 [in] D2D1_PROPERTY_TYPE type,
389 [out] BYTE *value,
390 [in] UINT32 value_size
392 HRESULT GetValue(
393 [in] UINT32 index,
394 [in] D2D1_PROPERTY_TYPE type,
395 [out] BYTE *value,
396 [in] UINT32 value_size
398 UINT32 GetValueSize(
399 [in] UINT32 index
401 HRESULT GetSubProperties(
402 [in] UINT32 index,
403 [out] ID2D1Properties **props
408 object,
409 uuid(28211a43-7d89-476f-8181-2d6159b220ad),
410 local,
412 interface ID2D1Effect : ID2D1Properties
414 void SetInput(
415 [in] UINT32 index,
416 [in] ID2D1Image *input,
417 [in] BOOL invalidate
419 HRESULT SetInputCount(
420 [in] UINT32 count
422 void GetInput(
423 [in] UINT32 index,
424 [out] ID2D1Image **input
426 UINT32 GetInputCount();
427 void GetOutput(
428 [out] ID2D1Image **output
433 object,
434 uuid(689f1f85-c72e-4e33-8f19-85754efd5ace),
435 local,
437 interface ID2D1DrawingStateBlock1 : ID2D1DrawingStateBlock
439 void GetDescription(
440 [out] D2D1_DRAWING_STATE_DESCRIPTION1 *desc
442 void SetDescription(
443 [in] const D2D1_DRAWING_STATE_DESCRIPTION1 *desc
448 object,
449 uuid(1c4820bb-5771-4518-a581-2fe4dd0ec657),
450 local,
452 interface ID2D1ColorContext : ID2D1Resource
454 D2D1_COLOR_SPACE GetColorSpace();
455 UINT32 GetProfileSize();
456 HRESULT GetProfile(
457 [out] BYTE *profile,
458 [in] UINT32 size
463 object,
464 uuid(a898a84c-3873-4588-b08b-ebbf978df041),
465 local,
467 interface ID2D1Bitmap1 : ID2D1Bitmap
469 void GetColorContext(
470 [out] ID2D1ColorContext **context
472 D2D1_BITMAP_OPTIONS GetOptions();
473 HRESULT GetSurface(
474 [out] IDXGISurface **surface
476 HRESULT Map(
477 [in] D2D1_MAP_OPTIONS options,
478 [out] D2D1_MAPPED_RECT *mapped_rect
480 HRESULT Unmap();
484 object,
485 uuid(41343a53-e41a-49a2-91cd-21793bbb62e5),
486 local,
488 interface ID2D1BitmapBrush1 : ID2D1BitmapBrush
490 void SetInterpolationMode1(
491 [in] D2D1_INTERPOLATION_MODE mode
493 D2D1_INTERPOLATION_MODE GetInterpolationMode1();
497 object,
498 uuid(ae1572f4-5dd0-4777-998b-9279472ae63b),
499 local,
501 interface ID2D1GradientStopCollection1 : ID2D1GradientStopCollection
503 void GetGradientStops1(
504 [out] D2D1_GRADIENT_STOP *gradient,
505 [in] UINT32 count
507 D2D1_COLOR_SPACE GetPreInterpolationSpace();
508 D2D1_COLOR_SPACE GetPostInterpolationSpace();
509 D2D1_BUFFER_PRECISION GetBufferPrecision();
510 D2D1_COLOR_INTERPOLATION_MODE GetColorInterpolationMode();
514 object,
515 uuid(47dd575d-ac05-4cdd-8049-9b02cd16f44c),
516 local,
518 interface ID2D1Device : ID2D1Resource
520 HRESULT CreateDeviceContext(
521 [in] D2D1_DEVICE_CONTEXT_OPTIONS options,
522 [out] ID2D1DeviceContext **context
524 HRESULT CreatePrintControl(
525 [in] IWICImagingFactory *wic_factory,
526 [in] IPrintDocumentPackageTarget *document_target,
527 [in] const D2D1_PRINT_CONTROL_PROPERTIES *desc,
528 [out] ID2D1PrintControl **print_control
530 void SetMaximumTextureMemory(
531 [in] UINT64 max_texture_memory
533 UINT64 GetMaximumTextureMemory();
534 HRESULT ClearResources(
535 [in, defaultvalue(0)] UINT msec_since_use
540 object,
541 uuid(54d7898a-a061-40a7-bec7-e465bcba2c4f),
542 local,
544 interface ID2D1CommandSink : IUnknown
546 HRESULT BeginDraw();
547 HRESULT EndDraw();
548 HRESULT SetAntialiasMode(
549 [in] D2D1_ANTIALIAS_MODE antialias_mode
551 HRESULT SetTags(
552 [in] D2D1_TAG tag1,
553 [in] D2D1_TAG tag2
555 HRESULT SetTextAntialiasMode(
556 [in] D2D1_TEXT_ANTIALIAS_MODE antialias_mode
558 HRESULT SetTextRenderingParams(
559 [in] IDWriteRenderingParams *text_rendering_params
561 HRESULT SetTransform(
562 [in] D2D1_MATRIX_3X2_F *transform
564 HRESULT SetPrimitiveBlend(
565 [in] D2D1_PRIMITIVE_BLEND primitive_blend
567 HRESULT SetUnitMode(
568 [in] D2D1_UNIT_MODE unit_mode
570 HRESULT Clear(
571 [in] const D2D1_COLOR_F *color
573 HRESULT DrawGlyphRun(
574 [in] D2D1_POINT_2F baseline_origin,
575 [in] const DWRITE_GLYPH_RUN *glyph_run,
576 [in] const DWRITE_GLYPH_RUN_DESCRIPTION *glyph_run_desc,
577 [in] ID2D1Brush *brush,
578 [in] DWRITE_MEASURING_MODE measuring_mode
580 HRESULT DrawLine(
581 [in] D2D1_POINT_2F p0,
582 [in] D2D1_POINT_2F p1,
583 [in] ID2D1Brush *brush,
584 [in] float stroke_width,
585 [in] ID2D1StrokeStyle *stroke_style
587 HRESULT DrawGeometry(
588 [in] ID2D1Geometry *geometry,
589 [in] ID2D1Brush *brush,
590 [in] float stroke_width,
591 [in] ID2D1StrokeStyle *stroke_style
593 HRESULT DrawRectangle(
594 [in] const D2D1_RECT_F *rect,
595 [in] ID2D1Brush *brush,
596 [in] float stroke_width,
597 [in] ID2D1StrokeStyle *stroke_style
599 HRESULT DrawBitmap(
600 [in] ID2D1Bitmap *bitmap,
601 [in] const D2D1_RECT_F *dst_rect,
602 [in] float opacity,
603 [in] D2D1_INTERPOLATION_MODE interpolation_mode,
604 [in] const D2D1_RECT_F *src_rect,
605 [in] const D2D1_MATRIX_4X4_F *perspective_transform
607 HRESULT DrawImage(
608 [in] ID2D1Image *image,
609 [in] const D2D1_POINT_2F *target_offset,
610 [in] const D2D1_POINT_2F *image_rect,
611 [in] D2D1_INTERPOLATION_MODE interpolation_mode,
612 [in] D2D1_COMPOSITE_MODE composite_mode
614 HRESULT DrawGdiMetafile(
615 [in] ID2D1GdiMetafile *metafile,
616 [in] const D2D1_POINT_2F *target_offset
618 HRESULT FillMesh(
619 [in] ID2D1Mesh *mesh,
620 [in] ID2D1Brush *brush
622 HRESULT FillOpacityMask(
623 [in] ID2D1Bitmap *bitmap,
624 [in] ID2D1Brush *brush,
625 [in] const D2D1_RECT_F *dst_rect,
626 [in] const D2D1_RECT_F *src_rect
628 HRESULT FillGeometry(
629 [in] ID2D1Geometry *geometry,
630 [in] ID2D1Brush *brush,
631 [in] ID2D1Brush *opacity_brush
633 HRESULT FillRectangle(
634 [in] const D2D1_RECT_F *rect,
635 [in] ID2D1Brush *brush
637 HRESULT PushAxisAlignedClip(
638 [in] const D2D1_RECT_F *clip_rect,
639 [in] D2D1_ANTIALIAS_MODE antialias_mode
641 HRESULT PushLayer(
642 [in] const D2D1_LAYER_PARAMETERS1 *layer_parameters,
643 [in] ID2D1Layer *layer
645 HRESULT PopAxisAlignedClip();
646 HRESULT PopLayer();
650 object,
651 uuid(b4f34a19-2383-4d76-94f6-ec343657c3dc),
652 local,
654 interface ID2D1CommandList : ID2D1Image
656 HRESULT Stream(
657 [in] ID2D1CommandSink *sink
659 HRESULT Close();
663 object,
664 uuid(2c1d867d-c290-41c8-ae7e-34a98702e9a5),
665 local,
667 interface ID2D1PrintControl : IUnknown
669 HRESULT AddPage(
670 [in] ID2D1CommandList *list,
671 [in] D2D_SIZE_F size,
672 [in, optional] IStream *stream,
673 [out, optional] D2D1_TAG *tag1,
674 [out, optional] D2D1_TAG *tag2
676 HRESULT Close();
680 object,
681 uuid(fe9e984d-3f95-407c-b5db-cb94d4e8f87c),
682 local,
684 interface ID2D1ImageBrush : ID2D1Brush
686 void SetImage(
687 [in] ID2D1Image *image
689 void SetExtendModeX(
690 [in] D2D1_EXTEND_MODE extend_mode
692 void SetExtendModeY(
693 [in] D2D1_EXTEND_MODE extend_mode
695 void SetInterpolationMode(
696 [in] D2D1_INTERPOLATION_MODE interpolation_mode
698 void SetSourceRectangle(
699 [in] const D2D1_RECT_F *rect
701 void GetImage(
702 [out] ID2D1Image **image
704 D2D1_EXTEND_MODE GetExtendModeX();
705 D2D1_EXTEND_MODE GetExtendModeY();
706 D2D1_INTERPOLATION_MODE GetInterpolationMode();
707 void GetSourceRectangle(
708 [out] D2D1_RECT_F *rect
713 object,
714 uuid(e8f7fe7a-191c-466d-ad95-975678bda998),
715 local,
717 interface ID2D1DeviceContext : ID2D1RenderTarget
719 HRESULT CreateBitmap(
720 [in] D2D1_SIZE_U size,
721 [in] const void *src_data,
722 [in] UINT32 pitch,
723 [in] const D2D1_BITMAP_PROPERTIES1 *desc,
724 [out] ID2D1Bitmap1 **bitmap
726 HRESULT CreateBitmapFromWicBitmap(
727 [in] IWICBitmapSource *bitmap_source,
728 [in] const D2D1_BITMAP_PROPERTIES1 *desc,
729 [out] ID2D1Bitmap1 **bitmap
731 HRESULT CreateColorContext(
732 [in] D2D1_COLOR_SPACE space,
733 [in] const BYTE *profile,
734 [in] UINT32 profile_size,
735 [out] ID2D1ColorContext **color_context
737 HRESULT CreateColorContextFromFilename(
738 [in] const WCHAR *filename,
739 [out] ID2D1ColorContext **color_context
741 HRESULT CreateColorContextFromWicColorContext(
742 [in] IWICColorContext *wic_color_context,
743 [out] ID2D1ColorContext **color_context
745 HRESULT CreateBitmapFromDxgiSurface(
746 [in] IDXGISurface *surface,
747 [in] const D2D1_BITMAP_PROPERTIES1 *desc,
748 [out] ID2D1Bitmap1 **bitmap
750 HRESULT CreateEffect(
751 [in] REFCLSID effect_id,
752 [out] ID2D1Effect **effect
754 HRESULT CreateGradientStopCollection(
755 [in] const D2D1_GRADIENT_STOP *stops,
756 [in] UINT32 stop_count,
757 [in] D2D1_COLOR_SPACE preinterpolation_space,
758 [in] D2D1_COLOR_SPACE postinterpolation_space,
759 [in] D2D1_BUFFER_PRECISION buffer_precision,
760 [in] D2D1_EXTEND_MODE extend_mode,
761 [in] D2D1_COLOR_INTERPOLATION_MODE color_interpolation_mode,
762 [out] ID2D1GradientStopCollection1 **gradient
764 HRESULT CreateImageBrush(
765 [in] ID2D1Image *image,
766 [in] const D2D1_IMAGE_BRUSH_PROPERTIES *image_brush_desc,
767 [in] const D2D1_BRUSH_PROPERTIES *brush_desc,
768 [out] ID2D1ImageBrush **brush
770 HRESULT CreateBitmapBrush(
771 [in] ID2D1Bitmap *bitmap,
772 [in] const D2D1_BITMAP_BRUSH_PROPERTIES1 *bitmap_brush_desc,
773 [in] const D2D1_BRUSH_PROPERTIES *brush_desc,
774 [out] ID2D1BitmapBrush1 **bitmap_brush
776 HRESULT CreateCommandList(
777 [out] ID2D1CommandList **command_list
779 BOOL IsDxgiFormatSupported(
780 [in] DXGI_FORMAT format
782 BOOL IsBufferPrecisionSupported(
783 [in] D2D1_BUFFER_PRECISION buffer_precision
785 void GetImageLocalBounds(
786 [in] ID2D1Image *image,
787 [out] D2D1_RECT_F *local_bounds
789 HRESULT GetImageWorldBounds(
790 [in] ID2D1Image *image,
791 [out] D2D1_RECT_F *world_bounds
793 HRESULT GetGlyphRunWorldBounds(
794 [in] D2D1_POINT_2F baseline_origin,
795 [in] const DWRITE_GLYPH_RUN *glyph_run,
796 [in] DWRITE_MEASURING_MODE measuring_mode,
797 [out] D2D1_RECT_F *bounds
799 void GetDevice(
800 [out] ID2D1Device **device
802 void SetTarget(
803 [in] ID2D1Image *target
805 void GetTarget(
806 [out] ID2D1Image **target
808 void SetRenderingControls(
809 [in] const D2D1_RENDERING_CONTROLS *rendering_controls
811 void GetRenderingControls(
812 [out] D2D1_RENDERING_CONTROLS *rendering_controls
814 void SetPrimitiveBlend(
815 [in] D2D1_PRIMITIVE_BLEND primitive_blend
817 D2D1_PRIMITIVE_BLEND GetPrimitiveBlend();
818 void SetUnitMode(
819 [in] D2D1_UNIT_MODE unit_mode
821 D2D1_UNIT_MODE GetUnitMode();
822 void DrawGlyphRun(
823 [in] D2D1_POINT_2F baseline_origin,
824 [in] const DWRITE_GLYPH_RUN *glyph_run,
825 [in] const DWRITE_GLYPH_RUN_DESCRIPTION *glyph_run_desc,
826 [in] ID2D1Brush *brush,
827 [in] DWRITE_MEASURING_MODE measuring_mode
829 void DrawImage(
830 [in] ID2D1Image *image,
831 [in] const D2D1_POINT_2F *target_offset,
832 [in] const D2D1_RECT_F *image_rect,
833 [in] D2D1_INTERPOLATION_MODE interpolation_mode,
834 [in] D2D1_COMPOSITE_MODE composite_mode
836 void DrawGdiMetafile(
837 [in] ID2D1GdiMetafile *metafile,
838 [in] const D2D1_POINT_2F *target_offset
840 void DrawBitmap(
841 [in] ID2D1Bitmap *bitmap,
842 [in] const D2D1_RECT_F *dst_rect,
843 [in] float opacity,
844 [in] D2D1_INTERPOLATION_MODE interpolation_mode,
845 [in] const D2D1_RECT_F *src_rect,
846 [in] const D2D1_MATRIX_4X4_F *perspective_transform
848 void PushLayer(
849 [in] const D2D1_LAYER_PARAMETERS1 *layer_parameters,
850 [in] ID2D1Layer *layer
852 HRESULT InvalidateEffectInputRectangle(
853 [in] ID2D1Effect *effect,
854 [in] UINT32 input,
855 [in] const D2D1_RECT_F *input_rect
857 HRESULT GetEffectInvalidRectangleCount(
858 [in] ID2D1Effect *effect,
859 [out] UINT32 *rect_count
861 HRESULT GetEffectInvalidRectangles(
862 [in] ID2D1Effect *effect,
863 [out] D2D1_RECT_F *rectangles,
864 [in] UINT32 rect_count
866 HRESULT GetEffectRequiredInputRectangles(
867 [in] ID2D1Effect *effect,
868 [in] const D2D1_RECT_F *image_rect,
869 [in] const D2D1_EFFECT_INPUT_DESCRIPTION *desc,
870 [out] D2D1_RECT_F *input_rect,
871 [in] UINT32 input_count
873 void FillOpacityMask(
874 [in] ID2D1Bitmap *mask,
875 [in] ID2D1Brush *brush,
876 [in] const D2D1_RECT_F *dst_rect,
877 [in] const D2D1_RECT_F *src_rect
882 object,
883 uuid(10a72a66-e91c-43f4-993f-ddf4b82b0b4a),
884 local,
886 interface ID2D1StrokeStyle1 : ID2D1StrokeStyle
888 D2D1_STROKE_TRANSFORM_TYPE GetStrokeTransformType();
892 object,
893 uuid(bb12d362-daee-4b9a-aa1d-14ba401cfa1f),
894 local,
896 interface ID2D1Factory1 : ID2D1Factory
898 HRESULT CreateDevice(
899 [in] IDXGIDevice *dxgi_device,
900 [out] ID2D1Device **device
902 HRESULT CreateStrokeStyle(
903 [in] const D2D1_STROKE_STYLE_PROPERTIES1 *desc,
904 [in, size_is(dash_count)] const float *dashes,
905 [in] UINT32 dash_count,
906 [out] ID2D1StrokeStyle1 **stroke_style
908 HRESULT CreatePathGeometry(
909 [out] ID2D1PathGeometry1 **geometry
911 HRESULT CreateDrawingStateBlock(
912 [in] const D2D1_DRAWING_STATE_DESCRIPTION1 *desc,
913 [in] IDWriteRenderingParams *text_rendering_params,
914 [out] ID2D1DrawingStateBlock1 **state_block
916 HRESULT CreateGdiMetafile(
917 [in] IStream *stream,
918 [out] ID2D1GdiMetafile **metafile
920 HRESULT RegisterEffectFromStream(
921 [in] REFCLSID effect_id,
922 [in] IStream *property_xml,
923 [in, size_is(binding_count)] const D2D1_PROPERTY_BINDING *bindings,
924 [in] UINT32 binding_count,
925 [in] PD2D1_EFFECT_FACTORY effect_factory
927 HRESULT RegisterEffectFromString(
928 [in] REFCLSID effect_id,
929 [in] const WCHAR *property_xml,
930 [in, size_is(binding_count)] const D2D1_PROPERTY_BINDING *bindings,
931 [in] UINT32 binding_count,
932 [in] PD2D1_EFFECT_FACTORY effect_factory
934 HRESULT UnregisterEffect(
935 [in] REFCLSID effect_id
937 HRESULT GetRegisteredEffects(
938 [out, size_is(effect_count)] CLSID *effects,
939 [in] UINT32 effect_count,
940 [out] UINT32 *returned,
941 [out] UINT32 *registered
943 HRESULT GetEffectProperties(
944 [in] REFCLSID effect_id,
945 [out] ID2D1Properties **props
950 object,
951 uuid(31e6e7bc-e0ff-4d46-8c64-a0a8c41c15d3),
952 local,
954 interface ID2D1Multithread : IUnknown
956 BOOL GetMultithreadProtected();
957 void Enter();
958 void Leave();
961 [local] HRESULT __stdcall D2D1CreateDevice(IDXGIDevice *dxgi_device,
962 const D2D1_CREATION_PROPERTIES *creation_properties, ID2D1Device **device);
963 [local] void __stdcall D2D1SinCos(float angle, float *s, float *c);
964 [local] float __stdcall D2D1Tan(float angle);
965 [local] float __stdcall D2D1Vec3Length(float x, float y, float z);
966 [local] D2D1_COLOR_F __stdcall D2D1ConvertColorSpace(D2D1_COLOR_SPACE src_colour_space,
967 D2D1_COLOR_SPACE dst_colour_space, const D2D1_COLOR_F *colour);