Merge branch '8.10'
This commit is contained in:
commit
59ea801627
@ -41,6 +41,10 @@
|
|||||||
* - add ppmload_source
|
* - add ppmload_source
|
||||||
* 22/11/20
|
* 22/11/20
|
||||||
* - fix msb_first default [ewelot]
|
* - fix msb_first default [ewelot]
|
||||||
|
* 26/12/20
|
||||||
|
* - don't byteswap ascii formats
|
||||||
|
* - set metadata for map loads
|
||||||
|
* - byteswap binary loads
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -705,7 +709,10 @@ vips_foreign_load_ppm_load( VipsForeignLoad *load )
|
|||||||
vips_amiMSBfirst() != ppm->msb_first );
|
vips_amiMSBfirst() != ppm->msb_first );
|
||||||
#endif /*DEBUG*/
|
#endif /*DEBUG*/
|
||||||
|
|
||||||
|
/* Don't byteswap the ascii formats.
|
||||||
|
*/
|
||||||
if( vips__byteswap_bool( t[0], &t[1],
|
if( vips__byteswap_bool( t[0], &t[1],
|
||||||
|
!ppm->ascii &&
|
||||||
vips_amiMSBfirst() != ppm->msb_first ) ||
|
vips_amiMSBfirst() != ppm->msb_first ) ||
|
||||||
vips_image_write( t[1], load->real ) )
|
vips_image_write( t[1], load->real ) )
|
||||||
return( -1 );
|
return( -1 );
|
||||||
|
@ -891,6 +891,20 @@ class TestForeign:
|
|||||||
self.save_load("%s.ppm", self.mono)
|
self.save_load("%s.ppm", self.mono)
|
||||||
self.save_load("%s.ppm", self.colour)
|
self.save_load("%s.ppm", self.colour)
|
||||||
|
|
||||||
|
self.save_load_file("%s.ppm", "[ascii]", self.mono, 0)
|
||||||
|
self.save_load_file("%s.ppm", "[ascii]", self.colour, 0)
|
||||||
|
|
||||||
|
self.save_load_file("%s.ppm", "[ascii,bitdepth=1]", self.onebit, 0)
|
||||||
|
|
||||||
|
rgb16 = self.colour.colourspace("rgb16")
|
||||||
|
grey16 = self.mono.colourspace("rgb16")
|
||||||
|
|
||||||
|
self.save_load("%s.ppm", grey16)
|
||||||
|
self.save_load("%s.ppm", rgb16)
|
||||||
|
|
||||||
|
self.save_load_file("%s.ppm", "[ascii]", grey16, 0)
|
||||||
|
self.save_load_file("%s.ppm", "[ascii]", rgb16, 0)
|
||||||
|
|
||||||
@skip_if_no("radload")
|
@skip_if_no("radload")
|
||||||
def test_rad(self):
|
def test_rad(self):
|
||||||
self.save_load("%s.hdr", self.colour)
|
self.save_load("%s.hdr", self.colour)
|
||||||
|
Loading…
Reference in New Issue
Block a user