Remove unused return value of IGraphics::UnloadTexture function

This commit is contained in:
Robert Müller 2024-08-01 22:38:48 +02:00
parent da8ec6bed9
commit 273f3e5bfa
3 changed files with 4 additions and 5 deletions

View file

@ -288,17 +288,16 @@ void CGraphics_Threaded::FreeTextureIndex(CTextureHandle *pIndex)
pIndex->Invalidate();
}
int CGraphics_Threaded::UnloadTexture(CTextureHandle *pIndex)
void CGraphics_Threaded::UnloadTexture(CTextureHandle *pIndex)
{
if(pIndex->IsNullTexture() || !pIndex->IsValid())
return 0;
return;
CCommandBuffer::SCommand_Texture_Destroy Cmd;
Cmd.m_Slot = pIndex->Id();
AddCmd(Cmd);
FreeTextureIndex(pIndex);
return 0;
}
static bool ConvertToRGBA(uint8_t *pDest, const CImageInfo &SrcImage)

View file

@ -946,7 +946,7 @@ public:
IGraphics::CTextureHandle FindFreeTextureIndex();
void FreeTextureIndex(CTextureHandle *pIndex);
int UnloadTexture(IGraphics::CTextureHandle *pIndex) override;
void UnloadTexture(IGraphics::CTextureHandle *pIndex) override;
IGraphics::CTextureHandle LoadTextureRaw(const CImageInfo &Image, int Flags, const char *pTexName = nullptr) override;
IGraphics::CTextureHandle LoadTextureRawMove(CImageInfo &Image, int Flags, const char *pTexName = nullptr) override;

View file

@ -340,7 +340,7 @@ public:
// destination width must be equal to the subwidth of the source
virtual void CopyTextureFromTextureBufferSub(uint8_t *pDestBuffer, size_t DestWidth, size_t DestHeight, const CImageInfo &SourceImage, size_t SrcSubOffsetX, size_t SrcSubOffsetY, size_t SrcSubCopyWidth, size_t SrcSubCopyHeight) = 0;
virtual int UnloadTexture(CTextureHandle *pIndex) = 0;
virtual void UnloadTexture(CTextureHandle *pIndex) = 0;
virtual CTextureHandle LoadTextureRaw(const CImageInfo &Image, int Flags, const char *pTexName = nullptr) = 0;
virtual CTextureHandle LoadTextureRawMove(CImageInfo &Image, int Flags, const char *pTexName = nullptr) = 0;
virtual CTextureHandle LoadTexture(const char *pFilename, int StorageType, int Flags = 0) = 0;