1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23#ifndef __com_sun_star_rendering_RenderState_idl__
24#define __com_sun_star_rendering_RenderState_idl__
25
26#ifndef __com_sun_star_geometry_AffineMatrix2D_idl__
27#include <com/sun/star/geometry/AffineMatrix2D.idl>
28#endif
29#ifndef __com_sun_star_rendering_XColorSpace_idl__
30#include <com/sun/star/rendering/XColorSpace.idl>
31#endif
32
33module com { module sun { module star { module rendering {
34
35published interface XPolyPolygon2D;
36
37/** This structure contains information passed to each
38    <type>XCanvas</type> render operation.<p>
39
40    This structure contains information considered as the render
41    state, i.e. the common setup required to render each individual
42    <type>XCanvas</type> primitive.<p>
43
44    @since OpenOffice 2.0
45 */
46published struct RenderState
47{
48    /** The affine transform associated with this render
49        operation.<p>
50
51        This is used to transform coordinates of canvas primitives
52        from user space to view space (from which they are
53        subsequently transformed to device space by the view
54        transform).<p>
55     */
56    ::com::sun::star::geometry::AffineMatrix2D	AffineTransform;
57
58    //-------------------------------------------------------------------------
59
60    /** The clipping area associated with this render operation.<p>
61
62        This clipping is interpreted in the user coordinate system,
63        i.e. subject to the render state transform followed by the
64        view transform before mapped to device coordinate space.<p>
65
66        Specifying an empty interface denotes no clipping,
67        i.e. everything rendered to the canvas will be visible
68        (subject to device-dependent constraints, of
69        course). Specifying an empty XPolyPolygon2D, i.e. a
70        poly-polygon containing zero polygons, or an XPolyPolygon2D
71        with any number of empty sub-polygons, denotes the NULL
72        clip. That means, nothing rendered to the canvas will be
73        visible.<p>
74     */
75    XPolyPolygon2D										Clip;
76
77    //-------------------------------------------------------------------------
78
79    /** The device color associated with this render operation.<p>
80
81        Note that this need not be RGB here, but depends on the active
82        device color space.<p>
83
84        @see XGraphicDevice
85        @see XColorSpace
86     */
87    sequence<ColorComponent>							DeviceColor;
88
89    //-------------------------------------------------------------------------
90
91    /** The composition mode associated with this render
92        operation.<p>
93
94        The composite mode determines in which way the primitive and
95        possibly existing background is combined. The permissible
96        values must be one out of the <type>CompositeOperation</type>
97        constants.<p>
98     */
99    byte												CompositeOperation;
100};
101
102}; }; }; };
103
104#endif
105