ObjectivelyGPU
Object oriented graphics framework for SDL3 and C
Loading...
Searching...
No Matches
Framebuffer.c File Reference
#include <assert.h>
#include "Framebuffer.h"
#include "RenderDevice.h"
#include "Texture.h"

Macros

#define _Class   _Framebuffer

Functions

static void dealloc (Object *self)
static Uint32 currentSlot (const Framebuffer *self, const GPU_FramebufferAttachment *attachment)
 Returns the physical slot index a double-buffered attachment is writing this frame.
static SDL_GPUColorTargetInfo colorTargetInfoForLayer (const Framebuffer *self, Uint32 index, Uint32 layer, SDL_GPULoadOp loadOp, SDL_GPUStoreOp storeOp)
static SDL_GPUColorTargetInfo colorTargetInfo (const Framebuffer *self, Uint32 index, SDL_GPULoadOp loadOp, SDL_GPUStoreOp storeOp)
static SDL_GPUDepthStencilTargetInfo depthTargetInfo (const Framebuffer *self, SDL_GPULoadOp loadOp, SDL_GPUStoreOp storeOp)
static void pipelineTargetInfo (const Framebuffer *self, const SDL_GPUColorTargetBlendState *blendStates, SDL_GPUColorTargetDescription *descriptions, SDL_GPUGraphicsPipelineTargetInfo *targetInfo)
static Framebuffer * initWithDevice (Framebuffer *self, RenderDevice *device, const GPU_FramebufferCreateInfo *info)
static bool resize (Framebuffer *self, const SDL_Size *size)
static Texture * resolveColorTexture (const Framebuffer *self, Uint32 index)
static Texture * previousColorTexture (const Framebuffer *self, Uint32 index)
static Texture * resolveDepthTexture (const Framebuffer *self)
static void swap (Framebuffer *self)
static void initialize (Class *clazz)
Class * _Framebuffer (void)

Macro Definition Documentation

◆ _Class

#define _Class   _Framebuffer

Function Documentation

◆ _Framebuffer()

Class * _Framebuffer ( void )

◆ colorTargetInfo()

SDL_GPUColorTargetInfo colorTargetInfo ( const Framebuffer * self,
Uint32 index,
SDL_GPULoadOp loadOp,
SDL_GPUStoreOp storeOp )
static

◆ colorTargetInfoForLayer()

SDL_GPUColorTargetInfo colorTargetInfoForLayer ( const Framebuffer * self,
Uint32 index,
Uint32 layer,
SDL_GPULoadOp loadOp,
SDL_GPUStoreOp storeOp )
static

◆ currentSlot()

Uint32 currentSlot ( const Framebuffer * self,
const GPU_FramebufferAttachment * attachment )
static

Returns the physical slot index a double-buffered attachment is writing this frame.

◆ dealloc()

void dealloc ( Object * self)
static
See also
Object::dealloc(Object *)

◆ depthTargetInfo()

SDL_GPUDepthStencilTargetInfo depthTargetInfo ( const Framebuffer * self,
SDL_GPULoadOp loadOp,
SDL_GPUStoreOp storeOp )
static

◆ initialize()

void initialize ( Class * clazz)
static
See also
Class::initialize(Class *)

◆ initWithDevice()

Framebuffer * initWithDevice ( Framebuffer * self,
RenderDevice * device,
const GPU_FramebufferCreateInfo * info )
static

◆ pipelineTargetInfo()

void pipelineTargetInfo ( const Framebuffer * self,
const SDL_GPUColorTargetBlendState * blendStates,
SDL_GPUColorTargetDescription * descriptions,
SDL_GPUGraphicsPipelineTargetInfo * targetInfo )
static

◆ previousColorTexture()

Texture * previousColorTexture ( const Framebuffer * self,
Uint32 index )
static

◆ resize()

bool resize ( Framebuffer * self,
const SDL_Size * size )
static

◆ resolveColorTexture()

Texture * resolveColorTexture ( const Framebuffer * self,
Uint32 index )
static

◆ resolveDepthTexture()

Texture * resolveDepthTexture ( const Framebuffer * self)
static

◆ swap()

void swap ( Framebuffer * self)
static