texture クラス

テクスチャは範囲ドメイン内の accelerator_view についてのデータ集合体です。 これは、範囲ドメインの各要素に対して 1 つずつの変数のコレクションです。 各変数は、C++ のプリミティブ型 (unsigned intintfloatdouble)、スカラー型 (norm または unorm)、または短いベクター型に対応する値を保持します。

構文

template <typename value_type,  int _Rank>
class texture;

パラメーター

value_type
テクスチャの要素の型。

_Rank
テクスチャのランク。

メンバー

パブリック typedef

名前 説明
scalar_type スカラー型。
value_type 値型。

パブリック コンストラクター

名前 説明
texture Constructor texture クラスの新しいインスタンスを初期化します。
~texture デストラクター texture オブジェクトを破棄します。

パブリック メソッド

名前 説明
copy_to 詳細コピーを行って、texture オブジェクトをコピー先にコピーします。
data このテクスチャの生データに CPU のポインターを返します。
get 指定したインデックス位置に要素の値を返します。
get_associated_accelerator_view コピー先であるこのテクスチャの優先ターゲットである accelerator_view を返します。
get_depth_pitch CPU の 3D ステージング テクスチャの各深度スライス間のバイト数を返します。
get_row_pitch CPU の 2D または 3D ステージング テクスチャの各行間でバイト数を返します。
set 指定されたインデックス位置にある要素の値を設定します。

パブリック演算子

名前 説明
Operator() パラメーターによって指定された要素の値を返します。
operator[] 指定したインデックス位置にある要素を返します。
operator= 指定された texture オブジェクトをこのオブジェクトにコピーします。

パブリック定数

名前 説明
rank 定数 texture オブジェクトのランクを取得します。

パブリック データ メンバー

名前 説明
associated_accelerator_view コピー先であるこのテクスチャの優先ターゲットである accelerator_view を取得します。
depth_pitch CPU の 3D ステージング テクスチャの各深度スライス間のバイト数を取得します。
row_pitch CPU の 2D または 3D ステージング テクスチャの各行間のバイト数を取得します。

継承階層

_Texture_base

texture

必要条件

ヘッダー: amp_graphics.h

名前空間: Concurrency::graphics

~texture

texture オブジェクトを破棄します。

~texture() restrict(cpu);

associated_accelerator_view

コピー先であるこのテクスチャの優先ターゲットである accelerator_view を取得します。

__declspec(property(get= get_associated_accelerator_view)) Concurrency::accelerator_view associated_accelerator_view;

copy_to

詳細コピーを行って、texture オブジェクトをコピー先にコピーします。

void copy_to(texture& _Dest) const;
void copy_to(writeonly_texture_view<value_type, _Rank>& _Dest) const;

パラメーター

_Dest
コピー先のオブジェクト。

_Rank
テクスチャのランク。

value_type
テクスチャの要素の型。

データ

このテクスチャの生データに CPU のポインターを返します。

void* data() restrict(cpu);

const void* data() const restrict(cpu);

戻り値

テクスチャの生データへのポインター。

depth_pitch

CPU の 3D ステージング テクスチャの各深度スライス間のバイト数を取得します。

__declspec(property(get= get_depth_pitch)) unsigned int depth_pitch;

get

指定したインデックス位置に要素の値を返します。

const value_type get(const index<_Rank>& _Index) const restrict(amp);

パラメーター

_Index
要素のインデックス。

戻り値

指定されたインデックス位置にある要素の値。

get_associated_accelerator_view

コピー先であるこのテクスチャの優先ターゲットである accelerator_view を返します。

Concurrency::accelerator_view get_associated_accelerator_view() const restrict(cpu);

戻り値

コピー先であるこのテクスチャの優先ターゲットである accelerator_view

get_depth_pitch

CPU の 3D ステージング テクスチャの各深度スライス間のバイト数を返します。

unsigned int get_depth_pitch() const restrict(cpu);

