Bump for 3.6-28
[LibreOffice.git] / offapi / com / sun / star / awt / XImageConsumer.idl
blobce967654eb7e6aa8db18d21e894e0ef1fde45aae
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * OpenOffice.org - a multi-platform office productivity suite
10 * This file is part of OpenOffice.org.
12 * OpenOffice.org is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 3
14 * only, as published by the Free Software Foundation.
16 * OpenOffice.org is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License version 3 for more details
20 * (a copy is included in the LICENSE file that accompanied this code).
22 * You should have received a copy of the GNU Lesser General Public License
23 * version 3 along with OpenOffice.org. If not, see
24 * <http://www.openoffice.org/license.html>
25 * for a copy of the LGPLv3 License.
27 ************************************************************************/
28 #ifndef __com_sun_star_awt_XImageConsumer_idl__
29 #define __com_sun_star_awt_XImageConsumer_idl__
31 #include <com/sun/star/uno/XInterface.idl>
33 //=============================================================================
35 module com { module sun { module star { module awt {
37 published interface XImageProducer;
39 //=============================================================================
41 /** specifies a data sink for an image.
43 <p>An image consumer is a component which wants to display or just
44 receive an image from an image producer.</p>
46 @see XImageProducer
48 published interface XImageConsumer: com::sun::star::uno::XInterface
50 //-------------------------------------------------------------------------
52 /** initializes the consumer with image dimensions.
54 [oneway] void init( [in] long Width,
55 [in] long Height );
57 //-------------------------------------------------------------------------
59 /** changes color model for next pixels
60 typically called once after initialization.
62 [oneway] void setColorModel( [in] short BitCount,
63 [in] sequence<long> RGBAPal,
64 [in] long RedMask,
65 [in] long GreenMask,
66 [in] long BlueMask,
67 [in] long AlphaMask );
69 //-------------------------------------------------------------------------
71 /** delivers a chunk of pixels as <atom>long</atom> values.
73 <p>The pixels of the image are delivered using one or more calls
74 to this method. Each call specifies the location and size of the
75 rectangle of source pixels that are contained in the array of pixels.
76 The specified color model object should be used to convert
77 the pixels into their corresponding color and alpha components. Pixel
78 (m,n) is stored in the pixels array at index (n * <var>nScanSize</var>
79 + m + nOffset).</p>
81 [oneway] void setPixelsByBytes( [in] long nX,
82 [in] long nY,
83 [in] long nWidth,
84 [in] long nHeight,
85 [in] sequence<byte> aProducerData,
86 [in] long nOffset,
87 [in] long nScanSize );
89 //-------------------------------------------------------------------------
91 /** delivers a chunk of pixels as <atom>byte</atom> values.
93 <p>The pixels of the image are delivered using one or more calls
94 to this method. Each call specifies the location and size of the
95 rectangle of source pixels that are contained in the array of pixels.
96 The specified color model object should be used to convert
97 the pixels into their corresponding color and alpha components. Pixel
98 (m,n) is stored in the pixels array at index (n * <var>nScanSize</var>
99 + m + nOffset).</p>
101 [oneway] void setPixelsByLongs( [in] long nX,
102 [in] long nY,
103 [in] long nWidth,
104 [in] long nHeight,
105 [in] sequence<long> aProducerData,
106 [in] long nOffset,
107 [in] long nScanSize );
109 //-------------------------------------------------------------------------
111 /** is called for the notification of the degree to which the
112 image is delivered.
114 <p>The complete method is called when the image producer
115 has finished delivering all of the pixels that the source image
116 contains, or when a single frame of a multi-frame animation has
117 been completed, or when an error in loading or producing the
118 image has occurred. The image consumer should remove itself from the
119 list of consumers registered with the image producer
120 at this time, unless it is interested in successive frames.</p>
122 [oneway] void complete( [in] long Status,
123 [in] XImageProducer xProducer );
127 //=============================================================================
129 }; }; }; };
131 #endif
133 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */