mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 08:35:20 +02:00
Keep stats on hw buffer uploads
This commit is contained in:
@@ -195,9 +195,7 @@ public:
|
||||
// get current frames per second value
|
||||
s32 getFPS() const override;
|
||||
|
||||
//! returns amount of primitives (mostly triangles) were drawn in the last frame.
|
||||
//! very useful method for statistics.
|
||||
u32 getPrimitiveCountDrawn(u32 param = 0) const override;
|
||||
SFrameStats getFrameStats() const override;
|
||||
|
||||
//! \return Returns the name of the video driver. Example: In case of the DIRECT3D8
|
||||
//! driver, it would return "Direct3D8.1".
|
||||
@@ -538,8 +536,6 @@ public:
|
||||
virtual void convertColor(const void *sP, ECOLOR_FORMAT sF, s32 sN,
|
||||
void *dP, ECOLOR_FORMAT dF) const override;
|
||||
|
||||
bool checkDriverReset() override { return false; }
|
||||
|
||||
protected:
|
||||
//! deletes all textures
|
||||
void deleteAllTextures();
|
||||
@@ -570,6 +566,12 @@ protected:
|
||||
// prints renderer version
|
||||
void printVersion();
|
||||
|
||||
inline void accountHWBufferUpload(u32 size)
|
||||
{
|
||||
FrameStats.HWBuffersUploaded++;
|
||||
FrameStats.HWBuffersUploadedSize += size;
|
||||
}
|
||||
|
||||
inline bool getWriteZBuffer(const SMaterial &material) const
|
||||
{
|
||||
switch (material.ZWriteEnable) {
|
||||
@@ -696,8 +698,8 @@ protected:
|
||||
core::matrix4 TransformationMatrix;
|
||||
|
||||
CFPSCounter FPSCounter;
|
||||
SFrameStats FrameStats;
|
||||
|
||||
u32 PrimitivesDrawn;
|
||||
u32 MinVertexCountForVBO;
|
||||
|
||||
u32 TextureCreationFlags;
|
||||
|
Reference in New Issue
Block a user