戻り値

CPU の 3D ステージング テクスチャの各深度スライス間のバイト数。

get_row_pitch

2 次元ステージング テクスチャの各行間、または 3 次元ステージング テクスチャの深度スライスの各行間のバイト数を返します。

unsigned int get_row_pitch() const restrict(cpu);

戻り値

2 次元ステージング テクスチャの各行間、または 3 次元ステージング テクスチャの深度スライスの各行間のバイト数。

Operator()

パラメーターによって指定された要素の値を返します。

const value_type operator() (
    const index<_Rank>& _Index) const restrict(amp);

const value_type operator() (
    int _I0) const restrict(amp);

const value_type operator() (
    int _I0,
    int _I1) const restrict(amp);

const value_type operator() (
    int _I0,
    int _I1,
    int _I2) const restrict(amp);

パラメーター

_Index
インデックスです。

_I0
インデックスの最上位のコンポーネント。

_I1
インデックスの最上位の次のコンポーネント。

_I2
インデックスの最下位のコンポーネント。

_Rank
インデックスのランク。

戻り値

パラメーターで指定された要素の値。

operator[]

指定したインデックス位置にある要素を返します。

const value_type operator[] (const index<_Rank>& _Index) const restrict(amp);

const value_type operator[] (int _I0) const restrict(amp);

パラメーター

_Index
インデックスです。

_I0
インデックスです。

戻り値

指定したインデックス位置にある要素。

operator=

指定された texture オブジェクトをこのオブジェクトにコピーします。

texture& operator= (
    const texture& _Other);

texture& operator= (
    texture<value_type, _Rank>&& _Other);

パラメーター

_Other
コピー元の texture オブジェクト。

戻り値

この texture オブジェクトへの参照。

rank

texture オブジェクトのランクを取得します。

static const int rank = _Rank;

row_pitch

CPU の 2D または 3D ステージング テクスチャの各行間のバイト数を取得します。

__declspec(property(get= get_row_pitch)) unsigned int row_pitch;

set

指定されたインデックス位置にある要素の値を設定します。

void set(
    const index<_Rank>& _Index,
    const value_type& value) restrict(amp);

パラメーター

_Index
要素のインデックス。

_Rank
インデックスのランク。

value
要素の新しい値。

テクスチャ

texture クラスの新しいインスタンスを初期化します。

texture(const Concurrency::extent<_Rank>& _Ext) restrict(cpu);

texture(int _E0) restrict(cpu);

texture(int _E0, int _E1) restrict(cpu);

texture(int _E0, int _E1, int _E2) restrict(cpu);

