po: Update Lithuanian translation.
[wine.git] / include / d2d1_1.idl
blob3dd1530e296cdcb9ac68680d8b5c24823a3ded31
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 ID2D1Properties;
24 interface IPrintDocumentPackageTarget;
25 interface ID2D1PrintControl;
26 interface IWICImagingFactory;
27 interface IWICColorContext;
28 interface ID2D1ColorContext;
29 interface ID2D1Effect;
30 interface ID2D1BitmapBrush1;
32 cpp_quote("#ifndef __dwrite_h__")
33 /* already defined in dwrite.h but needed for WIDL */
34 typedef struct DWRITE_GLYPH_RUN_DESCRIPTION DWRITE_GLYPH_RUN_DESCRIPTION;
35 cpp_quote("#endif /* __dwrite_h__ */")
36 cpp_quote("#define D2D1_INVALID_PROPERTY_INDEX UINT_MAX")
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(62baa2d2-ab54-41b7-b872-787e0106a421),
355 local,
357 interface ID2D1PathGeometry1 : ID2D1PathGeometry
359 HRESULT ComputePointAndSegmentAtLength(
360 [in] float length,
361 [in] UINT32 start_segment,
362 [in, optional] const D2D1_MATRIX_3X2_F *transform,
363 [in] float tolerance,
364 [out] D2D1_POINT_DESCRIPTION *point_desc
369 object,
370 uuid(483473d7-cd46-4f9d-9d3a-3112aa80159d),
371 local,
373 interface ID2D1Properties : IUnknown
375 UINT32 GetPropertyCount();
376 HRESULT GetPropertyName(
377 [in] UINT32 index,
378 [out] WCHAR *name,
379 [in] UINT32 name_count
381 UINT32 GetPropertyNameLength(
382 [in] UINT32 index
384 D2D1_PROPERTY_TYPE GetType(
385 [in] UINT32 index
387 UINT32 GetPropertyIndex(
388 [in] const WCHAR *name
390 HRESULT SetValueByName(
391 [in] const WCHAR *name,
392 [in] D2D1_PROPERTY_TYPE type,
393 [in] const BYTE *value,
394 [in] UINT32 value_size
396 HRESULT SetValue(
397 [in] UINT32 index,
398 [in] D2D1_PROPERTY_TYPE type,
399 [in] const BYTE *value,
400 [in] UINT32 value_size
402 HRESULT GetValueByName(
403 [in] const WCHAR *name,
404 [in] D2D1_PROPERTY_TYPE type,
405 [out] BYTE *value,
406 [in] UINT32 value_size
408 HRESULT GetValue(
409 [in] UINT32 index,
410 [in] D2D1_PROPERTY_TYPE type,
411 [out] BYTE *value,
412 [in] UINT32 value_size
414 UINT32 GetValueSize(
415 [in] UINT32 index
417 HRESULT GetSubProperties(
418 [in] UINT32 index,
419 [out] ID2D1Properties **props
424 object,
425 uuid(28211a43-7d89-476f-8181-2d6159b220ad),
426 local,
428 interface ID2D1Effect : ID2D1Properties
430 void SetInput(
431 [in] UINT32 index,
432 [in] ID2D1Image *input,
433 [in] BOOL invalidate
435 HRESULT SetInputCount(
436 [in] UINT32 count
438 void GetInput(
439 [in] UINT32 index,
440 [out] ID2D1Image **input
442 UINT32 GetInputCount();
443 void GetOutput(
444 [out] ID2D1Image **output
449 object,
450 uuid(689f1f85-c72e-4e33-8f19-85754efd5ace),
451 local,
453 interface ID2D1DrawingStateBlock1 : ID2D1DrawingStateBlock
455 void GetDescription(
456 [out] D2D1_DRAWING_STATE_DESCRIPTION1 *desc
458 void SetDescription(
459 [in] const D2D1_DRAWING_STATE_DESCRIPTION1 *desc
464 object,
465 uuid(1c4820bb-5771-4518-a581-2fe4dd0ec657),
466 local,
468 interface ID2D1ColorContext : ID2D1Resource
470 D2D1_COLOR_SPACE GetColorSpace();
471 UINT32 GetProfileSize();
472 HRESULT GetProfile(
473 [out] BYTE *profile,
474 [in] UINT32 size
479 object,
480 uuid(a898a84c-3873-4588-b08b-ebbf978df041),
481 local,
483 interface ID2D1Bitmap1 : ID2D1Bitmap
485 void GetColorContext(
486 [out] ID2D1ColorContext **context
488 D2D1_BITMAP_OPTIONS GetOptions();
489 HRESULT GetSurface(
490 [out] IDXGISurface **surface
492 HRESULT Map(
493 [in] D2D1_MAP_OPTIONS options,
494 [out] D2D1_MAPPED_RECT *mapped_rect
496 HRESULT Unmap();
500 object,
501 uuid(41343a53-e41a-49a2-91cd-21793bbb62e5),
502 local,
504 interface ID2D1BitmapBrush1 : ID2D1BitmapBrush
506 void SetInterpolationMode1(
507 [in] D2D1_INTERPOLATION_MODE mode
509 D2D1_INTERPOLATION_MODE GetInterpolationMode1();
513 object,
514 uuid(ae1572f4-5dd0-4777-998b-9279472ae63b),
515 local,
517 interface ID2D1GradientStopCollection1 : ID2D1GradientStopCollection
519 void GetGradientStops1(
520 [out] D2D1_GRADIENT_STOP *gradient,
521 [in] UINT32 count
523 D2D1_COLOR_SPACE GetPreInterpolationSpace();
524 D2D1_COLOR_SPACE GetPostInterpolationSpace();
525 D2D1_BUFFER_PRECISION GetBufferPrecision();
526 D2D1_COLOR_INTERPOLATION_MODE GetColorInterpolationMode();
530 object,
531 uuid(47dd575d-ac05-4cdd-8049-9b02cd16f44c),
532 local,
534 interface ID2D1Device : ID2D1Resource
536 HRESULT CreateDeviceContext(
537 [in] D2D1_DEVICE_CONTEXT_OPTIONS options,
538 [out] ID2D1DeviceContext **context
540 HRESULT CreatePrintControl(
541 [in] IWICImagingFactory *wic_factory,
542 [in] IPrintDocumentPackageTarget *document_target,
543 [in] const D2D1_PRINT_CONTROL_PROPERTIES *desc,
544 [out] ID2D1PrintControl **print_control
546 void SetMaximumTextureMemory(
547 [in] UINT64 max_texture_memory
549 UINT64 GetMaximumTextureMemory();
550 HRESULT ClearResources(
551 [in, defaultvalue(0)] UINT msec_since_use
556 object,
557 uuid(54d7898a-a061-40a7-bec7-e465bcba2c4f),
558 local,
560 interface ID2D1CommandSink : IUnknown
562 HRESULT BeginDraw();
563 HRESULT EndDraw();
564 HRESULT SetAntialiasMode(
565 [in] D2D1_ANTIALIAS_MODE antialias_mode
567 HRESULT SetTags(
568 [in] D2D1_TAG tag1,
569 [in] D2D1_TAG tag2
571 HRESULT SetTextAntialiasMode(
572 [in] D2D1_TEXT_ANTIALIAS_MODE antialias_mode
574 HRESULT SetTextRenderingParams(
575 [in] IDWriteRenderingParams *text_rendering_params
577 HRESULT SetTransform(
578 [in] D2D1_MATRIX_3X2_F *transform
580 HRESULT SetPrimitiveBlend(
581 [in] D2D1_PRIMITIVE_BLEND primitive_blend
583 HRESULT SetUnitMode(
584 [in] D2D1_UNIT_MODE unit_mode
586 HRESULT Clear(
587 [in] const D2D1_COLOR_F *color
589 HRESULT DrawGlyphRun(
590 [in] D2D1_POINT_2F baseline_origin,
591 [in] const DWRITE_GLYPH_RUN *glyph_run,
592 [in] const DWRITE_GLYPH_RUN_DESCRIPTION *glyph_run_desc,
593 [in] ID2D1Brush *brush,
594 [in] DWRITE_MEASURING_MODE measuring_mode
596 HRESULT DrawLine(
597 [in] D2D1_POINT_2F p0,
598 [in] D2D1_POINT_2F p1,
599 [in] ID2D1Brush *brush,
600 [in] float stroke_width,
601 [in] ID2D1StrokeStyle *stroke_style
603 HRESULT DrawGeometry(
604 [in] ID2D1Geometry *geometry,
605 [in] ID2D1Brush *brush,
606 [in] float stroke_width,
607 [in] ID2D1StrokeStyle *stroke_style
609 HRESULT DrawRectangle(
610 [in] const D2D1_RECT_F *rect,
611 [in] ID2D1Brush *brush,
612 [in] float stroke_width,
613 [in] ID2D1StrokeStyle *stroke_style
615 HRESULT DrawBitmap(
616 [in] ID2D1Bitmap *bitmap,
617 [in] const D2D1_RECT_F *dst_rect,
618 [in] float opacity,
619 [in] D2D1_INTERPOLATION_MODE interpolation_mode,
620 [in] const D2D1_RECT_F *src_rect,
621 [in] const D2D1_MATRIX_4X4_F *perspective_transform
623 HRESULT DrawImage(
624 [in] ID2D1Image *image,
625 [in] const D2D1_POINT_2F *target_offset,
626 [in] const D2D1_POINT_2F *image_rect,
627 [in] D2D1_INTERPOLATION_MODE interpolation_mode,
628 [in] D2D1_COMPOSITE_MODE composite_mode
630 HRESULT DrawGdiMetafile(
631 [in] ID2D1GdiMetafile *metafile,
632 [in] const D2D1_POINT_2F *target_offset
634 HRESULT FillMesh(
635 [in] ID2D1Mesh *mesh,
636 [in] ID2D1Brush *brush
638 HRESULT FillOpacityMask(
639 [in] ID2D1Bitmap *bitmap,
640 [in] ID2D1Brush *brush,
641 [in] const D2D1_RECT_F *dst_rect,
642 [in] const D2D1_RECT_F *src_rect
644 HRESULT FillGeometry(
645 [in] ID2D1Geometry *geometry,
646 [in] ID2D1Brush *brush,
647 [in] ID2D1Brush *opacity_brush
649 HRESULT FillRectangle(
650 [in] const D2D1_RECT_F *rect,
651 [in] ID2D1Brush *brush
653 HRESULT PushAxisAlignedClip(
654 [in] const D2D1_RECT_F *clip_rect,
655 [in] D2D1_ANTIALIAS_MODE antialias_mode
657 HRESULT PushLayer(
658 [in] const D2D1_LAYER_PARAMETERS1 *layer_parameters,
659 [in] ID2D1Layer *layer
661 HRESULT PopAxisAlignedClip();
662 HRESULT PopLayer();
666 object,
667 uuid(b4f34a19-2383-4d76-94f6-ec343657c3dc),
668 local,
670 interface ID2D1CommandList : ID2D1Image
672 HRESULT Stream(
673 [in] ID2D1CommandSink *sink
675 HRESULT Close();
679 object,
680 uuid(2c1d867d-c290-41c8-ae7e-34a98702e9a5),
681 local,
683 interface ID2D1PrintControl : IUnknown
685 HRESULT AddPage(
686 [in] ID2D1CommandList *list,
687 [in] D2D_SIZE_F size,
688 [in, optional] IStream *stream,
689 [out, optional] D2D1_TAG *tag1,
690 [out, optional] D2D1_TAG *tag2
692 HRESULT Close();
696 object,
697 uuid(fe9e984d-3f95-407c-b5db-cb94d4e8f87c),
698 local,
700 interface ID2D1ImageBrush : ID2D1Brush
702 void SetImage(
703 [in] ID2D1Image *image
705 void SetExtendModeX(
706 [in] D2D1_EXTEND_MODE extend_mode
708 void SetExtendModeY(
709 [in] D2D1_EXTEND_MODE extend_mode
711 void SetInterpolationMode(
712 [in] D2D1_INTERPOLATION_MODE interpolation_mode
714 void SetSourceRectangle(
715 [in] const D2D1_RECT_F *rect
717 void GetImage(
718 [out] ID2D1Image **image
720 D2D1_EXTEND_MODE GetExtendModeX();
721 D2D1_EXTEND_MODE GetExtendModeY();
722 D2D1_INTERPOLATION_MODE GetInterpolationMode();
723 void GetSourceRectangle(
724 [out] D2D1_RECT_F *rect
729 object,
730 uuid(e8f7fe7a-191c-466d-ad95-975678bda998),
731 local,
733 interface ID2D1DeviceContext : ID2D1RenderTarget
735 HRESULT CreateBitmap(
736 [in] D2D1_SIZE_U size,
737 [in] const void *src_data,
738 [in] UINT32 pitch,
739 [in] const D2D1_BITMAP_PROPERTIES1 *desc,
740 [out] ID2D1Bitmap1 **bitmap
742 HRESULT CreateBitmapFromWicBitmap(
743 [in] IWICBitmapSource *bitmap_source,
744 [in] const D2D1_BITMAP_PROPERTIES1 *desc,
745 [out] ID2D1Bitmap1 **bitmap
747 HRESULT CreateColorContext(
748 [in] D2D1_COLOR_SPACE space,
749 [in] const BYTE *profile,
750 [in] UINT32 profile_size,
751 [out] ID2D1ColorContext **color_context
753 HRESULT CreateColorContextFromFilename(
754 [in] const WCHAR *filename,
755 [out] ID2D1ColorContext **color_context
757 HRESULT CreateColorContextFromWicColorContext(
758 [in] IWICColorContext *wic_color_context,
759 [out] ID2D1ColorContext **color_context
761 HRESULT CreateBitmapFromDxgiSurface(
762 [in] IDXGISurface *surface,
763 [in] const D2D1_BITMAP_PROPERTIES1 *desc,
764 [out] ID2D1Bitmap1 **bitmap
766 HRESULT CreateEffect(
767 [in] REFCLSID effect_id,
768 [out] ID2D1Effect **effect
770 HRESULT CreateGradientStopCollection(
771 [in] const D2D1_GRADIENT_STOP *stops,
772 [in] UINT32 stop_count,
773 [in] D2D1_COLOR_SPACE preinterpolation_space,
774 [in] D2D1_COLOR_SPACE postinterpolation_space,
775 [in] D2D1_BUFFER_PRECISION buffer_precision,
776 [in] D2D1_EXTEND_MODE extend_mode,
777 [in] D2D1_COLOR_INTERPOLATION_MODE color_interpolation_mode,
778 [out] ID2D1GradientStopCollection1 **gradient
780 HRESULT CreateImageBrush(
781 [in] ID2D1Image *image,
782 [in] const D2D1_IMAGE_BRUSH_PROPERTIES *image_brush_desc,
783 [in] const D2D1_BRUSH_PROPERTIES *brush_desc,
784 [out] ID2D1ImageBrush **brush
786 HRESULT CreateBitmapBrush(
787 [in] ID2D1Bitmap *bitmap,
788 [in] const D2D1_BITMAP_BRUSH_PROPERTIES1 *bitmap_brush_desc,
789 [in] const D2D1_BRUSH_PROPERTIES *brush_desc,
790 [out] ID2D1BitmapBrush1 **bitmap_brush
792 HRESULT CreateCommandList(
793 [out] ID2D1CommandList **command_list
795 BOOL IsDxgiFormatSupported(
796 [in] DXGI_FORMAT format
798 BOOL IsBufferPrecisionSupported(
799 [in] D2D1_BUFFER_PRECISION buffer_precision
801 void GetImageLocalBounds(
802 [in] ID2D1Image *image,
803 [out] D2D1_RECT_F *local_bounds
805 HRESULT GetImageWorldBounds(
806 [in] ID2D1Image *image,
807 [out] D2D1_RECT_F *world_bounds
809 HRESULT GetGlyphRunWorldBounds(
810 [in] D2D1_POINT_2F baseline_origin,
811 [in] const DWRITE_GLYPH_RUN *glyph_run,
812 [in] DWRITE_MEASURING_MODE measuring_mode,
813 [out] D2D1_RECT_F *bounds
815 void GetDevice(
816 [out] ID2D1Device **device
818 void SetTarget(
819 [in] ID2D1Image *target
821 void GetTarget(
822 [out] ID2D1Image **target
824 void SetRenderingControls(
825 [in] const D2D1_RENDERING_CONTROLS *rendering_controls
827 void GetRenderingControls(
828 [out] D2D1_RENDERING_CONTROLS *rendering_controls
830 void SetPrimitiveBlend(
831 [in] D2D1_PRIMITIVE_BLEND primitive_blend
833 D2D1_PRIMITIVE_BLEND GetPrimitiveBlend();
834 void SetUnitMode(
835 [in] D2D1_UNIT_MODE unit_mode
837 D2D1_UNIT_MODE GetUnitMode();
838 void DrawGlyphRun(
839 [in] D2D1_POINT_2F baseline_origin,
840 [in] const DWRITE_GLYPH_RUN *glyph_run,
841 [in] const DWRITE_GLYPH_RUN_DESCRIPTION *glyph_run_desc,
842 [in] ID2D1Brush *brush,
843 [in] DWRITE_MEASURING_MODE measuring_mode
845 void DrawImage(
846 [in] ID2D1Image *image,
847 [in] const D2D1_POINT_2F *target_offset,
848 [in] const D2D1_RECT_F *image_rect,
849 [in] D2D1_INTERPOLATION_MODE interpolation_mode,
850 [in] D2D1_COMPOSITE_MODE composite_mode
852 void DrawGdiMetafile(
853 [in] ID2D1GdiMetafile *metafile,
854 [in] const D2D1_POINT_2F *target_offset
856 void DrawBitmap(
857 [in] ID2D1Bitmap *bitmap,
858 [in] const D2D1_RECT_F *dst_rect,
859 [in] float opacity,
860 [in] D2D1_INTERPOLATION_MODE interpolation_mode,
861 [in] const D2D1_RECT_F *src_rect,
862 [in] const D2D1_MATRIX_4X4_F *perspective_transform
864 void PushLayer(
865 [in] const D2D1_LAYER_PARAMETERS1 *layer_parameters,
866 [in] ID2D1Layer *layer
868 HRESULT InvalidateEffectInputRectangle(
869 [in] ID2D1Effect *effect,
870 [in] UINT32 input,
871 [in] const D2D1_RECT_F *input_rect
873 HRESULT GetEffectInvalidRectangleCount(
874 [in] ID2D1Effect *effect,
875 [out] UINT32 *rect_count
877 HRESULT GetEffectInvalidRectangles(
878 [in] ID2D1Effect *effect,
879 [out] D2D1_RECT_F *rectangles,
880 [in] UINT32 rect_count
882 HRESULT GetEffectRequiredInputRectangles(
883 [in] ID2D1Effect *effect,
884 [in] const D2D1_RECT_F *image_rect,
885 [in] const D2D1_EFFECT_INPUT_DESCRIPTION *desc,
886 [out] D2D1_RECT_F *input_rect,
887 [in] UINT32 input_count
889 void FillOpacityMask(
890 [in] ID2D1Bitmap *mask,
891 [in] ID2D1Brush *brush,
892 [in] const D2D1_RECT_F *dst_rect,
893 [in] const D2D1_RECT_F *src_rect
898 object,
899 uuid(10a72a66-e91c-43f4-993f-ddf4b82b0b4a),
900 local,
902 interface ID2D1StrokeStyle1 : ID2D1StrokeStyle
904 D2D1_STROKE_TRANSFORM_TYPE GetStrokeTransformType();
908 object,
909 uuid(bb12d362-daee-4b9a-aa1d-14ba401cfa1f),
910 local,
912 interface ID2D1Factory1 : ID2D1Factory
914 HRESULT CreateDevice(
915 [in] IDXGIDevice *dxgi_device,
916 [out] ID2D1Device **device
918 HRESULT CreateStrokeStyle(
919 [in] const D2D1_STROKE_STYLE_PROPERTIES1 *desc,
920 [in, size_is(dash_count)] const float *dashes,
921 [in] UINT32 dash_count,
922 [out] ID2D1StrokeStyle1 **stroke_style
924 HRESULT CreatePathGeometry(
925 [out] ID2D1PathGeometry1 **geometry
927 HRESULT CreateDrawingStateBlock(
928 [in] const D2D1_DRAWING_STATE_DESCRIPTION1 *desc,
929 [in] IDWriteRenderingParams *text_rendering_params,
930 [out] ID2D1DrawingStateBlock1 **state_block
932 HRESULT CreateGdiMetafile(
933 [in] IStream *stream,
934 [out] ID2D1GdiMetafile **metafile
936 HRESULT RegisterEffectFromStream(
937 [in] REFCLSID effect_id,
938 [in] IStream *property_xml,
939 [in, size_is(binding_count)] const D2D1_PROPERTY_BINDING *bindings,
940 [in] UINT32 binding_count,
941 [in] PD2D1_EFFECT_FACTORY effect_factory
943 HRESULT RegisterEffectFromString(
944 [in] REFCLSID effect_id,
945 [in] const WCHAR *property_xml,
946 [in, size_is(binding_count)] const D2D1_PROPERTY_BINDING *bindings,
947 [in] UINT32 binding_count,
948 [in] PD2D1_EFFECT_FACTORY effect_factory
950 HRESULT UnregisterEffect(
951 [in] REFCLSID effect_id
953 HRESULT GetRegisteredEffects(
954 [out, size_is(effect_count)] CLSID *effects,
955 [in] UINT32 effect_count,
956 [out] UINT32 *returned,
957 [out] UINT32 *registered
959 HRESULT GetEffectProperties(
960 [in] REFCLSID effect_id,
961 [out] ID2D1Properties **props
966 object,
967 uuid(31e6e7bc-e0ff-4d46-8c64-a0a8c41c15d3),
968 local,
970 interface ID2D1Multithread : IUnknown
972 BOOL GetMultithreadProtected();
973 void Enter();
974 void Leave();
977 [local] HRESULT __stdcall D2D1CreateDevice(IDXGIDevice *dxgi_device,
978 const D2D1_CREATION_PROPERTIES *creation_properties, ID2D1Device **device);
979 [local] void __stdcall D2D1SinCos(float angle, float *s, float *c);
980 [local] float __stdcall D2D1Tan(float angle);
981 [local] float __stdcall D2D1Vec3Length(float x, float y, float z);
982 [local] D2D1_COLOR_F __stdcall D2D1ConvertColorSpace(D2D1_COLOR_SPACE src_colour_space,
983 D2D1_COLOR_SPACE dst_colour_space, const D2D1_COLOR_F *colour);