Skip to content

A molecular graphic toy visualizer in Rust

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT
Notifications You must be signed in to change notification settings

mogura-rs/mogura

Repository files navigation

mogura: A molecular graphic toy visualizer in Rust

Warning

RAM $\geq$ 8GB, CPU $\geq$ 8cores and GPU are desirable.

Do not load too large structure files.

There are some limitation for WASM version. See Feature

Quick Start

Install

cargo install --git https://github.com/mogura-rs/mogura mogura --locked

Run mogura

# start mogura
mogura

# show help
mogura -h

# visualize PDB: 8GNG (Or you can load them after staring mogura)
mogura 8gng.pdb

# visualize MD simulation of chignolin (Or you can load them after staring mogura)
mogura init.gro input.mol.compact.xtc

Gallery

simple_8gng selected_8gng simple_5awl
chignolin_trajectory 3jac_demo a2a_demo

Input files are available here

Feature

  • Visualize PDB, GRO format
    • stick, stick&ball, ball, tube(catmull-rom), line mode are supported
    • WASM does not support line (because WebGPU)
  • Visualize MD simulation using XTC format
    • topology must be PDB or GRO format
    • WASM does not support this (because of groan_rs, this crate depends internally on libc)
  • Atom selection language
    • resname, resid, name, index, protein, water, backbone, sidechain, ion, all, (), and, or, not are reserved words
    • support complex syntax
      • e.g. protein and name C CA N, (resname TYR PRO) and protein or not water
  • Multiple selection panel
    • multiple atom selection are possible for a single structure file.
  • Fetch PDB
    • dirty pdb file will cause parse error because of pdbtbx.

TODO

  • Lv1: Change configuration of selected atoms (e.g. Color, Radius, Opacity)
  • Lv1: Load multiple structure files
  • Lv1: Morphing by specifying two structures
  • Lv2: Pick up atoms and highlight them with their name
  • Lv2: Allow more flexible configuration of plugins
  • Lv3: Secondary structure prediction using DSSP or STRIDE
  • Lv3: Visualize structure as Cartoon and NewCartoon
  • Lv4: Path tracing using bevy-hikari(but no more developed) or developing default feature

About the name

$$ \text{Molecular Graphic Visualizer} \rightarrow \text{Mole + graphic} \rightarrow \text{Mo + gra} \rightarrow \text{mogura} $$

mogura also means "Mole".

Useful Reference

References