Fermat
Public Types | Public Methods | Public Members | List of all members
FBufferStorage Struct Reference

Detailed description

Framebuffer storage class, to be used from the host to allocate framebuffer storage
A framebuffer can hold multiple named channels of the same size; currently, only float4 channels are supported - in the future multiple formats might be added. The framebuffer also holds a single G-buffer.

#include <framebuffer.h>

Public Types

typedef std::shared_ptr< FBufferChannelStorageFBufferChannelPtr
 

Public Methods

 FBufferStorage ()
 
 ~FBufferStorage ()
 
void set_channel_count (const uint32 _n_channels)
 
void set_channel (const uint32_t i, const char *name)
 
void resize (const uint32_t _res_x, const uint32_t _res_y)
 
uint32_t channel_count () const
 
size_t size () const
 
FBufferView view ()
 

Public Members

uint32_t res_x
 
uint32_t res_y
 
uint32_t n_channels
 
GBufferStorage gbuffer
 
FBufferChannelStoragechannels
 
std::vector< std::string > names
 
DomainBuffer< CUDA_BUFFER, FBufferChannelViewchannel_views
 

Constructor & Destructor Documentation

◆ FBufferStorage()

FBufferStorage::FBufferStorage ( )
inline

constructor

◆ ~FBufferStorage()

FBufferStorage::~FBufferStorage ( )
inline

destructor

Member Function Documentation

◆ channel_count()

uint32_t FBufferStorage::channel_count ( ) const
inline

return the number of channels

◆ resize()

void FBufferStorage::resize ( const uint32_t  _res_x,
const uint32_t  _res_y 
)
inline

set the resolution of the framebuffer

◆ set_channel()

void FBufferStorage::set_channel ( const uint32_t  i,
const char *  name 
)
inline

set the name of a channel

◆ set_channel_count()

void FBufferStorage::set_channel_count ( const uint32  _n_channels)
inline

set the number of channels

◆ size()

size_t FBufferStorage::size ( ) const
inline

return the resolution of the framebuffer

◆ view()

FBufferView FBufferStorage::view ( )
inline

return a view object


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