texture(
    const Concurrency::extent<_Rank>& _Ext,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    int _E0,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    int _E0,
    int _E1,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    int _E0,
    int _E1,
    int _E2,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

template<typename _Input_iterator>
texture(
    const Concurrency::extent<_Rank>& _Ext,
    _Input_iterator _Src_first,
    _Input_iterator _Src_last) restrict(cpu);

template<typename _Input_iterator>
texture(
    int _E0, _Input_iterator _Src_first, _Input_iterator _Src_last) restrict(cpu);

template<typename _Input_iterator>
texture(
    int _E0,
    int _E1,
    _Input_iterator _Src_first,
    _Input_iterator _Src_last) restrict(cpu);

template<typename _Input_iterator>
texture(
    int _E0,
    int _E1,
    int _E2,
    _Input_iterator _Src_first,
    _Input_iterator _Src_last) restrict(cpu);

template<typename _Input_iterator>
texture(
    const Concurrency::extent<_Rank>& _Ext,
    _Input_iterator _Src_first,
    _Input_iterator _Src_last,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

template<typename _Input_iterator>
texture(
    int _E0,
    _Input_iterator _Src_first,
    _Input_iterator _Src_last,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

template<typename _Input_iterator>
texture(
    int _E0,
    int _E1,
    _Input_iterator _Src_first,
    _Input_iterator _Src_last,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

template<typename _Input_iterator>
texture(
    int _E0,
    int _E1,
    int _E2,
    _Input_iterator _Src_first,
    _Input_iterator _Src_last,
    const Concurrency::accelerator_view& _Av) restrict(cpu))  ;

texture(
    int _E0,
    unsigned int _Bits_per_scalar_element) restrict(cpu);

texture(
    int _E0,
    int _E1,
    unsigned int _Bits_per_scalar_element) restrict(cpu);

texture(
    int _E0,
    int _E1,
    int _E2,
    unsigned int _Bits_per_scalar_element) restrict(cpu);

texture(
    const Concurrency::extent<_Rank>& _Ext,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    int _E0,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av)  ;

texture(
    int _E0,
    int _E1,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    int _E0,
    int _E1,
    int _E2,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    const Concurrency::extent<_Rank>& _Ext,
    _In_ void* _Source,
    unsigned int _Src_byte_size,
    unsigned int _Bits_per_scalar_element) restrict(cpu);

texture(
    int _E0,
    _In_ void* _Source,
    unsigned int _Src_byte_size,
    unsigned int _Bits_per_scalar_element) restrict(cpu);

texture(
    int _E0,
    int _E1,
    _In_ void* _Source,
    unsigned int _Src_byte_size,
    unsigned int _Bits_per_scalar_element) restrict(cpu);

texture(
    int _E0,
    int _E1,
    int _E2,
    _In_ void* _Source,
    unsigned int _Src_byte_size,
    unsigned int _Bits_per_scalar_element) restrict(cpu);

texture(
    const Concurrency::extent<_Rank>& _Ext,
    _In_ void* _Source,
    unsigned int _Src_byte_size,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av)  ;

texture(
    int _E0,
    _In_ void* _Source,
    unsigned int _Src_byte_size,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    int _E0,
    int _E1,
    _In_ void* _Source,
    unsigned int _Src_byte_size,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    int _E0,
    int _E1,
    int _E2,
    _In_ void* _Source,
    unsigned int _Src_byte_size,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av) restrict(cpu);

texture(
    const texture& _Src,
    const Concurrency::accelerator_view& _Acc_view);

texture(
    texture&& _Other);

texture(
    const Concurrency::extent<_Rank>& _Ext,
    unsigned int _Bits_per_scalar_element,
    const Concurrency::accelerator_view& _Av);

texture(
    const texture& _Src);

パラメーター

_Acc_view
テクスチャの位置を指定する accelerator_view

_Av
テクスチャの位置を指定する accelerator_view

_Associated_av
コピー先としてまたはこのテクスチャからの優先ターゲットを指定する accelerator_view。

_Bits_per_scalar_element
テクスチャの基になるスカラー型のスカラー要素ごとのビット数。 一般に、サポートされている値は 8、16、32、および 64 です。 0 を指定すると、ビット数は基になる scalar_type と同じです。 64 は、倍精度ベースのテクスチャに対してのみ有効です。

_Ext
テクスチャの各次元の範囲。

_E0
テクスチャの最上位のコンポーネント。

_E1
テクスチャの最上位の次のコンポーネント。

_E2
テクスチャの範囲の最下位のコンポーネント。

_Input_iterator
入力反復子の型。

_Mipmap_levels
基になるテクスチャの MIPMAP レベルの数。 0 を指定すると、テクスチャには指定された範囲で可能な最小サイズにした MIPMAP レベルのすべての範囲が含まれます。

_Rank
範囲のランク。

_Source
ホスト バッファーへのポインター。

_Src
コピーするテクスチャ。

_Src_byte_size
ソース バッファーのバイト数。

_Src_first
ソース コンテナーへの先頭の反復子。

_Src_last
ソース コンテナーへの終了の反復子。

_Other
その他のデータ ソース。

_Rank
セクションのランク。

関連項目

Concurrency::graphics 名前空間