Quantcast

jpg not viewable in Linux?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

jpg not viewable in Linux?

Karyn Hurley
I'm hoping someone has seen this problem already!  

I am loading pictures into a viewer:

tempFile := 'C:\temp.png') asFilename.
stream := tempFile writeStream binary.
stream nextPutAll: myImage.
stream close.
pic := (ImageReader fromFile: tempFile) image.
imageDict := Dictionary new.
pic bounds corner = (1 @ 1) ifTrue: [^self].
imageDict at: #createDate put: (each at: #createDate).
imageDict at: #createTime put: (each at: #createTime).
imageDict at: #image put: pic.
imageDict at: #origin put: 1 @ 1.
imageDict at: #color put: #white.
imageDict at: #box put: pic bounds.
imageList add: imageDict

This code works fine for jpg and png in Windows o/s.   In Linux Red Hat 6.5 only the png's display, the jpg's are blank.

I've confirmed that:

ImageReader fromFile: tempFile is returning a JPEGImageReader and the pic is a Depth32 image, if I halt the code and inspect the pic in the Windows view and the Linux view the attributes are all the same.  

The jpg's that don't show up in the Smalltalk view can be opened and viewed in Linux by other applications.

Any thoughts?   I'm stumped.

Thanks!

Karyn Hurley
Global Foundries, Application Development
Loading...