public class AverageDownSampleOps
extends java.lang.Object
Operations related to down sampling image by computing the average within square regions. The first square region is from (0,0) to (w-1,w-1), inclusive. Each square region after that is found by skipping over 'w' pixels in x and y directions. partial regions along the right and bottom borders are handled by computing the average with the rectangle defined by the intersection of the image and the square region.
NOTE: Errors are reduced in integer images by rounding instead of standard integer division.
| Constructor and Description |
|---|
AverageDownSampleOps() |
| Modifier and Type | Method and Description |
|---|---|
static void |
down(boofcv.struct.image.GrayF32 input,
int sampleWidth,
boofcv.struct.image.GrayF32 output)
Down samples the image.
|
static void |
down(boofcv.struct.image.GrayF64 input,
int sampleWidth,
boofcv.struct.image.GrayF64 output)
Down samples the image.
|
static void |
down(boofcv.struct.image.GrayS16 input,
int sampleWidth,
boofcv.struct.image.GrayI16 output)
Down samples the image.
|
static void |
down(boofcv.struct.image.GrayS32 input,
int sampleWidth,
boofcv.struct.image.GrayS32 output)
Down samples the image.
|
static void |
down(boofcv.struct.image.GrayS8 input,
int sampleWidth,
boofcv.struct.image.GrayI8 output)
Down samples the image.
|
static void |
down(boofcv.struct.image.GrayU16 input,
int sampleWidth,
boofcv.struct.image.GrayI16 output)
Down samples the image.
|
static void |
down(boofcv.struct.image.GrayU8 input,
int sampleWidth,
boofcv.struct.image.GrayI8 output)
Down samples the image.
|
static void |
down(boofcv.struct.image.ImageBase input,
int sampleWidth,
boofcv.struct.image.ImageBase output) |
static void |
down(boofcv.struct.image.ImageGray input,
int sampleWidth,
boofcv.struct.image.ImageGray output)
Down samples image.
|
static <T extends boofcv.struct.image.ImageGray<T>> |
down(boofcv.struct.image.Planar<T> input,
int sampleWidth,
boofcv.struct.image.Planar<T> output)
Down samples a planar image.
|
static <T extends boofcv.struct.image.ImageGray<T>> |
down(boofcv.struct.image.Planar<T> input,
boofcv.struct.image.Planar<T> output)
Down samples a planar image.
|
static <T extends boofcv.struct.image.ImageBase<T>> |
down(T input,
T output)
Down samples image.
|
static int |
downSampleSize(int length,
int squareWidth)
Computes the length of a down sampled image based on the original length and the square width
|
static void |
reshapeDown(boofcv.struct.image.ImageBase image,
int inputWidth,
int inputHeight,
int squareWidth)
Reshapes an image so that it is the correct size to store the down sampled image
|
public static int downSampleSize(int length,
int squareWidth)
length - Length of side in input imagesquareWidth - Width of region used to down sample imagespublic static void reshapeDown(boofcv.struct.image.ImageBase image,
int inputWidth,
int inputHeight,
int squareWidth)
public static void down(boofcv.struct.image.ImageBase input,
int sampleWidth,
boofcv.struct.image.ImageBase output)
public static void down(boofcv.struct.image.ImageGray input,
int sampleWidth,
boofcv.struct.image.ImageGray output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.public static <T extends boofcv.struct.image.ImageBase<T>> void down(T input,
T output)
input - Input image. Not modified.output - Output image. Modified.public static <T extends boofcv.struct.image.ImageGray<T>> void down(boofcv.struct.image.Planar<T> input,
int sampleWidth,
boofcv.struct.image.Planar<T> output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.public static <T extends boofcv.struct.image.ImageGray<T>> void down(boofcv.struct.image.Planar<T> input,
boofcv.struct.image.Planar<T> output)
input - Input image. Not modified.output - Output image. Modified.public static void down(boofcv.struct.image.GrayU8 input,
int sampleWidth,
boofcv.struct.image.GrayI8 output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.public static void down(boofcv.struct.image.GrayS8 input,
int sampleWidth,
boofcv.struct.image.GrayI8 output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.public static void down(boofcv.struct.image.GrayU16 input,
int sampleWidth,
boofcv.struct.image.GrayI16 output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.public static void down(boofcv.struct.image.GrayS16 input,
int sampleWidth,
boofcv.struct.image.GrayI16 output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.public static void down(boofcv.struct.image.GrayS32 input,
int sampleWidth,
boofcv.struct.image.GrayS32 output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.public static void down(boofcv.struct.image.GrayF32 input,
int sampleWidth,
boofcv.struct.image.GrayF32 output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.public static void down(boofcv.struct.image.GrayF64 input,
int sampleWidth,
boofcv.struct.image.GrayF64 output)
input - Input image. Not modified.sampleWidth - Width of square region.output - Output image. Modified.