mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 17:01:28 +00:00
6aa61e72b5
* cleanup on the sound init code. * added #pragma once in several headers. * macOS version detection overhaul.
36 lines
813 B
C++
36 lines
813 B
C++
#pragma once
|
|
#include "tarray.h"
|
|
#include "hwrenderer/data/buffers.h"
|
|
|
|
struct HWViewpointUniforms;
|
|
class FRenderState;
|
|
|
|
class HWViewpointBuffer
|
|
{
|
|
IDataBuffer *mBuffer;
|
|
IDataBuffer* mBufferPipeline[HW_MAX_PIPELINE_BUFFERS];
|
|
int mPipelineNbr;
|
|
int mPipelinePos = 0;
|
|
|
|
unsigned int mBufferSize;
|
|
unsigned int mBlockAlign;
|
|
unsigned int mUploadIndex;
|
|
unsigned int mLastMappedIndex;
|
|
unsigned int mByteSize;
|
|
TArray<bool> mClipPlaneInfo;
|
|
|
|
unsigned int mBlockSize;
|
|
|
|
void CheckSize();
|
|
|
|
public:
|
|
|
|
HWViewpointBuffer(int pipelineNbr = 1);
|
|
~HWViewpointBuffer();
|
|
void Clear();
|
|
int Bind(FRenderState &di, unsigned int index);
|
|
void Set2D(FRenderState &di, int width, int height, int pll = 0);
|
|
int SetViewpoint(FRenderState &di, HWViewpointUniforms *vp);
|
|
unsigned int GetBlockSize() const { return mBlockSize; }
|
|
};
|
|
|