Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- readBlp :: FilePath -> IO (Either String DynamicImage)
- readBlpMipmaps :: FilePath -> IO (Either String [DynamicImage])
- decodeBlp :: ByteString -> Either String DynamicImage
- decodeBlpMipmaps :: ByteString -> Either String [DynamicImage]
- writeBlpJpeg :: FilePath -> Int -> Int -> DynamicImage -> IO ()
- writeBlpUncompressedWithAlpha :: FilePath -> Int -> DynamicImage -> IO ()
- writeBlpUncompressedWithoutAlpha :: FilePath -> Int -> DynamicImage -> IO ()
- encodeBlpJpeg :: Int -> Int -> DynamicImage -> ByteString
- encodeBlpUncompressedWithAlpha :: Int -> DynamicImage -> ByteString
- encodeBlpUncompressedWithoutAlpha :: Int -> DynamicImage -> ByteString
- mipMapsUpTo :: Int -> DynamicImage -> Int
Documentation
readBlp :: FilePath -> IO (Either String DynamicImage) Source #
Read BLP from given file without mipmaps
readBlpMipmaps :: FilePath -> IO (Either String [DynamicImage]) Source #
Read BLP from given file with mipmaps
decodeBlp :: ByteString -> Either String DynamicImage Source #
Decodes BLP without mipmaps
decodeBlpMipmaps :: ByteString -> Either String [DynamicImage] Source #
Decodes BLP and returns original image plus all mipmaps
writeBlpJpeg :: FilePath -> Int -> Int -> DynamicImage -> IO () Source #
writeBlpUncompressedWithAlpha :: FilePath -> Int -> DynamicImage -> IO () Source #
writeBlpUncompressedWithoutAlpha :: FilePath -> Int -> DynamicImage -> IO () Source #
encodeBlpJpeg :: Int -> Int -> DynamicImage -> ByteString Source #
:: Int | Minimum size of picture side for generation of mipmap (ex. 2, 4, 16, 32, 64, 512, 1024 and etc) |
-> DynamicImage | Image for which we generate mipmaps |
-> Int |
Calculate needed count of mipmaps to cover sizes up to given minimum size (helper for 'writeBlp*' functions)