update dev300-m58
[ooovba.git] / offapi / com / sun / star / rendering / XIeeeFloatBitmap.idl
blob3abd9d1ceb106faf59adc89323f7d15825836d37
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: XIeeeFloatBitmap.idl,v $
10 * $Revision: 1.6 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef __com_sun_star_rendering_XIeeeFloatBitmap_idl__
31 #define __com_sun_star_rendering_XIeeeFloatBitmap_idl__
33 #ifndef __com_sun_star_lang_IllegalArgumentException_idl__
34 #include <com/sun/star/lang/IllegalArgumentException.idl>
35 #endif
36 #ifndef __com_sun_star_lang_IndexOutOfBoundsException_idl__
37 #include <com/sun/star/lang/IndexOutOfBoundsException.idl>
38 #endif
39 #ifndef __com_sun_star_rendering_FloatingPointBitmapLayout_idl__
40 #include <com/sun/star/rendering/FloatingPointBitmapLayout.idl>
41 #endif
42 #ifndef __com_sun_star_geometry_IntegerPoint2D_idl__
43 #include <com/sun/star/geometry/IntegerPoint2D.idl>
44 #endif
45 #ifndef __com_sun_star_geometry_IntegerRectangle2D_idl__
46 #include <com/sun/star/geometry/IntegerRectangle2D.idl>
47 #endif
48 #ifndef __com_sun_star_rendering_XIeeeFloatReadOnlyBitmap_idl__
49 #include <com/sun/star/rendering/XIeeeFloatReadOnlyBitmap.idl>
50 #endif
51 #ifndef __com_sun_star_rendering_VolatileContentDestroyedException_idl__
52 #include <com/sun/star/rendering/VolatileContentDestroyedException.idl>
53 #endif
56 module com { module sun { module star { module rendering {
58 /** Specialized interface for bitmaps containing IEEE floats as their
59 color components.<p>
61 interface XIeeeFloatBitmap : XIeeeFloatReadOnlyBitmap
63 //-------------------------------------------------------------------------
65 /** Set raw data of a bitmap.<p>
67 Set raw data of a bitmap, in the format as defined by
68 getMemoryLayout(). With the given rectangle, a subset of the
69 bitmap can be changed. When setting subsets of the bitmap, the
70 same scanline padding takes place as when the whole bitmap is
71 changed.<p>
73 When setting data on volatile bitmaps, always call isValid()
74 before, and retrieve a new memory layout via
75 getMemoryLayout(). At least under Windows, the memory layout
76 can change for the same bitmap, if the user e.g. switches the
77 screen resolution. Thus, this method will throw an
78 IllegalArgumentException, if the memory layout changed between
79 a call to getMemoryLayout() and setData().<p>
81 @param data
82 Data to set
84 @param bitmapLayout
85 Layout of the data to set. Must match this bitmap's current
86 layout.
88 @param rect
89 Destination rectangle, within the bounds of the bitmap, to set
90 the data in.
92 @throws <type>com::sun::star::lang::IndexOutOfBoundsException</type>
93 if parts of the given rectangle are outside the permissible
94 bitmap area.
96 @throws <type>com::sun::star::lang::IllegalArgumentException</type>
97 if the given memory layout does not match this bitmap's
98 layout, or if the given data sequence has too few or too much
99 elements.
101 void setData( [in] sequence<float> data, [in] FloatingPointBitmapLayout bitmapLayout, [in] ::com::sun::star::geometry::IntegerRectangle2D rect )
102 raises (com::sun::star::lang::IllegalArgumentException,
103 com::sun::star::lang::IndexOutOfBoundsException);
105 //-------------------------------------------------------------------------
107 /** Set a single pixel of the bitmap with the given color
108 value.<p>
110 When setting data on volatile bitmaps, always call isValid()
111 before, and retrieve a new memory layout via
112 getMemoryLayout(). At least under Windows, the memory layout
113 can change for the same bitmap, if the user e.g. switches the
114 screen resolution. Thus, this method will throw an
115 IllegalArgumentException, if the memory layout changed between
116 a call to getMemoryLayout() and setPixel().<p>
118 @param color
119 The color value(s) to set
121 @param bitmapLayout
122 Layout of the color elements to set. Must match this bitmap's
123 current layout.
125 @param pos
126 Pixel position with the bounds of the bitmap to set.
128 @throws <type>com::sun::star::lang::IndexOutOfBoundsException</type>
129 if the given point is outside the permissible bitmap area.
131 @throws <type>com::sun::star::lang::IllegalArgumentException</type>
132 if the given memory layout does not match this bitmap's
133 layout, or if the given data sequence has too few or too much
134 elements.
136 void setPixel( [in] sequence<float> color, [in] FloatingPointBitmapLayout bitmapLayout, [in] ::com::sun::star::geometry::IntegerPoint2D pos )
137 raises (com::sun::star::lang::IllegalArgumentException,
138 com::sun::star::lang::IndexOutOfBoundsException);
141 }; }; }; };
143 #endif