1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 15:23:05 +04:00

Merge pull request #12192 from pasbi:pfm

* created new decoder and encoder for PFM

pfm file format stores binary RGB or grayscale float images.

* added test for pfm codec

* replaced large with short licence header

* little/big-endian-check is now compile time

* fixed width/height confusion, improved big/little endian recognition, fixed scaling issue and Improved signature check

* adapted tests to handle float images well

* removed data-dependency: lena.pfm

the lena image is now loaded is pam and converted to pfm.

* fixed bug in endianess detection macro

* Added endianess detection for android and win

* removed fancy endianess detection

endianess detection will be implemented in cmake scripts soonish.

* fixed minor warnings

* fixed stupid elif defined bug

* silenced some implicit cast warnings

* replaced std::to_string with std::stringstream solution

std::to_string variant did not build on android.

* replaced new endianess macros with existing ones

* improved readability
This commit is contained in:
pasbi
2018-08-13 12:14:12 +02:00
committed by Alexander Alekhin
parent 4eb2966559
commit 9f5f64e14e
8 changed files with 376 additions and 2 deletions
+4
View File
@@ -156,6 +156,10 @@ struct ImageCodecInitializer
decoders.push_back( makePtr<PAMDecoder>() );
encoders.push_back( makePtr<PAMEncoder>() );
#endif
#ifdef HAVE_IMGCODEC_PFM
decoders.push_back( makePtr<PFMDecoder>() );
encoders.push_back( makePtr<PFMEncoder>() );
#endif
#ifdef HAVE_TIFF
decoders.push_back( makePtr<TiffDecoder>() );
encoders.push_back( makePtr<TiffEncoder>() );