@Namespace(value="cv") @NoOffset @Properties(inherit=opencv_core.class) public class UMat extends Pointer
Pointer.CustomDeallocator, Pointer.Deallocator, Pointer.NativeDeallocator, Pointer.ReferenceCounter
Modifier and Type | Field and Description |
---|---|
static int |
AUTO_STEP
enum cv::UMat::
|
static int |
CONTINUOUS_FLAG
enum cv::UMat::
|
static int |
DEPTH_MASK
enum cv::UMat::
|
static int |
MAGIC_MASK
enum cv::UMat::
|
static int |
MAGIC_VAL
enum cv::UMat::
|
static int |
SUBMATRIX_FLAG
enum cv::UMat::
|
static int |
TYPE_MASK
enum cv::UMat::
|
Constructor and Description |
---|
UMat() |
UMat(int usageFlags)
default constructor
|
UMat(int ndims,
int[] sizes,
int type) |
UMat(int ndims,
int[] sizes,
int type,
int usageFlags) |
UMat(int ndims,
int[] sizes,
int type,
Scalar s) |
UMat(int ndims,
int[] sizes,
int type,
Scalar s,
int usageFlags) |
UMat(int ndims,
IntBuffer sizes,
int type) |
UMat(int ndims,
IntBuffer sizes,
int type,
int usageFlags) |
UMat(int ndims,
IntBuffer sizes,
int type,
Scalar s) |
UMat(int ndims,
IntBuffer sizes,
int type,
Scalar s,
int usageFlags) |
UMat(int rows,
int cols,
int type) |
UMat(int rows,
int cols,
int type,
int usageFlags)
constructs 2D matrix of the specified size and type
|
UMat(int rows,
int cols,
int type,
Scalar s) |
UMat(int rows,
int cols,
int type,
Scalar s,
int usageFlags)
constructs 2D matrix and fills it with the specified value _s.
|
UMat(int ndims,
IntPointer sizes,
int type) |
UMat(int ndims,
IntPointer sizes,
int type,
int usageFlags)
constructs n-dimensional matrix
|
UMat(int ndims,
IntPointer sizes,
int type,
Scalar s) |
UMat(int ndims,
IntPointer sizes,
int type,
Scalar s,
int usageFlags) |
UMat(Pointer p)
Pointer cast constructor.
|
UMat(Size size,
int type) |
UMat(Size size,
int type,
int usageFlags) |
UMat(Size size,
int type,
Scalar s) |
UMat(Size size,
int type,
Scalar s,
int usageFlags) |
UMat(UMat m)
copy constructor
|
UMat(UMat m,
Range rowRange) |
UMat(UMat m,
Range rowRange,
Range colRange)
creates a matrix header for a part of the bigger matrix
|
UMat(UMat m,
Rect roi) |
Modifier and Type | Method and Description |
---|---|
void |
_deallocate()
deallocates the matrix data
|
void |
addref()
increases the reference counter; use with care to avoid memleaks
|
UMat |
adjustROI(int dtop,
int dbottom,
int dleft,
int dright)
moves/resizes the current matrix ROI inside the parent matrix.
|
MatAllocator |
allocator()
custom allocator
|
UMat |
allocator(MatAllocator setter) |
UMat |
apply(Range ranges) |
UMat |
apply(Range rowRange,
Range colRange)
extracts a rectangular sub-matrix
|
UMat |
apply(Rect roi) |
void |
assignTo(UMat m) |
void |
assignTo(UMat m,
int type) |
int |
channels()
returns element type, similar to CV_MAT_CN(cvmat->type)
|
int |
checkVector(int elemChannels) |
int |
checkVector(int elemChannels,
int depth,
boolean requireContinuous)
returns N if the matrix is 1-channel (N x ptdim) or ptdim-channel (1 x N) or (N x 1); negative number otherwise
|
UMat |
clone()
returns deep copy of the matrix, i.e.
|
UMat |
col(int x)
returns a new matrix header for the specified column
|
UMat |
colRange(int startcol,
int endcol)
...
|
UMat |
colRange(Range r) |
int |
cols() |
UMat |
cols(int setter) |
void |
convertTo(GpuMat m,
int rtype) |
void |
convertTo(GpuMat m,
int rtype,
double alpha,
double beta) |
void |
convertTo(Mat m,
int rtype) |
void |
convertTo(Mat m,
int rtype,
double alpha,
double beta)
converts matrix to another datatype with optional scaling.
|
void |
convertTo(UMat m,
int rtype) |
void |
convertTo(UMat m,
int rtype,
double alpha,
double beta) |
void |
copySize(UMat m)
internal use function; properly re-allocates _size, _step arrays
|
void |
copyTo(GpuMat m) |
void |
copyTo(GpuMat m,
GpuMat mask) |
void |
copyTo(Mat m)
copies the matrix content to "m".
|
void |
copyTo(Mat m,
Mat mask)
copies those matrix elements to "m" that are marked with non-zero mask elements.
|
void |
copyTo(UMat m) |
void |
copyTo(UMat m,
UMat mask) |
void |
create(int[] sizes,
int type) |
void |
create(int[] sizes,
int type,
int usageFlags) |
void |
create(IntBuffer sizes,
int type) |
void |
create(IntBuffer sizes,
int type,
int usageFlags) |
void |
create(int ndims,
int[] sizes,
int type) |
void |
create(int ndims,
int[] sizes,
int type,
int usageFlags) |
void |
create(int ndims,
IntBuffer sizes,
int type) |
void |
create(int ndims,
IntBuffer sizes,
int type,
int usageFlags) |
void |
create(int rows,
int cols,
int type) |
void |
create(int rows,
int cols,
int type,
int usageFlags)
allocates new matrix data unless the matrix already has specified size and type.
|
void |
create(int ndims,
IntPointer sizes,
int type) |
void |
create(int ndims,
IntPointer sizes,
int type,
int usageFlags) |
void |
create(IntPointer sizes,
int type) |
void |
create(IntPointer sizes,
int type,
int usageFlags) |
void |
create(Size size,
int type) |
void |
create(Size size,
int type,
int usageFlags) |
int |
depth()
returns element type, similar to CV_MAT_DEPTH(cvmat->type)
|
UMat |
diag() |
UMat |
diag(int d)
...
|
static UMat |
diag(UMat d)
constructs a square diagonal matrix which main diagonal is vector "d"
|
int |
dims()
the matrix dimensionality, >= 2
|
UMat |
dims(int setter) |
double |
dot(GpuMat m) |
double |
dot(Mat m)
computes dot-product
|
double |
dot(UMat m) |
long |
elemSize()
returns element size in bytes,
|
long |
elemSize1()
returns the size of element channel in bytes.
|
boolean |
empty()
returns true if matrix data is NULL
|
static UMat |
eye(int rows,
int cols,
int type) |
static UMat |
eye(Size size,
int type) |
int |
flags()
includes several bit-fields:
- the magic signature
- continuity flag
- depth
- number of channels
|
UMat |
flags(int setter) |
Mat |
getMat(int flags) |
static MatAllocator |
getStdAllocator()
and the standard allocator
|
Pointer |
handle(int accessFlags)
Returns the OpenCL buffer handle on which UMat operates on.
|
UMat |
inv() |
UMat |
inv(int method)
matrix inversion by means of matrix expressions
|
boolean |
isContinuous()
returns true iff the matrix data is continuous
|
boolean |
isSubmatrix()
returns true if the matrix is a submatrix of another matrix
|
void |
locateROI(Size wholeSize,
Point ofs)
locates matrix header within a parent matrix.
|
UMat |
mul(GpuMat m) |
UMat |
mul(GpuMat m,
double scale) |
UMat |
mul(Mat m) |
UMat |
mul(Mat m,
double scale)
per-element matrix multiplication by means of matrix expressions
|
UMat |
mul(UMat m) |
UMat |
mul(UMat m,
double scale) |
void |
ndoffset(SizeTPointer ofs) |
long |
offset() |
UMat |
offset(long setter) |
static UMat |
ones(int rows,
int cols,
int type) |
static UMat |
ones(Size size,
int type) |
UMat |
put(Scalar s)
sets every matrix element to s
|
UMat |
put(UMat m)
assignment operators
|
void |
release()
decreases reference counter;
|
UMat |
reshape(int cn) |
UMat |
reshape(int cn,
int rows)
creates alternative matrix header for the same data, with different
|
UMat |
reshape(int cn,
int newndims,
int[] newsz) |
UMat |
reshape(int cn,
int newndims,
IntBuffer newsz) |
UMat |
reshape(int cn,
int newndims,
IntPointer newsz) |
UMat |
row(int y)
returns a new matrix header for the specified row
|
UMat |
rowRange(int startrow,
int endrow)
...
|
UMat |
rowRange(Range r) |
int |
rows()
the number of rows and columns or (-1, -1) when the matrix has more than 2 dimensions
|
UMat |
rows(int setter) |
UMat |
setTo(GpuMat value) |
UMat |
setTo(GpuMat value,
GpuMat mask) |
UMat |
setTo(Mat value) |
UMat |
setTo(Mat value,
Mat mask)
sets some of the matrix elements to s, according to the mask
|
UMat |
setTo(UMat value) |
UMat |
setTo(UMat value,
UMat mask) |
Size |
size() |
int |
size(int i) |
long |
step() |
long |
step(int i) |
long |
step1() |
long |
step1(int i)
returns step/elemSize1()
|
UMat |
t()
matrix transposition by means of matrix expressions
|
long |
total()
returns the total number of matrix elements
|
int |
type()
returns element type, similar to CV_MAT_TYPE(cvmat->type)
|
UMatData |
u() |
UMat |
u(UMatData setter) |
void |
updateContinuityFlag()
internal use method: updates the continuity flag
|
int |
usageFlags() |
UMat |
usageFlags(int setter) |
static UMat |
zeros(int rows,
int cols,
int type)
Matlab-style matrix initialization
|
static UMat |
zeros(Size size,
int type) |
address, asBuffer, asByteBuffer, availablePhysicalBytes, calloc, capacity, capacity, close, deallocate, deallocate, deallocateReferences, deallocator, deallocator, equals, fill, formatBytes, free, hashCode, isNull, isNull, limit, limit, malloc, maxBytes, maxPhysicalBytes, memchr, memcmp, memcpy, memmove, memset, offsetof, parseBytes, physicalBytes, position, position, put, realloc, referenceCount, releaseReference, retainReference, setNull, sizeof, toString, totalBytes, totalPhysicalBytes, withDeallocator, zero
public static final int MAGIC_VAL
public static final int AUTO_STEP
public static final int CONTINUOUS_FLAG
public static final int SUBMATRIX_FLAG
public static final int MAGIC_MASK
public static final int TYPE_MASK
public static final int DEPTH_MASK
public UMat(Pointer p)
Pointer.Pointer(Pointer)
.public UMat()
public UMat(int rows, int cols, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(int rows, int cols, int type)
public UMat(int rows, int cols, int type, @Const @ByRef Scalar s, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(@ByVal Size size, int type, @Const @ByRef Scalar s, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(int ndims, @Const IntPointer sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(int ndims, @Const IntPointer sizes, int type)
public UMat(int ndims, @Const IntBuffer sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(int ndims, @Const int[] sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(int ndims, @Const int[] sizes, int type)
public UMat(int ndims, @Const IntPointer sizes, int type, @Const @ByRef Scalar s, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(int ndims, @Const IntPointer sizes, int type, @Const @ByRef Scalar s)
public UMat(int ndims, @Const IntBuffer sizes, int type, @Const @ByRef Scalar s, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(int ndims, @Const int[] sizes, int type, @Const @ByRef Scalar s, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public UMat(@Const @ByRef UMat m, @Const @ByRef Range rowRange, @Const @ByRef(nullValue="cv::Range::all()") Range colRange)
@ByVal public UMat diag(int d)
@ByVal public static UMat diag(@Const @ByRef UMat d)
public void copyTo(@ByVal Mat m, @ByVal Mat mask)
public void convertTo(@ByVal Mat m, int rtype, double alpha, double beta)
@ByRef @Name(value="operator =") public UMat put(@Const @ByRef Scalar s)
@ByRef public UMat setTo(@ByVal Mat value, @ByVal(nullValue="cv::InputArray(cv::noArray())") Mat mask)
@ByRef public UMat setTo(@ByVal UMat value, @ByVal(nullValue="cv::InputArray(cv::noArray())") UMat mask)
@ByRef public UMat setTo(@ByVal GpuMat value, @ByVal(nullValue="cv::InputArray(cv::noArray())") GpuMat mask)
@ByVal public UMat reshape(int cn, int rows)
@ByVal public UMat reshape(int cn, int newndims, @Const IntPointer newsz)
@ByVal public UMat mul(@ByVal Mat m, double scale)
@ByVal public static UMat zeros(int rows, int cols, int type)
public void create(int rows, int cols, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public void create(int rows, int cols, int type)
public void create(@ByVal Size size, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public void create(int ndims, @Const IntPointer sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public void create(int ndims, @Const IntPointer sizes, int type)
public void create(int ndims, @Const IntBuffer sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public void create(int ndims, @Const int[] sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public void create(int ndims, @Const int[] sizes, int type)
public void create(@StdVector IntPointer sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public void create(@StdVector IntPointer sizes, int type)
public void create(@StdVector IntBuffer sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public void create(@StdVector IntBuffer sizes, int type)
public void create(@StdVector int[] sizes, int type, @Cast(value="cv::UMatUsageFlags") int usageFlags)
public void create(@StdVector int[] sizes, int type)
public void addref()
public void release()
public void copySize(@Const @ByRef UMat m)
public void locateROI(@ByRef Size wholeSize, @ByRef Point ofs)
@ByRef public UMat adjustROI(int dtop, int dbottom, int dleft, int dright)
@ByVal @Name(value="operator ()") public UMat apply(@ByVal Range rowRange, @ByVal Range colRange)
@Cast(value="bool") public boolean isContinuous()
@Cast(value="bool") public boolean isSubmatrix()
@Cast(value="size_t") public long elemSize1()
public int type()
public int depth()
public int channels()
public int checkVector(int elemChannels, int depth, @Cast(value="bool") boolean requireContinuous)
public int checkVector(int elemChannels)
public Pointer handle(@Cast(value="cv::AccessFlag") int accessFlags)
public void ndoffset(@Cast(value="size_t*") SizeTPointer ofs)
public int flags()
public UMat flags(int setter)
public int dims()
public UMat dims(int setter)
public int rows()
public UMat rows(int setter)
public int cols()
public UMat cols(int setter)
public MatAllocator allocator()
public UMat allocator(MatAllocator setter)
public UMat usageFlags(int setter)
public static MatAllocator getStdAllocator()
public void updateContinuityFlag()
public UMatData u()
public UMat offset(long setter)
@MemberGetter public int size(int i)
@MemberGetter public long step()
@MemberGetter public long step(int i)
Copyright © 2020. All rights reserved.