Blender  V3.3
Public Member Functions | Public Attributes | Protected Member Functions | List of all members
device_texture Class Reference

#include <memory.h>

Inheritance diagram for device_texture:
device_memory

Public Member Functions

 device_texture (Device *device, const char *name, const uint slot, ImageDataType image_data_type, InterpolationType interpolation, ExtensionType extension)
 
 ~device_texture ()
 
voidalloc (const size_t width, const size_t height, const size_t depth=0)
 
void copy_to_device ()
 
- Public Member Functions inherited from device_memory
size_t memory_size ()
 
size_t memory_elements_size (int elements)
 
virtual ~device_memory ()
 
void swap_device (Device *new_device, size_t new_device_size, device_ptr new_device_ptr)
 
void restore_device ()
 
bool is_resident (Device *sub_device) const
 

Public Attributes

uint slot
 
TextureInfo info
 
- Public Attributes inherited from device_memory
DataType data_type
 
int data_elements
 
size_t data_size
 
size_t device_size
 
size_t data_width
 
size_t data_height
 
size_t data_depth
 
MemoryType type
 
const char * name
 
Devicedevice
 
device_ptr device_pointer
 
voidhost_pointer
 
voidshared_pointer
 
int shared_counter
 

Protected Member Functions

size_t size (const size_t width, const size_t height, const size_t depth)
 
- Protected Member Functions inherited from device_memory
 device_memory (Device *device, const char *name, MemoryType type)
 
 device_memory (const device_memory &)=delete
 
 device_memory (device_memory &&other) noexcept=delete
 
device_memoryoperator= (const device_memory &)=delete
 
device_memoryoperator= (device_memory &&)=delete
 
voidhost_alloc (size_t size)
 
void host_free ()
 
void device_alloc ()
 
void device_free ()
 
void device_copy_to ()
 
void device_copy_from (size_t y, size_t w, size_t h, size_t elem)
 
void device_zero ()
 
bool device_is_cpu ()
 

Additional Inherited Members

- Protected Attributes inherited from device_memory
device_ptr original_device_ptr
 
size_t original_device_size
 
Deviceoriginal_device
 
bool need_realloc_
 
bool modified
 

Detailed Description

Definition at line 597 of file cycles/device/memory.h.

Constructor & Destructor Documentation

◆ device_texture()

device_texture::device_texture ( Device device,
const char *  name,
const uint  slot,
ImageDataType  image_data_type,
InterpolationType  interpolation,
ExtensionType  extension 
)

◆ ~device_texture()

device_texture::~device_texture ( )

Definition at line 200 of file memory.cpp.

References device_memory::device_free(), and device_memory::host_free().

Member Function Documentation

◆ alloc()

void * device_texture::alloc ( const size_t  width,
const size_t  height,
const size_t  depth = 0 
)

◆ copy_to_device()

void device_texture::copy_to_device ( )

Definition at line 230 of file memory.cpp.

References device_memory::device_copy_to().

◆ size()

size_t device_texture::size ( const size_t  width,
const size_t  height,
const size_t  depth 
)
inlineprotected

Definition at line 614 of file cycles/device/memory.h.

References height, and width.

Referenced by alloc().

Member Data Documentation

◆ info

TextureInfo device_texture::info

Definition at line 611 of file cycles/device/memory.h.

Referenced by alloc(), device_texture(), and CPUDevice::tex_alloc().

◆ slot

uint device_texture::slot

Definition at line 610 of file cycles/device/memory.h.

Referenced by CPUDevice::tex_alloc().


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