From ddb290d5f615019c33c42b8d94e5a5254cabcf33 Mon Sep 17 00:00:00 2001 From: Miodrag Milanovic Date: Sat, 22 Oct 2016 13:13:17 +0200 Subject: NOTICE (TYPE NAME CONSOLIDATION) Use standard uint64_t, uint32_t, uint16_t or uint8_t instead of UINT64, UINT32, UINT16 or UINT8 also use standard int64_t, int32_t, int16_t or int8_t instead of INT64, INT32, INT16 or INT8 --- src/lib/formats/csw_cas.cpp | 52 ++++++++++++++++++++++----------------------- 1 file changed, 26 insertions(+), 26 deletions(-) (limited to 'src/lib/formats/csw_cas.cpp') diff --git a/src/lib/formats/csw_cas.cpp b/src/lib/formats/csw_cas.cpp index 0790dd16dee..a8feccf5300 100644 --- a/src/lib/formats/csw_cas.cpp +++ b/src/lib/formats/csw_cas.cpp @@ -32,32 +32,32 @@ Offset Value Type Description #define CSW_WAV_FREQUENCY 44100 -static const UINT8 CSW_HEADER[] = { "Compressed Square Wave" }; +static const uint8_t CSW_HEADER[] = { "Compressed Square Wave" }; -static UINT32 get_leuint32(const void *ptr) +static uint32_t get_leuint32(const void *ptr) { - UINT32 value; + uint32_t value; memcpy(&value, ptr, sizeof(value)); return little_endianize_int32(value); } static int mycaslen; -static int csw_cas_to_wav_size( const UINT8 *casdata, int caslen ) +static int csw_cas_to_wav_size( const uint8_t *casdata, int caslen ) { - UINT32 SampleRate; - UINT32 NumberOfPulses; - UINT8 MajorRevision; - UINT8 MinorRevision; - UINT8 CompressionType; - UINT8 Flags; - UINT8 HeaderExtensionLength; - std::vector gz_ptr; + uint32_t SampleRate; + uint32_t NumberOfPulses; + uint8_t MajorRevision; + uint8_t MinorRevision; + uint8_t CompressionType; + uint8_t Flags; + uint8_t HeaderExtensionLength; + std::vector gz_ptr; int total_size; z_stream d_stream; int err; - UINT8 *in_ptr; + uint8_t *in_ptr; int bsize=0; if ( memcmp( casdata, CSW_HEADER, sizeof(CSW_HEADER)-1 ) ) @@ -98,7 +98,7 @@ static int csw_cas_to_wav_size( const UINT8 *casdata, int caslen ) mycaslen=caslen; //from here on down for now I am assuming it is compressed csw file. - in_ptr = (UINT8*) casdata+0x34+HeaderExtensionLength; + in_ptr = (uint8_t*) casdata+0x34+HeaderExtensionLength; gz_ptr.resize( 8 ); @@ -163,20 +163,20 @@ cleanup: return -1; } -static int csw_cas_fill_wave( INT16 *buffer, int length, UINT8 *bytes ) +static int csw_cas_fill_wave( int16_t *buffer, int length, uint8_t *bytes ) { - UINT32 SampleRate; - UINT32 NumberOfPulses; - UINT8 CompressionType; - UINT8 Flags; - UINT8 HeaderExtensionLength; - INT8 Bit; - - std::vector gz_ptr; + uint32_t SampleRate; + uint32_t NumberOfPulses; + uint8_t CompressionType; + uint8_t Flags; + uint8_t HeaderExtensionLength; + int8_t Bit; + + std::vector gz_ptr; int total_size; z_stream d_stream; int err; - UINT8 *in_ptr; + uint8_t *in_ptr; int bsize=0; int i; @@ -206,7 +206,7 @@ static int csw_cas_fill_wave( INT16 *buffer, int length, UINT8 *bytes ) //from here on down for now I am assuming it is compressed csw file. - in_ptr = (UINT8*) bytes+0x34+HeaderExtensionLength; + in_ptr = (uint8_t*) bytes+0x34+HeaderExtensionLength; gz_ptr.resize( 8 ); @@ -288,7 +288,7 @@ static const struct CassetteLegacyWaveFiller csw_legacy_fill_wave = { static cassette_image::error csw_cassette_identify( cassette_image *cassette, struct CassetteOptions *opts ) { - UINT8 header[22]; + uint8_t header[22]; cassette_image_read(cassette, header, 0, sizeof(header)); if (memcmp(&header[0], CSW_HEADER, sizeof(CSW_HEADER) - 1)) { -- cgit v1.2.3-70-g09d2