--- a/Depth64Image.st Tue Mar 15 22:44:46 2016 +0100
+++ b/Depth64Image.st Tue Mar 15 22:44:50 2016 +0100
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
"
COPYRIGHT (c) 2009 by eXept Software AG
All Rights Reserved
@@ -11,6 +13,8 @@
"
"{ Package: 'stx:libview' }"
+"{ NameSpace: Smalltalk }"
+
Image subclass:#Depth64Image
instanceVariableNames:''
classVariableNames:''
@@ -78,9 +82,9 @@
pixelIndex := (width * 8 * y) + 1 + (x * 8).
- ^ ((bytes wordAt:pixelIndex MSB:true) bitShift:48)
- + ((bytes wordAt:pixelIndex+2 MSB:true) bitShift:32)
- + ((bytes wordAt:pixelIndex+4 MSB:true) bitShift:16)
+ ^ ((bytes unsignedInt16At:pixelIndex MSB:true) bitShift:48)
+ + ((bytes unsignedInt16At:pixelIndex+2 MSB:true) bitShift:32)
+ + ((bytes unsignedInt16At:pixelIndex+4 MSB:true) bitShift:16)
+ (bytes wordAt:pixelIndex+6 MSB:true).
!
@@ -95,10 +99,10 @@
bytes isNil ifTrue:[
self createPixelStore
].
- bytes wordAt:pixelIndex put:((aPixelValue bitShift:-48) bitAnd:16rFFFF) MSB:true.
- bytes wordAt:pixelIndex+2 put:((aPixelValue bitShift:-32) bitAnd:16rFFFF) MSB:true.
- bytes wordAt:pixelIndex+4 put:((aPixelValue bitShift:-16) bitAnd:16rFFFF) MSB:true.
- bytes wordAt:pixelIndex+6 put:(aPixelValue bitAnd:16rFFFF) MSB:true.
+ bytes unsignedInt16At:pixelIndex put:((aPixelValue bitShift:-48) bitAnd:16rFFFF) MSB:true.
+ bytes unsignedInt16At:pixelIndex+2 put:((aPixelValue bitShift:-32) bitAnd:16rFFFF) MSB:true.
+ bytes unsignedInt16At:pixelIndex+4 put:((aPixelValue bitShift:-16) bitAnd:16rFFFF) MSB:true.
+ bytes unsignedInt16At:pixelIndex+6 put:(aPixelValue bitAnd:16rFFFF) MSB:true.
! !
!Depth64Image methodsFor:'initialization'!
@@ -136,6 +140,6 @@
!Depth64Image class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libview/Depth64Image.st,v 1.4 2014-03-02 13:59:31 cg Exp $'
+ ^ '$Header$'
! !