molgif

command module
v0.0.0-...-a7df9e4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 8, 2018 License: ISC Imports: 17 Imported by: 0

README

Molgif

Molgif is an easy-to-use tool for creating GIF animations of molecules. Thanks to the widespread support of GIF file format, animations can be easily embedded into presentations, websites, wikipedia, and so forth.

caffeine fullerene benzene

Installation

Molgif works on Linux, BSD, OSX, Windows operating systems. Molgif requires Go version 1.5 or later. To download and compile the code, issue:

go get github.com/ilyak/molgif

Molgif has no external dependencies and uses only Go standard library. Animation rendering is performed using ray-tracing. Rendering is done in parallel using multiple CPUs available on the system.

Usage

List of available command-line flags with documentation can be obtained with molgif -help:

-X            rotate along x axis in reverse
-Y            rotate along y axis in reverse
-Z            rotate along z axis in reverse
-a float      atom size (default 0.4)
-b uint       background color blue component
-d float      bond size (default 0.2)
-e string     cpu profiling data file name
-g uint       background color green component
-h int        output image height (default 256)
-l            hide molgif banner
-o string     output file name
-p            render image in png format
-r uint       background color red component
-t int        animation loop time in seconds (default 3)
-w int        output image width (default 256)
-x            rotate along x axis
-y            rotate along y axis
-z            rotate along z axis
Samples

Below is a list of sample animations along with the molgif command used to create them.

Caffeine molecule
molgif caffeine.xyz

caffeine

Benzene molecule
molgif -X -a 0.2 benzene.xyz

benzene

Carbon nanotube
molgif -w 500 -t 5 nanotube.xyz

nanotube

Water cluster
molgif -Y -t 5 -r 80 -g 80 -b 80 water.xyz

water

TNT molecule
molgif -r 220 -g 220 tnt.xyz

tnt

Fullerene molecule
molgif -Y -t 8 -g 100 -b 100 -a 0.3 fullerene.xyz

fullerene

Adenine and Guanine nucleobases
molgif -t 8 adenine.xyz
molgif -t 4 guanine.xyz

adenine guanine

Documentation

Overview

(c) 2016 Ilya Kaliman. ISC license.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL