Re: [Jmol-users] png files created in jsmol

2017-07-23 Thread Robert Hanson
Q: What is the purpose of using pngCheck?


On Sat, Jul 22, 2017 at 5:52 AM, Angel Herráez  wrote:

> Hi João
>
> Even though the PNG files are not validated by pngcheck, they are rendered
> correctly by many programs.
>
> It should be easy to implement the setting of  'set imageState off'
> in the page source for the Sage project, and then the product of the Export
> menu would be compliant.
>
>
> ---
> El software de antivirus Avast ha analizado este correo electrónico en
> busca de virus.
> https://www.avast.com/antivirus
>
>
> 
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Jmol-users mailing list
> Jmol-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jmol-users
>



-- 
Robert M. Hanson
Professor of Chemistry
St. Olaf College
Northfield, MN
http://www.stolaf.edu/people/hansonr


If nature does not answer first what we want,
it is better to take what answer we get.

-- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] png files created in jsmol

2017-07-22 Thread Angel Herráez
Hi João 

Even though the PNG files are not validated by pngcheck, they are rendered 
correctly by many programs.

It should be easy to implement the setting of  'set imageState off'
in the page source for the Sage project, and then the product of the Export 
menu would be compliant.


---
El software de antivirus Avast ha analizado este correo electrónico en busca de 
virus.
https://www.avast.com/antivirus


--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] png files created in jsmol

2017-07-22 Thread João Palhoto Matos

Às 09:24 de 22-07-2017, Rolf Huehne escreveu:


Am 22.07.17 um 10:04 schrieb João Palhoto Matos:

Hello!

I use jmol inside SageMath which I build from source. Currently this is
Sage 7.6 which comes with  jmol-14.6.1_2016.07.11 from which it uses
jsmol. When producing a 3d graphic one has the option of saving or
exporting files in various formats from a context menu. One of them is
PNG files, namely "export PNG image". The files produced in this manner
fail to pass testing with the pngcheck utility. Opening the file with
gimp and exporting to png format one ends up with a smaller file without
apparent image quality loss which is considered OK by pngcheck. Is this
intended behavior and the file getting some extra information, or 
some bug?


It is a special Jmol feature. As default, images saved in PNG format 
are actually saved in PNGJ format (see 
https://chemapps.stolaf.edu/jmol/docs/#writeimagesandframes). This 
means everything needed to get back the 3D model in the representation 
shown in the image is included.


You can easily check this by opening the image in Jmol/JSmol.

This behaviour can be switched off by the command 'set imageState off' 
and back on by 'set imageState on'.


Regards,
Rolf



Thanks! This seems rather counterintuitive for a menu labeled 
"Export...", though. I'll notify sage developers about this.


Regards,

João

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


Re: [Jmol-users] png files created in jsmol

2017-07-22 Thread Rolf Huehne

Am 22.07.17 um 10:04 schrieb João Palhoto Matos:

Hello!

I use jmol inside SageMath which I build from source. Currently this is
Sage 7.6 which comes with  jmol-14.6.1_2016.07.11 from which it uses
jsmol. When producing a 3d graphic one has the option of saving or
exporting files in various formats from a context menu. One of them is
PNG files, namely "export PNG image". The files produced in this manner
fail to pass testing with the pngcheck utility. Opening the file with
gimp and exporting to png format one ends up with a smaller file without
apparent image quality loss which is considered OK by pngcheck. Is this
intended behavior and the file getting some extra information, or some bug?

It is a special Jmol feature. As default, images saved in PNG format are 
actually saved in PNGJ format (see 
https://chemapps.stolaf.edu/jmol/docs/#writeimagesandframes). This means 
everything needed to get back the 3D model in the representation shown 
in the image is included.


You can easily check this by opening the image in Jmol/JSmol.

This behaviour can be switched off by the command 'set imageState off' 
and back on by 'set imageState on'.


Regards,
Rolf


--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users


[Jmol-users] png files created in jsmol

2017-07-22 Thread João Palhoto Matos

Hello!

I use jmol inside SageMath which I build from source. Currently this is 
Sage 7.6 which comes with  jmol-14.6.1_2016.07.11 from which it uses 
jsmol. When producing a 3d graphic one has the option of saving or 
exporting files in various formats from a context menu. One of them is 
PNG files, namely "export PNG image". The files produced in this manner 
fail to pass testing with the pngcheck utility. Opening the file with 
gimp and exporting to png format one ends up with a smaller file without 
apparent image quality loss which is considered OK by pngcheck. Is this 
intended behavior and the file getting some extra information, or some bug?


Typical output of pngcheck in one of these files:

pngcheck Fromjmol.png
Fromjmol.png  additional data after IEND chunk
ERROR: Fromjmol.png

The file in question is available at:

https://drive.google.com/file/d/0BxvQu5VZ1xbeODl6R01aMVJSeFE/view?usp=sharing 



I believe jmol is not particularly changed by sage and this probably the 
best place to ask the question. Sorry, if this not the case.


Best, and thanks for Jmol,

João Palhoto Matos


--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users