imageutils.h File Reference

Go to the documentation of this file. Source: include/ffw/media/imageutils.h

/* This file is part of FineFramework project */
#ifndef FFW_MEDIA_IMAGE_UTILS
#define FFW_MEDIA_IMAGE_UTILS

#include <string>
#include "config.h"
#include "imagebuffer.h"

namespace ffw {
    class ImageReader;
    class ImageWriter;
    FFW_API ImageReader* openImageReader(const std::string& path);
    FFW_API ImageWriter* openImageWriter(const std::string& path, int width, int height, ffw::ImageType type, int quality = 100, int mips = 1);
    void FFW_API readImage(const std::string& path, void** dest, int* width, int* height, ffw::ImageType* format, int* mips = NULL);
    void FFW_API writeImage(const std::string& path, const void* src, int width, int height, ffw::ImageType format, int quality = 100, int mips = 1);
    void FFW_API readImage(const std::string& path, ffw::ImageBuffer& image);
    void FFW_API writeImage(const std::string& path, const ffw::ImageBuffer& image, int quality = 100);
}

#endif