With the recent disclosure of a major security hole in Java, I have been wondering if perhaps my continued use of the Jmol utility for displaying 3-D molecular structures makes sense. Perhaps it is time to consider alternatives. (Right now if you click on a molecule image in one of my blog posts and you are using Firefox, a big warning sign comes up first requiring the user to actively decide to invoke the Jmol viewer. Might this warning be enough to discourage some users?)
In addition, the increasing use of mobile devices, which most often are not Java-enabled, suggests that moving to a new display option is warranted.
So, I am asking the community to participate in a conversation about how we might best address this issue in the (near) future. Is a Javascript widget the way to go? If so, which current program are people happy with? Or should we move to an HTML5 approach? And if this is the way to go, what tools are people suggesting?
If you want to see some fine examples of all three approaches (Java-based: Jmol, Javascipt-based: Chemdoodle, and HTML5-based: GLMol) I strongly encourage you to read Henry Rzepa’s recent brilliant article in Journal of Cheminformatics (DOI: 10.1186/1758-2946-5-6). This is a fantastic article to compare the old-school publication technology (as presented in modern day PDF form) and new-school enabled technology (what Henry calls a datument). First download the pdf version and read it, and then access the HTML version; I guarantee you will be impressed by the difference in the experience.
So, please chime in on what molecular viewers I might adopt for this blog, and perhaps we as a community might be able to encourage the use of and further the development of these enhanced publication technologies.
Jan H. Jensen responded on 26 Jan 2013 at 5:12 am #
JSmol, which is Jmol converted to javascript, is coming along nicely. http://chemapps.stolaf.edu/jmol/jsmol/test2.htm
It still needs to be a little bit faster, especially the loading.
Chemdoodle web components looks and feels great, but WebGL is still not supported on iOS devices.
Henry Rzepa responded on 29 Jan 2013 at 1:28 am #
Might I add some background (as I see it) to this process.
First, there came Xmol (= X-windows Mol). This was based on X-Windows, and served to provide an interface between national computation centers and the new breed of graphics-capable computers in the 1980s.
This was followed by Rasmol around 1990, which emerged out of protein crystallography and brought with it the need to accelerate the graphics for larger molecules (a need as revealed by Xmol). Rasmol had some fundamental breakthroughs in fast rendering of molecules, and showed that you could do this just in software; you did not need hardware accelerations (and very expensive systems such as the Evans and Sutherland PS series).
We incorporated Rasmol into a Web browser in 1994 using Chemical MIME; Rasmol was then spun out into the Netscape browser plugin Chime, and this introduced the more seamless combination of molecule viewer with a web browser.
Chime required the user to pre-install it into their browser. A Java-based solution was introduced in 1996 which did not require such pre-installation; we now know this as Jmol (= Java Mol). In the early days, performance was also an issue!
When I was writing the article Steve refers to above, in April 2012, the previous two years or so had seen remarkable improvements in the Javascript engines implemented in browsers, perhaps 10-20 fold in a short time. Coupled with WebGL, it brought the prospect of speeds which might approach that of (compiled) Java. I guess JSMol was born from about April to September 2012, but the realisation that it could actually start to compete in speed with Jmol only came relatively late.
I would like to highlight one other relatively un-lauded feature, due entirely to Bob Hanson, and that is JVXL. This is a wonderful compression algorithm which allows smooth surfaces to be rendered compactly. To illustrate, take a look at a cube of values (such as generated by eg Gaussian, ORCA and other programs) for visualising molecular orbitals, densities and other surfaces. These often can be up to 100 Mbytes in size (as fine grids). Bob’s JVXL algorithm can reduce that down to often 5 kbytes, or 200 kbytes for the larger grids. It means that these surfaces are easily embedded into Web pages, with no worries about download bandwidths. Perhaps the most difficult aspect of converting Jmol to JSMol was probably handling those surfaces; I do not know how fast it is for those (if you want to convert a cube file to JVXL, try this page).
Henry Rzepa responded on 29 Jan 2013 at 10:19 am #
I might perhaps add another comment about how one convinces a journal publisher to publish a datument. Although the J. Cheminformatics is a modern journal, they inherit the mechanics of producing an article from the parent organisation. This latter uses well honed methods for producing classical articles (ie PDF with perhaps a HTML version). The DTD used in this production process did not seamlessly absorb the requirements of the datument I submitted. In fact the relatively long processing time (April 2012 to January 2013) was due to discussions with the publishers. I sat down in their offices on two occasions for about two hours each to discuss the various issues raised by the process, and with possible solutions batted to and fro.
Even now, I sense that this process was to some extent a 1-off; I am not entirely sure they would welcome a deluge of datuments at this precise instant! But on the other hand, I suspect there is not at the moment a pent up demand from authors to get such compound articles published.
I might mention that achieving this with two 2 hour meetings is not always possible! I am in discussion with another (commercial) publisher about another article that was submitted some 9 months ago. Thus far, they have not been so accommodating as J. Cheminformatics, and it is entirely possible that in fact this second article will end up withdrawn from the publisher if they are unable to publish it as a datument. I will not give details here, but if the latter scenario does come about, please be assured that I will indeed name and shame them.
The experiments in datuments date back a while. A list of our recent experiments in this genre can be found by following this link or here.