OutputImageParam#

class OutputImageParam#

A handle on the output buffer of a pipeline.

Used to make static promises about the output size and stride.

Subclassed by Halide::ImageParam

Public Functions

OutputImageParam() = default#

Construct a null image parameter handle.

const std::string &name() const#

Get the name of this Param.

Type type() const#

Get the type of the image data this Param refers to.

bool defined() const#

Is this parameter handle non-nullptr.

Internal::Dimension dim(int i)#

Get a handle on one of the dimensions for the purposes of inspecting or constraining its min, extent, or stride.

Internal::Dimension dim(int i) const#

Get a handle on one of the dimensions for the purposes of inspecting its min, extent, or stride.

int host_alignment() const#

Get the alignment of the host pointer in bytes.

Defaults to the size of type.

OutputImageParam &set_host_alignment(int)#

Set the expected alignment of the host pointer in bytes.

int dimensions() const#

Get the dimensionality of this image parameter.

Expr left() const#

Get an expression giving the minimum coordinate in dimension 0, which by convention is the coordinate of the left edge of the image.

Expr right() const#

Get an expression giving the maximum coordinate in dimension 0, which by convention is the coordinate of the right edge of the image.

Expr top() const#

Get an expression giving the minimum coordinate in dimension 1, which by convention is the top of the image.

Expr bottom() const#

Get an expression giving the maximum coordinate in dimension 1, which by convention is the bottom of the image.

Expr width() const#

Get an expression giving the extent in dimension 0, which by convention is the width of the image.

Expr height() const#

Get an expression giving the extent in dimension 1, which by convention is the height of the image.

Expr channels() const#

Get an expression giving the extent in dimension 2, which by convention is the channel-count of the image.

Parameter parameter() const#

Get at the internal parameter object representing this ImageParam.

operator Argument() const#

Construct the appropriate argument matching this parameter, for the purpose of generating the right type signature when statically compiling halide pipelines.

operator ExternFuncArgument() const#

Using a param as the argument to an external stage treats it as an Expr.

OutputImageParam &set_estimates(const Region &estimates)#

Set (min, extent) estimates for all dimensions in the ImageParam at once; this is equivalent to calling dim(n).set_estimate(min, extent) repeatedly, but slightly terser.

The size of the estimates vector must match the dimensionality of the ImageParam.

OutputImageParam &store_in(MemoryType type)#

Set the desired storage type for this parameter.

Only useful for MemoryType::GPUTexture at present