This revision compiles and runs on Win7x64- but further evaluation is necessary. There may be an issue with cmake step -After cmake I had to copy rtgui/version.h & config.h into out of source build /rtgui folder. Additional notes: - ImProcFunctions::hsv2rgb01 -> this likely need to be added to color.h & color.cc - Use of array2D should be verified in NR code - compilation warning for rtengine::RawImageSource::isWBProviderReady()
57 lines
1.0 KiB
C++
57 lines
1.0 KiB
C++
/*********************************************************************
|
|
* error.c
|
|
*
|
|
* Error and warning messages, and system commands.
|
|
*********************************************************************/
|
|
|
|
|
|
/* Standard includes */
|
|
#include <cstdio>
|
|
#include <cstdlib>
|
|
#include <cstdarg>
|
|
|
|
|
|
/*********************************************************************
|
|
* KLTError
|
|
*
|
|
* Prints an error message and dies.
|
|
*
|
|
* INPUTS
|
|
* exactly like printf
|
|
*/
|
|
|
|
void KLTError(const char *fmt, ...)
|
|
{
|
|
va_list args;
|
|
|
|
va_start(args, fmt);
|
|
fprintf(stderr, "KLT Error: ");
|
|
vfprintf(stderr, fmt, args);
|
|
fprintf(stderr, "\n");
|
|
va_end(args);
|
|
exit(1);
|
|
}
|
|
|
|
|
|
/*********************************************************************
|
|
* KLTWarning
|
|
*
|
|
* Prints a warning message.
|
|
*
|
|
* INPUTS
|
|
* exactly like printf
|
|
*/
|
|
|
|
void KLTWarning(const char *fmt, ...)
|
|
{
|
|
va_list args;
|
|
|
|
va_start(args, fmt);
|
|
fprintf(stderr, "KLT Warning: ");
|
|
vfprintf(stderr, fmt, args);
|
|
fprintf(stderr, "\n");
|
|
fflush(stderr);
|
|
va_end(args);
|
|
}
|
|
|