#FEATURE by cg
class: ImageReader
class definition
changed: #makeImage
metaData support
--- a/ImageReader.st Thu Jun 02 09:31:43 2016 +0200
+++ b/ImageReader.st Thu Jun 02 19:46:18 2016 +0200
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
"
COPYRIGHT (c) 1991 by Claus Gittinger
All Rights Reserved
@@ -16,7 +18,8 @@
Object subclass:#ImageReader
instanceVariableNames:'width height data byteOrder inStream outStream photometric
samplesPerPixel bitsPerSample colorMap mask maskPixel
- dimensionCallBack dimensionHolder progressHolder imageSequence'
+ dimensionCallBack dimensionHolder progressHolder imageSequence
+ metaData'
classVariableNames:'ReverseBits'
poolDictionaries:''
category:'Graphics-Images-Readers'
@@ -1843,24 +1846,27 @@
depth := self bitsPerPixel.
(depth notNil and:[data notNil]) ifTrue:[
- image := Image newForDepth:depth.
- image depth:depth.
- inStream isFileStream ifTrue:[
- image fileName:inStream pathName.
- ].
- image
- width:width
- height:height
- photometric:photometric
- samplesPerPixel:samplesPerPixel
- bitsPerSample:bitsPerSample
- colorMap:colorMap
- bits:data
- mask:mask.
+ image := Image newForDepth:depth.
+ image depth:depth.
+ inStream isFileStream ifTrue:[
+ image fileName:inStream pathName.
+ ].
+ image
+ width:width
+ height:height
+ photometric:photometric
+ samplesPerPixel:samplesPerPixel
+ bitsPerSample:bitsPerSample
+ colorMap:colorMap
+ bits:data
+ mask:mask.
- imageSequence notNil ifTrue:[
- image imageSequence:imageSequence.
- ].
+ imageSequence notNil ifTrue:[
+ image imageSequence:imageSequence.
+ ].
+ (metaData notNil and:[metaData notEmpty]) ifTrue:[
+ image metaData:metaData
+ ].
].
^ image
@@ -2195,3 +2201,4 @@
version_CVS
^ '$Header$'
! !
+