From db44898ff61031ec533d7c3174e8635539241cca Mon Sep 17 00:00:00 2001 From: Emeric Date: Wed, 16 May 2018 18:17:01 +0200 Subject: [PATCH] Fix MSVC builds --- Codec/demosaicframes.c | 1 - Codec/lutpath.c | 4 ---- Common/MessageQueue.h | 2 +- DecoderSDK/CFHDMetadata.cpp | 4 +++- DecoderSDK/SampleDecoder.cpp | 2 +- 5 files changed, 5 insertions(+), 8 deletions(-) diff --git a/Codec/demosaicframes.c b/Codec/demosaicframes.c index de5bae2..3b72b55 100644 --- a/Codec/demosaicframes.c +++ b/Codec/demosaicframes.c @@ -5021,7 +5021,6 @@ float *LoadCube64_3DLUT(DECODER *decoder, CFHDDATA *cfhddata, int *lutsize) float *LUT = NULL; bool useLUT = false; CFLook_Header CFLKhdr; - char crcname[256]; FILE *fp = NULL; int err = 0; diff --git a/Codec/lutpath.c b/Codec/lutpath.c index 4245ed5..ca690e5 100644 --- a/Codec/lutpath.c +++ b/Codec/lutpath.c @@ -274,7 +274,6 @@ void OverrideCFHDDATA(DECODER *decoder, unsigned char *lpCurrentBuffer, int nWor if (decoder->image_dev_only || (metadatastart = MetaDataFindFirst(buf, samplesize, &metadatasize, &tag, &size, &type))) { - int firstmetadatachunk = 1; //DAN20080710 -- reset the value before loading them, as some RAW streams didn't have all the //value, which causes a database reset to fail (switch color database would not switch for //Premiere.) @@ -308,9 +307,6 @@ void OverrideCFHDDATA(DECODER *decoder, unsigned char *lpCurrentBuffer, int nWor if (decoder->image_dev_only || memcmp( &lastGUID, &cfhddata->clip_guid, sizeof(cfhddata->clip_guid) ) != 0) { - // fprintf(stderr, "newclip \n"); - int i; - if (cfhddata->ignore_disk_database == false) { checkdiskinfo = 1; // CD See if it is a new clip Need to set if not ignoring disk diff --git a/Common/MessageQueue.h b/Common/MessageQueue.h index 1ce425d..01c3327 100644 --- a/Common/MessageQueue.h +++ b/Common/MessageQueue.h @@ -64,7 +64,7 @@ class CMessageSemaphore if (handle) { long count; - bool result = ReleaseSemaphore(handle, 1, &count); + BOOL result = ReleaseSemaphore(handle, 1, &count); assert(result); return result != 0; } diff --git a/DecoderSDK/CFHDMetadata.cpp b/DecoderSDK/CFHDMetadata.cpp index f624e9a..f73598e 100644 --- a/DecoderSDK/CFHDMetadata.cpp +++ b/DecoderSDK/CFHDMetadata.cpp @@ -25,7 +25,9 @@ #if __APPLE__ #include #include "CoreFoundation/CoreFoundation.h" -#else +#endif + +#ifndef _WIN32 #include #endif diff --git a/DecoderSDK/SampleDecoder.cpp b/DecoderSDK/SampleDecoder.cpp index 7b37702..ee747ce 100644 --- a/DecoderSDK/SampleDecoder.cpp +++ b/DecoderSDK/SampleDecoder.cpp @@ -338,7 +338,7 @@ int GetPixelSize(CFHD_PixelFormat format) break; default: - throw CFHD_ERROR_BADFORMAT; + pixelSize = 0; break; }