From a9a8b8e6b6d3f49cff1addebb73f2b54b17ff5cf Mon Sep 17 00:00:00 2001 From: Christian Gmeiner Date: Tue, 2 Jun 2009 08:47:21 +0200 Subject: remove cSpuData class, as it is not needed --- dxr3interface_spu_encoder.c | 40 ---------------------------------------- dxr3interface_spu_encoder.h | 25 ------------------------- 2 files changed, 65 deletions(-) diff --git a/dxr3interface_spu_encoder.c b/dxr3interface_spu_encoder.c index 8c085d7..d80a02d 100644 --- a/dxr3interface_spu_encoder.c +++ b/dxr3interface_spu_encoder.c @@ -203,46 +203,6 @@ namespace XineScaler */ #endif /* USE_XINE_SCALER */ - -// ================================== -// dec. -cSpuData::~cSpuData() -{ - Clear(); -} - -// ================================== -// free buffer and set it to 0 -void cSpuData::Clear() -{ - if (data) - { - free(data); - count = malloc_size = 0; - } -} - -// ================================== -// wirte a byte to spu buffer -void cSpuData::WriteByte(uint8_t byte) -{ - if (count >= malloc_size) - { - data = (u_char*) realloc(data, malloc_size += 2048); - } - data[count++] = byte; -} - -// ================================== -void cSpuData::WriteNibble(int *higher_nibble, uint8_t nibble) -{ -} - -// ================================== -void cSpuData::WriteRle(int *higher_nibble, int length, int color) -{ -} - // ================================== cSPUEncoder::cSPUEncoder() { diff --git a/dxr3interface_spu_encoder.h b/dxr3interface_spu_encoder.h index d1d1b57..d226d14 100644 --- a/dxr3interface_spu_encoder.h +++ b/dxr3interface_spu_encoder.h @@ -53,31 +53,6 @@ struct sRectal size_t y1; }; -// ================================== -// our spu(data) with all needed routines -class cSpuData -{ -public: - cSpuData(): count(0), malloc_size(0) {} - ~cSpuData(); - - void Clear(); - u_char* GetData() const - { - return data; - } - - // write operations - void WriteByte(uint8_t byte); - void WriteNibble(int *higher_nibble, uint8_t nibble); - void WriteRle(int *higher_nibble, int length, int color); - -private: - u_char *data; - size_t count; // the count of bytes written - size_t malloc_size; // size of data -}; - // ================================== struct pixbuf { -- cgit v1.2.3