Fix bug reported by Noel Llopis.
Make sure FreeImage declarations are not used when FreeImage is not available.
This commit is contained in:
@ -423,7 +423,7 @@ FloatImage * FloatImage::fastDownSample() const
|
|||||||
{
|
{
|
||||||
const uint n = w * h;
|
const uint n = w * h;
|
||||||
|
|
||||||
if (n & 1)
|
if ((m_width * m_height) & 1)
|
||||||
{
|
{
|
||||||
const float scale = 1.0f / (2 * n + 1);
|
const float scale = 1.0f / (2 * n + 1);
|
||||||
|
|
||||||
|
@ -62,9 +62,10 @@ namespace {
|
|||||||
|
|
||||||
} // namespace
|
} // namespace
|
||||||
|
|
||||||
|
#if defined(HAVE_FREEIMAGE)
|
||||||
static Image * loadFreeImage(FREE_IMAGE_FORMAT fif, Stream & s);
|
static Image * loadFreeImage(FREE_IMAGE_FORMAT fif, Stream & s);
|
||||||
static FloatImage * loadFloatFreeImage(FREE_IMAGE_FORMAT fif, Stream & s);
|
static FloatImage * loadFloatFreeImage(FREE_IMAGE_FORMAT fif, Stream & s);
|
||||||
|
#endif
|
||||||
|
|
||||||
Image * nv::ImageIO::load(const char * fileName)
|
Image * nv::ImageIO::load(const char * fileName)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user