Loading...
Searching...
No Matches
Halide::OutputImageParam Class Reference

A handle on the output buffer of a pipeline. More...

`#include <OutputImageParam.h>`

Inheritance diagram for Halide::OutputImageParam:

## Public Member 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.
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.
OutputImageParam & | store_in (MemoryType type)
| Set the desired storage type for this parameter.

## Protected Member Functions

void | add_implicit_args_if_placeholder (std::vector< Expr > &args, Expr last_arg, int total_args, bool *placeholder_seen) const
| OutputImageParam (const Parameter &p, Argument::Kind k, Func f)
| Construct an OutputImageParam that wraps an Internal Parameter object.

## Protected Attributes

Parameter | param
| A reference-counted handle on the internal parameter object.
Argument::Kind | kind = Argument::InputScalar
| Is this an input or an output?
Func | func
| If Input: Func representation of the ImageParam.

## Detailed Description

A handle on the output buffer of a pipeline.

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

Definition at line 19 of file OutputImageParam.h.

## Constructor & Destructor Documentation

## OutputImageParam() [1/2]

Halide::OutputImageParam::OutputImageParam | ( | const Parameter & | p,
|  | Argument::Kind | k,
|  | Func | f )

protected

Construct an OutputImageParam that wraps an Internal Parameter object.

References Func.

Referenced by Halide::ImageParam::::Halide::Internal::GeneratorInput_Buffer, set_estimates(), set_host_alignment(), and store_in().

## OutputImageParam() [2/2]

Halide::OutputImageParam::OutputImageParam | ( |  | ) |

default

Construct a null image parameter handle.

## Member Function Documentation

## add_implicit_args_if_placeholder()

void Halide::OutputImageParam::add_implicit_args_if_placeholder | ( | std::vector< Expr > & | args,
|  | Expr | last_arg,
|  | int | total_args,
|  | bool * | placeholder_seen ) const

protected

## name()

const std::string & Halide::OutputImageParam::name | ( |  | ) | const

Get the name of this Param.

## type()

Type Halide::OutputImageParam::type | ( |  | ) | const

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

Referenced by store_in().

## defined()

bool Halide::OutputImageParam::defined | ( |  | ) | const

Is this parameter handle non-nullptr.

## dim() [1/2]

Internal::Dimension Halide::OutputImageParam::dim | ( | int | i | ) |

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

## dim() [2/2]

Internal::Dimension Halide::OutputImageParam::dim | ( | int | i | ) | const

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

## host_alignment()

int Halide::OutputImageParam::host_alignment | ( |  | ) | const

Get the alignment of the host pointer in bytes.

Defaults to the size of type.

## set_host_alignment()

OutputImageParam & Halide::OutputImageParam::set_host_alignment | ( | int |  | ) |

Set the expected alignment of the host pointer in bytes.

References OutputImageParam().

## dimensions()

int Halide::OutputImageParam::dimensions | ( |  | ) | const

Get the dimensionality of this image parameter.

## left()

Expr Halide::OutputImageParam::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.

## right()

Expr Halide::OutputImageParam::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.

## top()

Expr Halide::OutputImageParam::top | ( |  | ) | const

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

## bottom()

Expr Halide::OutputImageParam::bottom | ( |  | ) | const

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

## width()

Expr Halide::OutputImageParam::width | ( |  | ) | const

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

## height()

Expr Halide::OutputImageParam::height | ( |  | ) | const

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

## channels()

Expr Halide::OutputImageParam::channels | ( |  | ) | const

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

## parameter()

Parameter Halide::OutputImageParam::parameter | ( |  | ) | const

Get at the internal parameter object representing this ImageParam.

## operator Argument()

Halide::OutputImageParam::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()

Halide::OutputImageParam::operator ExternFuncArgument | ( |  | ) | const

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

## set_estimates()

OutputImageParam & Halide::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.

References OutputImageParam().

## store_in()

OutputImageParam & Halide::OutputImageParam::store_in | ( | MemoryType | type | ) |

Set the desired storage type for this parameter.

Only useful for MemoryType::GPUTexture at present

References OutputImageParam(), and type().

## Member Data Documentation

## param

Parameter Halide::OutputImageParam::param

protected

A reference-counted handle on the internal parameter object.

Definition at line 24 of file OutputImageParam.h.

## kind

Argument::Kind Halide::OutputImageParam::kind = Argument::InputScalar

protected

Is this an input or an output?

OutputImageParam is the base class for both.

Definition at line 27 of file OutputImageParam.h.

## func

Func Halide::OutputImageParam::func

protected

If Input: Func representation of the ImageParam.

If Output: Func that creates this OutputImageParam.

Definition at line 32 of file OutputImageParam.h.

Referenced by Halide::ImageParam::operator()().

The documentation for this class was generated from the following file:

- src/OutputImageParam.h