Lines Matching defs:pixels

104      * <p>Blurs the source pixels into the destination pixels. The force of the blur is specified by the radius which
105 * must be greater than 0.</p> <p>The source and destination pixels arrays are expected to be in the INT_ARGB
109 * @param srcPixels the source pixels
110 * @param dstPixels the destination pixels
166 * <p>Blurs the source pixels into the destination pixels. The force of the blur is specified by the radius which
167 * must be greater than 0.</p> <p>The source and destination pixels arrays are expected to be in the BYTE_GREY
171 * @param srcPixels the source pixels
172 * @param dstPixels the destination pixels
236 * <p>Returns an array of pixels, stored as integers, from a <code>BufferedImage</code>. The pixels are grabbed from
242 * @param x the x location at which to start grabbing pixels
243 * @param y the y location at which to start grabbing pixels
244 * @param w the width of the rectangle of pixels to grab
245 * @param h the height of the rectangle of pixels to grab
246 * @param pixels a pre-allocated array of pixels of size w*h; can be null
247 * @return <code>pixels</code> if non-null, a new array of integers otherwise
248 * @throws IllegalArgumentException is <code>pixels</code> is non-null and of length &lt; w*h
251 int x, int y, int w, int h, byte[] pixels) {
256 if (pixels == null) {
257 pixels = new byte[w * h];
258 } else if (pixels.length < w * h) {
259 throw new IllegalArgumentException("pixels array must have a length >= w*h");
265 return (byte[]) raster.getDataElements(x, y, w, h, pixels);
272 * <p>Writes a rectangular area of pixels in the destination <code>BufferedImage</code>. Calling this method on an
277 * @param x the x location at which to start storing pixels
278 * @param y the y location at which to start storing pixels
279 * @param w the width of the rectangle of pixels to store
280 * @param h the height of the rectangle of pixels to store
281 * @param pixels an array of pixels, stored as integers
282 * @throws IllegalArgumentException is <code>pixels</code> is non-null and of length &lt; w*h
285 int x, int y, int w, int h, byte[] pixels) {
286 if (pixels == null || w == 0 || h == 0) {
288 } else if (pixels.length < w * h) {
289 throw new IllegalArgumentException("pixels array must have a length >= w*h");
294 raster.setDataElements(x, y, w, h, pixels);
301 * <p>Returns an array of pixels, stored as integers, from a
302 * <code>BufferedImage</code>. The pixels are grabbed from a rectangular
308 * @param x the x location at which to start grabbing pixels
309 * @param y the y location at which to start grabbing pixels
310 * @param w the width of the rectangle of pixels to grab
311 * @param h the height of the rectangle of pixels to grab
312 * @param pixels a pre-allocated array of pixels of size w*h; can be null
313 * @return <code>pixels</code> if non-null, a new array of integers
315 * @throws IllegalArgumentException is <code>pixels</code> is non-null and
319 int x, int y, int w, int h, int[] pixels) {
324 if (pixels == null) {
325 pixels = new int[w * h];
326 } else if (pixels.length < w * h) {
327 throw new IllegalArgumentException("pixels array must have a length" +
335 return (int[]) raster.getDataElements(x, y, w, h, pixels);
339 return img.getRGB(x, y, w, h, pixels, 0, w);
343 * <p>Writes a rectangular area of pixels in the destination
349 * @param x the x location at which to start storing pixels
350 * @param y the y location at which to start storing pixels
351 * @param w the width of the rectangle of pixels to store
352 * @param h the height of the rectangle of pixels to store
353 * @param pixels an array of pixels, stored as integers
354 * @throws IllegalArgumentException is <code>pixels</code> is non-null and
358 int x, int y, int w, int h, int[] pixels) {
359 if (pixels == null || w == 0 || h == 0) {
361 } else if (pixels.length < w * h) {
362 throw new IllegalArgumentException("pixels array must have a length" +
370 raster.setDataElements(x, y, w, h, pixels);
373 img.setRGB(x, y, w, h, pixels, 0, w);