BACKGROUND
the problem we address in this report is visualization of integrated multimodality three-dimensional  brain imaging data.
such visualizations can lead to new insights that are not apparent from a single modality alone.
over the past several years many applications have become available that include some aspect of 3-d visualization.
a comprehensive listing of these applications can be found by searching the harvard internet analysis tools registry   <cit>  for those tools that are indexed by the keyword "visualization".
as of march  <dig> such a search returned a list of  <dig> tools.
of these tools many are designed for analysis of specific types of data; as, for example, loreta for source localized eeg  <cit> ; fsl  <cit> , spm  <cit>  and afni  <cit>  for functional magnetic resonance  data; and jatlasview  <cit>  and the allen brain atlas  <cit>  for gene expression data.
because they are designed for only one type of data these tools generally do not display different types of data at once.
on the other end of the spectrum, many tools are general purpose, such as analyze  <cit> , 3dvienix  <cit> , vtk  <cit>  or volview  <cit> .
these tools can integrate and visualize many different kinds of data.
however, if a user is simply interested in visualization of existing integrated data they can be overkill, especially given that some of them are expensive.
somewhere in the middle are programs specifically designed for multi-modality 3-d biomedical data, such as mricro  <cit> , medx  <cit> , brainsuite  <cit> , loni visualization environment  <cit> , freesurfer  <cit> , caret  <cit> , neuroterrain  <cit> , and 3d slicer  <cit> .
however, because many of these programs contain extensive analysis or other methods they may be more complex than is needed for pure visualization.
in addition, few if any of these programs combine both stand-alone and remote multi-modality visualization in an open source, portable and extensible tool that is easy to install and use, yet can be included as a component of a larger information system.
in this report we describe such a 3-d visualization program, called mindseer, which combines many of the best features of existing 3-d brain visualization programs, yet is greatly simplified by restricting it to visualization of existing data.
the program is written in java and java3d for true portability, and includes integrated data management, interoperability with many common neuroimaging data formats, standalone operation as well as remote visualization of centralized data through client-server access, the capability to be a component in a larger information system, and extensibility through plugins.
the program is freely available, portable across all three major platforms , and runs at interactive speeds when installed locally.
the remainder of this report describes the design goals and implementation for mindseer, and as well as examples of its use.
more extensive documentation, downloads, and tutorials are available on the project web page  <cit> .
implementation
design goals
we have designed mindseer to make visualizing and managing complex multi-modality neuroimaging datasets easy and convenient.
in order to provide the most intuitive system possible, we have kept mindseer focused on visualization, avoiding the complexity of duplicating analysis tools that are already found within existing programs.
we have therefore designed mindseer to work with the output of several popular brain image analysis tools, such as spm  <cit>  and fsl  <cit> , while providing a plugin mechanism for importing and exporting data from other analysis packages.
table  <dig> lists the current compatible file formats.
within this focus on visualization, we have defined a set of design goals.
mindseer should:
<dig>  import and export common data formats.
<dig>  provide both 2-d slice views and 3-d surface views with cutaways.
<dig>  allow superposition of multiple sources and types of functional data on a single structural volume or surface.
<dig>  be easy to setup, with no configuration for the end user.
<dig>  be easy to extend.
new neuroimaging data sources and visualization techniques are in continuous development.
<dig>  support integrated data management, and provide a system where it is easy to keep track of images and visualize them in new and different scenes.
<dig>  support these functions and others in a client-server mode that transparently provides interactive visualization of data in a central repository.
<dig>  be portable across all major platforms, and run at interactive speeds.
<dig>  be able to be a component in a larger information system.
<dig>  be freely available under an open source  license.
architecture
the architecture of mindseer is designed to meet these goals.
the program is written in java and java3d  <cit> , so is platform independent.
recent versions of java3d take advantage of the considerable rendering speeds of desktop graphics cards, so are able to provide real-time rendering of large 3-d surface models, yet retain portability.
to meet the need for transparent client-server mode with the same look and feel as the standalone version, mindseer is designed in  <dig> main parts based on the model-view-controller  pattern  <cit> .
the mvc pattern separates the user interface  from the underlying data representation and processing  by introducing an intermediary  to respond to input and changes.
in our case, the display and the communication layer form the view, and the back end contains both models and controllers .
this division is natural because mindseer can either work as a standalone application where the display and back end communicate instantaneously, or can be separated, with the display becoming the client application, the back end becoming the server, and the communication layer taking care of synchronization.
the display is further divided into a number of subparts .
the main work horse is the client manager.
this component acts as an intermediary to ensure that communication between the display and back end is executed in a deterministic order in a multi-threaded environment.
it also monitors the scenes that are currently visible, and manages events to load new scenes and add data to existing scenes.
another display controller is the layout manager, which takes care of laying out the components of the graphical user interface .
the layout manager can be changed to support different layouts; currently the system supports both a single tabbed window layout and a layout with multiple floating windows.
the third important piece is the gui, which consists of the displayed scene, widgets for controlling the data and scene, and the library view, which displays the available files of neuroimaging data and associated metadata.
within the gui communications are primarily handled by a special set of gui widgets that are based on the observer pattern  <cit> .
this pattern allows an object, the observer, to register itself with the subject.
the subject will then notify all registered observers whenever important changes or events occur.
the widget itself is the subject and the primary observer is the controller on the back-end.
for example, in figure  <dig> the viewport controller is an observer for the view control widgets in the gui.
when in client-server mode, secondary observers act as the communication link between the two computers by transmitting user events and view changes across the network connection.
in the few cases where communication is not graphically initiated, such as opening a session, quitting or launching a new view, the client manager will send an event to the session on the back-end.
the back end  provides an extensible framework for processing data and generating the content of scenes.
the framework is directed by a session object, which controls the flow of the program.
the session is aided by a data manager, which loads and caches the neuroimaging data files in a memory efficient manner.
the master copy of the library is maintained by the session.
scenes are also maintained and created in the viewport by the session.
plugins for managing and viewing scenes
new data types and methods for displaying them in scenes are added to the system by subclassing one or more of seven abstract plugin classes , which provide a set of common methods for each plugin type.
the seven classes all interrelate, and include file decoders and encoders, data models, data wrappers, viewports, view controllers and data controllers.
the decoders and encoders are responsible for loading a file and turning it into a compatible data model.
the data model represents a shared form that the file takes in memory, whereas data wrappers present a data model in the form required by a specific type of viewport.
viewports are responsible for rendering a scene using wrapped versions of each data model.
viewports also support custom controls and algorithms through viewport controllers and data controllers, which can be customized for each type of data wrapper and viewport.
the specific instances of these seven abstract classes are discovered at runtime by consulting an xml configuration file that describes where to find these concrete implementations.
the concrete implementations are registered with factory classes that produce the correct concrete implementation from information known at runtime.
for example, the decoder for a nifti  <cit>  file can be retrieved by simply asking the factory for a nifti decoder.
likewise, the appropriate default viewport can be called just by telling the factory what data model is being used.
the base system provides two main sets of prebuilt plugins for visualizing volumetric datasets  and surfaces .
these plugin sets are organized around a slice viewport and a surface viewport.
the slice viewport displays volumetric data in coronal, transverse and sagittal views.
it is capable of layering an arbitrary number of volumes and coordinate maps.
to aid in differentiating the volumes and maps, each can be assigned its own color scheme and transparency value.
this viewport is supported by several plugins, including decoders for nifti, analyze  <dig> , spm's version of analyze  <dig> , and a custom xml map file of 3-d coordinates within or on the surface of the brain .
the decoders can produce two different kinds of data models: the volume data model, which represents 3-d and 4-d  volumes such as mri and source localized eeg, and the map data model, which represents the xml map file.
these models are in turn encapsulated by data wrappers for different types of visualization.
three dimensional surfaces are displayed in the surface viewport, which supports dynamic interaction and transparency, and can display any number of surfaces.
surfaces can either be pre-generated using a tool such as spm, or isosurfaces can be generated by mindseer from the volumetric data.
like the slice viewport, the surface viewport is supported by several plugins.
this viewport has its own decoders for spm's 3-d surface format and some of the geomview  <cit>  surface file formats, but it also shares the decoders for volume and map files with the slice viewport.
a surface data model handles surface data files, and data wrappers over the surface data model hold display and color information in addition to producing the required java3d objects.
by writing different wrappers for the surface and volume data models the same models can be re-used in both the volume and surface viewports.
for example, there are three different wrappers for volume data models that produce three different visualization effects in the surface viewport: volumes as isosurfaces, volumes as orthogonal planes that cut into 3-d surfaces, and volumes as highlights over 3-d surfaces.
in addition to the two main viewports there are two minor viewports: an independent display of map file 3-d coordinates in tabular form, and a simple image viewport that displays digital photographs and other images.
to visualize a new data model or create a new way of visualizing an existing data model within an existing viewport, developers can write a new data wrapper to make the modality compatible with the viewport.
in addition, developers can expand the variety of viewports beyond the slice and 3-d surface viewports.
new file types can be added by developing decoders and encoders to read and write them.
to aid the development of new file decoders, mindseer includes many tools and algorithms for manipulating and displaying data that is represented in typical ways.
for surface data, the framework includes tools for handling and optimizing triangle arrays , which are a standard way to represent polygonal structures.
for volumetric images, the basic built-in model is a  <dig> dimensional array that aligns closely with the nifti format and can accommodate most volumetric modalities and their file formats .
the available data structures also support associating labels with individual intensities in a volume file.
this gives mindseer's built in volume model the capability to be extended to handle the custom lookup files that are associated with indexed atlases .
these core data models – and the fact that they are decoupled from the details of file encoding and decoding – should allow mindseer to model most medical imaging data.
data management
an important feature of mindseer is that it integrates data management with visualization.
by combining these functions, mindseer provides a quick and easy way to create and experiment with scenes, and to automatically find data without user intervention.
the application manages data in an xml file, called the library, which contains file locations and associated metadata.
data can be tagged with any metadata, but the interface makes it easy to attach certain core tags, including the coordinate space , the subject or patient identifier, whether the image is structural or functional, and the modality .
these core tags are used to automatically generate a consistent tree for easily browsing the data , which is sorted by coordinate space, subject, function versus structure, and modality.
the system also infers the tags of a new data file based on where it is inserted into the tree.
the core tags and exact tree structure are specified in an xml based template file that can be edited for other domains.
simple scripts can be created to generate the xml library file automatically from a database.
client-server
by designing the system with separate display and back ends a client-server mode is a natural extension.
mindseer only required minor modifications and additions to add client-server functionality.
for example, the server required the addition of a control class to generate new sessions for each client.
this class also registers itself with the java rmi  <cit>  server so that clients can find it.
other additions include the introduction of secondary observers to automatically handle synchronization when either the client or server state changes.
these observers are automatically added to observable subjects when the subjects are marshaled to be sent over the wire.
through this mechanism, we can create custom objects that transparently handle client-server mode.
in addition the system tries to maintain interactivity over a variety of connections by adjusting image quality and compression level to reflect the network speed.
gui widgets
the key to making it easy to write plugins that work in both standalone and client-server modes is that most communication is handled transparently through custom gui widgets.
these widgets are based on the architecture of java swing  <cit> , and they therefore follow modified model-view-controller and observer patterns.
while each widget can have any number of observers, in mindseer observers usually are of two types.
the first types are controllers, which handle events from the user and initiate changes in the scene.
the second types are the synchronization listeners that are automatically added as the widgets are marshaled.
each synchronization listener monitors a copy of the widget for any property changes, and when they occur, the changes are propagated across the network.
additionally, in order to leverage the java library, the widgets generate swing objects for display.
user interface
the user interface is designed to maximize consistency.
everything has a well-defined place , corresponding to the gui classes in figure  <dig>  the viewport containing the scene is flanked by the library view on the left and the scene controls on the right, which are in turn divided into two tabs: data and view.
the data tab contains controls for the appearance of an individual file within a scene.
these controls can affect color, transparency, location, or other attributes.
additionally, since some files can be edited, this group of controls can be locked or unlocked by activating an "edit" mode.
the view tab, on the other hand, controls the appearance of the whole scene, including the order that volumes are stacked , the camera parameters, and the location and extent of a wedge cut out of a surface.
the library view  is also kept visible and is intuitively interactive.
the tree supports drag-and-drop for rearranging the library and transparently altering metadata, as well as drag-and-drop for adding files to existing scenes.
to maximize user friendliness, mindseer also provides several standard menus where preferences can be adjusted and changes undone.
RESULTS
in this section we demonstrate the range of mindseer features by presenting a number of example case studies.
tutorials or demos of several of these use cases are presented on the website  <cit> .
visualizing mri, fmri and source localized eeg
the focus of the system from the beginning has been to build rich scenes with diverse sources of data.
such data integration provides a qualitative feel for how different functional modalities interrelate and how they relate to the underlying structure.
in order to test this capability, we obtained image volumes from three different imaging modalities: structural mri, fmri, and source localized eeg.
we then displayed these volumes in a set of complex scenes.
from the structural mri we also derived the cortical surface and masks of the brain.
the initial step was to build a library that had all the files, which was done by using the file menu to define a new library based on a template, and to add new image files in their proper location in the template.
after placing each file into the library, we built a 2-d or 3-d scene by dragging an icon representing each desired data file from the library into a 2-d or 3-d viewport.
the first such scene is a simple slice view with the structural mri as a base and the fmri and eeg each shown in different colors .
the second scene is in 3-d. the scene starts on a base of the cortical surface.
when we added the first functional volume to the surface the system used the library to automatically add the structural mri and masks as it cut out the wedge.
to achieve the final image, we generated 3-d isosurfaces of the functional data in order to pinpoint activation .
this entire scene was generated quickly and painlessly.
since mindseer is compatible with tools researchers already use for analysis and segmentation, the addition of multimodality visualization is not an undue burden.
plotting 3-d points from a 2-d photograph
another feature of the system allows the user to indicate the 3-d locations of cortical landmarks on a displayed brain surface, in the process generating the xml map file described earlier.
in our own work we use this feature to visually  map the locations of labels from a surgical photograph  onto a 3-d surface rendering of the patient's own brain   <cit> .
the labels on the photograph show the locations where areas of exposed cortex were electrically simulated during a procedure called cortical stimulation mapping   <cit> , which is used during neurosurgery to map the locations of language-sensitive cortex.
by mapping these csm sites to the patient's own brain and later to a normalized brain atlas we can relate them to other brain mapping data such as fmri or single unit recording   <cit> .
the first step in this procedure was to use spm to create a mask volume that strips away the skull from an mri structural image volume, and to use the mask to generate a 3-d cortical surface.
given these data files  we created a mindseer library pointing to these files, as well as the surgical photograph , the structural mri image volume, and an mri venogram showing cortical veins.
the veins, in conjunction with sulci and gyri, are useful landmarks for the visual mapping procedure.
within mindseer we then used the venogram and the mask generated in the first step to create a 3-d surface reconstruction of the patient's veins.
this surface was added to a mindseer scene showing the cortex and veins, which was displayed alongside the surgical photograph.
the final step was to use the mouse to indicate the locations on the 3-d surface that correspond to the csm sites shown on the photograph .
the resulting dataset was then saved as an xml map file.
this overall plotting process is similar to our earlier visual brain mapper  <cit> , but has mindseer's advantages of portability, remote access, and integration with analysis applications.
remote visualization
an important concern for us from the beginning has been remote visualization.
over several years of research we have accumulated a repository and associated database with mri, csm and fmri data from over  <dig> patients.
our collaborators need to be able to visualize this plethora of data without the added effort of downloading or organizing hundreds of gigabytes of files.
to accomplish this, we harness the client-server mode of mindseer.
in this case the server accesses an xml library that is automatically generated from the output of our x-batch program  <cit> .
x-batch is a plugin for spm that transparently generates a database describing  the locations of the structural and functional image files, accumulating multiple runs in a single file that is periodically converted to the mindseer xml library format.
thus, the central repository is automatically updated whenever new mri images are processed, thereby making these images immediately available for remote viewing in mindseer.
a demo of this capability for a sample dataset can be found on the project website  <cit> .
when run in client-server mode the client-side user interface looks exactly like the interface for the standalone version.
the only difference is in frame rates.
while the client-server version lacks the fluidity of the standalone version, it is still quite interactive , with frame rates of around  <dig> per second over a cable modem .
integration within a larger information system
as part of our human brain project  <cit>  work our group has created several local laboratory information management systems to manage various types of multi-modality brain imaging data.
these databases include the x-batch xml database  for managing mri data processed by spm  <cit> , as well as separate relational databases for cortical stimulation mapping   <cit>  and single unit recording   <cit>  data.
these separate databases are encapsulated in web services that accept queries in the xml query language xquery  <cit> .
a distributed xquery processor  <cit>  accepts queries over one or more of these data sources, sends individual query fragments to the separate data sources, and packages the separate results into a single xml file.
a web-based application called dxbrain  <cit>  allows the user to formulate distributed xqueries and visualize the returned xml result in various ways, including raw xml, html and 3-d.
when the user requests a 3-d visualization of the returned data, dxbrain reformulates the returned xml results as a mindseer library file, and automatically displays the results on a choice of 3-d surfaces – either a canonical brain surface to which all data have been normalized, or a patient-specific cortical surface from our repository.
for the canonical brain surface the system downloads the data and launches mindseer in standalone mode through a java web start link .
the download for the canonical surface only happens the first time mindseer is launched, so the extra speed and interactivity of standalone mode  makes this small download worth the extra time.
however, when the user selects a brain from our repository, the required download for each subject would be too large and expensive.
therefore, we use the versatility of client-server mode for visualizing data on a single subject.
the two different modes are transparent to the user except for the slower response time in client-server mode.
the ability to dynamically visualize query results with a single click of a web link has proved to be an invaluable tool for our collaborators, who can quickly adapt and refine queries to highlight the results in which they are interested.
it has also proven to be a thorough test of mindseer, as it has routinely and successfully been used on mac, linux and windows systems with various hardware and browser configurations.
extending mindseer
to test the extensibility of mindseer a computer science undergraduate student, , wrote a series of plugins as a senior thesis project  <cit> .
the goal of this work was to explore ways to highlight the cortical surface with functional data sources.
the final result added the capability to color cortical surfaces with functional data like fmri or source localized eeg .
in order to integrate his algorithms as plugins he needed to implement two subclasses of the abstract plugin classes- a data wrapper around a volume data model to add new visualization capabilities, and a custom viewport controller.
the wrapper binds his surface coloring algorithms, the volume data model and the underlying cortical surface data model.
the custom controller allows the user to specify the exact surface coloring algorithm, as well as how multiple functional volumes interact.
the new data volume wrapper made it easy to leverage existing decoders for surface and volume data, as well as the corresponding data models.
it also made it possible for his subsystem to handle new decoders for volumetric data without modification.
furthermore, by using the specialized gui widgets in his controller, his subsystem was able to work in client-server mode without additional effort.
the default user interface layout also made it so that his controls naturally work with the existing interface.
the end result is that much of his time was spent experimenting with visualization algorithms instead of reinventing the wheel.
discussion
these five case studies show that mindseer achieves the ten design goals previously described.
the achievement of these goals provides a basis for future enhancements.
in particular, the plugin mechanism should allow an undergraduate-level computer science or similar student to add new image modalities and visualization approaches with relative ease.
for example, the ability to plot points could be extended to draw curves and to calculate areas, as in the measure program  <cit> .
furthermore, there is nothing in the code that restricts mindseer to functional brain imaging data; with proper file encoders and decoders or external file converters  <cit> , the system should be able to display gene expression data on developmental atlases such as the mouse  <cit> , and with new data model plugins should be able to display 3-d molecular structures  <cit> .
other data that can be placed in a  <dig> or 4d grid could be visualized using mindseer.
these include computed tomography , among others.
additionally, while mindseer's default units are in millimeters, the units can be configured to display sub-millimeter data such as μmri, optical projection tomography   <cit> , episcopic fluorescence image capture   <cit>  and confocal microscopy.
other possible enhancements include the ability to display 4-d data via animations or a time slider in the 3-d viewport; the ability to complement the java web start client with an ajax  <cit>  style client similar to google maps  <cit> , thereby eliminating all setup requirements; the ability to click on regions of the 3-d brain and send queries to the backend databases, thereby allowing mindseer to be a visual query interface as well as a display interface; the ability to generate 3-d reconstructions from serial sections  <cit> ; and the ability to generate interactive anatomical scenes for anatomy education  <cit> .
we believe that the addition of each of these features would be relatively straightforward because of mindseer's modular and extensible architecture, all of which is open source.
CONCLUSIONS
in this paper we have presented mindseer, a new application for visualizing multimodality neuroimaging data that is extensible to other biomedical data as well.
although there are many 3-d visualization programs available, mindseer combines the best of many of them while retaining portability and extensibility.
in addition, mindseer is free and open source, thereby making it a candidate for extension to the needs of specific user communities.
availability and requirements
• project name: mindseer
• project home page:
• operating system: windows, linux, mac
• programming language: java, java3d
• other requirements: java  <dig> +, java3d  <dig>
• license: gpl
• any restrictions to use by non-academics: none
abbreviations
3-d – three-dimensional
ajax – asynchronous javascript and xml
csm – cortical stimulation mapping
erp – event related potential
fmri – functional magnetic resonance imaging
gpl – gnu general public license
gui – graphical user interface
html – hypertext markup language
mri – magnetic resonance imaging
mvc – model-view-controller
nifti – neuroimaging informatics technology initiative
rmi – remote method invocation
xml – extensible markup language
competing interests
the author declares that there are no competing interests.
authors' contributions
em – primary designer and implementer of mindseer, primary author of manuscript.
ap – neuroscience user requirements, software tester, user and maintainer.
pl – fmri surface coloring plugin.
jb – lab director, problem and use case specifications, software tester, manuscript preparation, funding support.
all authors have read and approved the final version of the manuscript.

 the problem we address in this report is visualization of integrated multimodality three-dimensional brain imaging data. such visualizations can lead to new insights that are not apparent from a single modality alone. over the past several years many applications have become available that include some aspect of 3-d visualization. a comprehensive listing of these applications can be found by searching the harvard internet analysis tools registry for those tools that are indexed by the keyword "visualization". as of march such a search returned a list of tools. of these tools many are designed for analysis of specific types of data; as, for example, loreta for source localized eeg; fsl, spm and afni for functional magnetic resonance data; and jatlasview and the allen brain atlas for gene expression data. because they are designed for only one type of data these tools generally do not display different types of data at once. on the other end of the spectrum, many tools are general purpose, such as analyze, 3dvienix, vtk or volview. these tools can integrate and visualize many different kinds of data. however, if a user is simply interested in visualization of existing integrated data they can be overkill, especially given that some of them are expensive. somewhere in the middle are programs specifically designed for multi-modality 3-d biomedical data, such as mricro, medx, brainsuite, loni visualization environment, freesurfer, caret, neuroterrain, and 3d slicer. however, because many of these programs contain extensive analysis or other methods they may be more complex than is needed for pure visualization. in addition, few if any of these programs combine both stand-alone and remote multi-modality visualization in an open source, portable and extensible tool that is easy to install and use, yet can be included as a component of a larger information system. in this report we describe such a 3-d visualization program, called mindseer, which combines many of the best features of existing 3-d brain visualization programs, yet is greatly simplified by restricting it to visualization of existing data. the program is written in java and java3d for true portability, and includes integrated data management, interoperability with many common neuroimaging data formats, standalone operation as well as remote visualization of centralized data through client-server access, the capability to be a component in a larger information system, and extensibility through plugins. the program is freely available, portable across all three major platforms, and runs at interactive speeds when installed locally. the remainder of this report describes the design goals and implementation for mindseer, and as well as examples of its use. more extensive documentation, downloads, and tutorials are available on the project web page. implementation design goals we have designed mindseer to make visualizing and managing complex multi-modality neuroimaging datasets easy and convenient. in order to provide the most intuitive system possible, we have kept mindseer focused on visualization, avoiding the complexity of duplicating analysis tools that are already found within existing programs. we have therefore designed mindseer to work with the output of several popular brain image analysis tools, such as spm and fsl, while providing a plugin mechanism for importing and exporting data from other analysis packages. table lists the current compatible file formats. within this focus on visualization, we have defined a set of design goals. mindseer should: import and export common data formats. provide both 2-d slice views and 3-d surface views with cutaways. allow superposition of multiple sources and types of functional data on a single structural volume or surface. be easy to setup, with no configuration for the end user. be easy to extend. new neuroimaging data sources and visualization techniques are in continuous development. support integrated data management, and provide a system where it is easy to keep track of images and visualize them in new and different scenes. support these functions and others in a client-server mode that transparently provides interactive visualization of data in a central repository. be portable across all major platforms, and run at interactive speeds. be able to be a component in a larger information system. be freely available under an open source license. architecture the architecture of mindseer is designed to meet these goals. the program is written in java and java3d, so is platform independent. recent versions of java3d take advantage of the considerable rendering speeds of desktop graphics cards, so are able to provide real-time rendering of large 3-d surface models, yet retain portability. to meet the need for transparent client-server mode with the same look and feel as the standalone version, mindseer is designed in main parts based on the model-view-controller pattern. the mvc pattern separates the user interface from the underlying data representation and processing by introducing an intermediary to respond to input and changes. in our case, the display and the communication layer form the view, and the back end contains both models and controllers. this division is natural because mindseer can either work as a standalone application where the display and back end communicate instantaneously, or can be separated, with the display becoming the client application, the back end becoming the server, and the communication layer taking care of synchronization. the display is further divided into a number of subparts. the main work horse is the client manager. this component acts as an intermediary to ensure that communication between the display and back end is executed in a deterministic order in a multi-threaded environment. it also monitors the scenes that are currently visible, and manages events to load new scenes and add data to existing scenes. another display controller is the layout manager, which takes care of laying out the components of the graphical user interface. the layout manager can be changed to support different layouts; currently the system supports both a single tabbed window layout and a layout with multiple floating windows. the third important piece is the gui, which consists of the displayed scene, widgets for controlling the data and scene, and the library view, which displays the available files of neuroimaging data and associated metadata. within the gui communications are primarily handled by a special set of gui widgets that are based on the observer pattern. this pattern allows an object, the observer, to register itself with the subject. the subject will then notify all registered observers whenever important changes or events occur. the widget itself is the subject and the primary observer is the controller on the back-end. for example, in figure the viewport controller is an observer for the view control widgets in the gui. when in client-server mode, secondary observers act as the communication link between the two computers by transmitting user events and view changes across the network connection. in the few cases where communication is not graphically initiated, such as opening a session, quitting or launching a new view, the client manager will send an event to the session on the back-end. the back end provides an extensible framework for processing data and generating the content of scenes. the framework is directed by a session object, which controls the flow of the program. the session is aided by a data manager, which loads and caches the neuroimaging data files in a memory efficient manner. the master copy of the library is maintained by the session. scenes are also maintained and created in the viewport by the session. plugins for managing and viewing scenes new data types and methods for displaying them in scenes are added to the system by subclassing one or more of seven abstract plugin classes, which provide a set of common methods for each plugin type. the seven classes all interrelate, and include file decoders and encoders, data models, data wrappers, viewports, view controllers and data controllers. the decoders and encoders are responsible for loading a file and turning it into a compatible data model. the data model represents a shared form that the file takes in memory, whereas data wrappers present a data model in the form required by a specific type of viewport. viewports are responsible for rendering a scene using wrapped versions of each data model. viewports also support custom controls and algorithms through viewport controllers and data controllers, which can be customized for each type of data wrapper and viewport. the specific instances of these seven abstract classes are discovered at runtime by consulting an xml configuration file that describes where to find these concrete implementations. the concrete implementations are registered with factory classes that produce the correct concrete implementation from information known at runtime. for example, the decoder for a nifti file can be retrieved by simply asking the factory for a nifti decoder. likewise, the appropriate default viewport can be called just by telling the factory what data model is being used. the base system provides two main sets of prebuilt plugins for visualizing volumetric datasets and surfaces. these plugin sets are organized around a slice viewport and a surface viewport. the slice viewport displays volumetric data in coronal, transverse and sagittal views. it is capable of layering an arbitrary number of volumes and coordinate maps. to aid in differentiating the volumes and maps, each can be assigned its own color scheme and transparency value. this viewport is supported by several plugins, including decoders for nifti, analyze, spm's version of analyze, and a custom xml map file of 3-d coordinates within or on the surface of the brain. the decoders can produce two different kinds of data models: the volume data model, which represents 3-d and 4-d volumes such as mri and source localized eeg, and the map data model, which represents the xml map file. these models are in turn encapsulated by data wrappers for different types of visualization. three dimensional surfaces are displayed in the surface viewport, which supports dynamic interaction and transparency, and can display any number of surfaces. surfaces can either be pre-generated using a tool such as spm, or isosurfaces can be generated by mindseer from the volumetric data. like the slice viewport, the surface viewport is supported by several plugins. this viewport has its own decoders for spm's 3-d surface format and some of the geomview surface file formats, but it also shares the decoders for volume and map files with the slice viewport. a surface data model handles surface data files, and data wrappers over the surface data model hold display and color information in addition to producing the required java3d objects. by writing different wrappers for the surface and volume data models the same models can be re-used in both the volume and surface viewports. for example, there are three different wrappers for volume data models that produce three different visualization effects in the surface viewport: volumes as isosurfaces, volumes as orthogonal planes that cut into 3-d surfaces, and volumes as highlights over 3-d surfaces. in addition to the two main viewports there are two minor viewports: an independent display of map file 3-d coordinates in tabular form, and a simple image viewport that displays digital photographs and other images. to visualize a new data model or create a new way of visualizing an existing data model within an existing viewport, developers can write a new data wrapper to make the modality compatible with the viewport. in addition, developers can expand the variety of viewports beyond the slice and 3-d surface viewports. new file types can be added by developing decoders and encoders to read and write them. to aid the development of new file decoders, mindseer includes many tools and algorithms for manipulating and displaying data that is represented in typical ways. for surface data, the framework includes tools for handling and optimizing triangle arrays, which are a standard way to represent polygonal structures. for volumetric images, the basic built-in model is a dimensional array that aligns closely with the nifti format and can accommodate most volumetric modalities and their file formats. the available data structures also support associating labels with individual intensities in a volume file. this gives mindseer's built in volume model the capability to be extended to handle the custom lookup files that are associated with indexed atlases. these core data models – and the fact that they are decoupled from the details of file encoding and decoding – should allow mindseer to model most medical imaging data. data management an important feature of mindseer is that it integrates data management with visualization. by combining these functions, mindseer provides a quick and easy way to create and experiment with scenes, and to automatically find data without user intervention. the application manages data in an xml file, called the library, which contains file locations and associated metadata. data can be tagged with any metadata, but the interface makes it easy to attach certain core tags, including the coordinate space, the subject or patient identifier, whether the image is structural or functional, and the modality. these core tags are used to automatically generate a consistent tree for easily browsing the data, which is sorted by coordinate space, subject, function versus structure, and modality. the system also infers the tags of a new data file based on where it is inserted into the tree. the core tags and exact tree structure are specified in an xml based template file that can be edited for other domains. simple scripts can be created to generate the xml library file automatically from a database. client-server by designing the system with separate display and back ends a client-server mode is a natural extension. mindseer only required minor modifications and additions to add client-server functionality. for example, the server required the addition of a control class to generate new sessions for each client. this class also registers itself with the java rmi server so that clients can find it. other additions include the introduction of secondary observers to automatically handle synchronization when either the client or server state changes. these observers are automatically added to observable subjects when the subjects are marshaled to be sent over the wire. through this mechanism, we can create custom objects that transparently handle client-server mode. in addition the system tries to maintain interactivity over a variety of connections by adjusting image quality and compression level to reflect the network speed. gui widgets the key to making it easy to write plugins that work in both standalone and client-server modes is that most communication is handled transparently through custom gui widgets. these widgets are based on the architecture of java swing, and they therefore follow modified model-view-controller and observer patterns. while each widget can have any number of observers, in mindseer observers usually are of two types. the first types are controllers, which handle events from the user and initiate changes in the scene. the second types are the synchronization listeners that are automatically added as the widgets are marshaled. each synchronization listener monitors a copy of the widget for any property changes, and when they occur, the changes are propagated across the network. additionally, in order to leverage the java library, the widgets generate swing objects for display. user interface the user interface is designed to maximize consistency. everything has a well-defined place, corresponding to the gui classes in figure the viewport containing the scene is flanked by the library view on the left and the scene controls on the right, which are in turn divided into two tabs: data and view. the data tab contains controls for the appearance of an individual file within a scene. these controls can affect color, transparency, location, or other attributes. additionally, since some files can be edited, this group of controls can be locked or unlocked by activating an "edit" mode. the view tab, on the other hand, controls the appearance of the whole scene, including the order that volumes are stacked, the camera parameters, and the location and extent of a wedge cut out of a surface. the library view is also kept visible and is intuitively interactive. the tree supports drag-and-drop for rearranging the library and transparently altering metadata, as well as drag-and-drop for adding files to existing scenes. to maximize user friendliness, mindseer also provides several standard menus where preferences can be adjusted and changes undone.  in this section we demonstrate the range of mindseer features by presenting a number of example case studies. tutorials or demos of several of these use cases are presented on the website. visualizing mri, fmri and source localized eeg the focus of the system from the beginning has been to build rich scenes with diverse sources of data. such data integration provides a qualitative feel for how different functional modalities interrelate and how they relate to the underlying structure. in order to test this capability, we obtained image volumes from three different imaging modalities: structural mri, fmri, and source localized eeg. we then displayed these volumes in a set of complex scenes. from the structural mri we also derived the cortical surface and masks of the brain. the initial step was to build a library that had all the files, which was done by using the file menu to define a new library based on a template, and to add new image files in their proper location in the template. after placing each file into the library, we built a 2-d or 3-d scene by dragging an icon representing each desired data file from the library into a 2-d or 3-d viewport. the first such scene is a simple slice view with the structural mri as a base and the fmri and eeg each shown in different colors. the second scene is in 3-d. the scene starts on a base of the cortical surface. when we added the first functional volume to the surface the system used the library to automatically add the structural mri and masks as it cut out the wedge. to achieve the final image, we generated 3-d isosurfaces of the functional data in order to pinpoint activation. this entire scene was generated quickly and painlessly. since mindseer is compatible with tools researchers already use for analysis and segmentation, the addition of multimodality visualization is not an undue burden. plotting 3-d points from a 2-d photograph another feature of the system allows the user to indicate the 3-d locations of cortical landmarks on a displayed brain surface, in the process generating the xml map file described earlier. in our own work we use this feature to visually map the locations of labels from a surgical photograph onto a 3-d surface rendering of the patient's own brain. the labels on the photograph show the locations where areas of exposed cortex were electrically simulated during a procedure called cortical stimulation mapping, which is used during neurosurgery to map the locations of language-sensitive cortex. by mapping these csm sites to the patient's own brain and later to a normalized brain atlas we can relate them to other brain mapping data such as fmri or single unit recording. the first step in this procedure was to use spm to create a mask volume that strips away the skull from an mri structural image volume, and to use the mask to generate a 3-d cortical surface. given these data files we created a mindseer library pointing to these files, as well as the surgical photograph, the structural mri image volume, and an mri venogram showing cortical veins. the veins, in conjunction with sulci and gyri, are useful landmarks for the visual mapping procedure. within mindseer we then used the venogram and the mask generated in the first step to create a 3-d surface reconstruction of the patient's veins. this surface was added to a mindseer scene showing the cortex and veins, which was displayed alongside the surgical photograph. the final step was to use the mouse to indicate the locations on the 3-d surface that correspond to the csm sites shown on the photograph. the resulting dataset was then saved as an xml map file. this overall plotting process is similar to our earlier visual brain mapper, but has mindseer's advantages of portability, remote access, and integration with analysis applications. remote visualization an important concern for us from the beginning has been remote visualization. over several years of research we have accumulated a repository and associated database with mri, csm and fmri data from over patients. our collaborators need to be able to visualize this plethora of data without the added effort of downloading or organizing hundreds of gigabytes of files. to accomplish this, we harness the client-server mode of mindseer. in this case the server accesses an xml library that is automatically generated from the output of our x-batch program. x-batch is a plugin for spm that transparently generates a database describing the locations of the structural and functional image files, accumulating multiple runs in a single file that is periodically converted to the mindseer xml library format. thus, the central repository is automatically updated whenever new mri images are processed, thereby making these images immediately available for remote viewing in mindseer. a demo of this capability for a sample dataset can be found on the project website. when run in client-server mode the client-side user interface looks exactly like the interface for the standalone version. the only difference is in frame rates. while the client-server version lacks the fluidity of the standalone version, it is still quite interactive, with frame rates of around per second over a cable modem. integration within a larger information system as part of our human brain project work our group has created several local laboratory information management systems to manage various types of multi-modality brain imaging data. these databases include the x-batch xml database for managing mri data processed by spm, as well as separate relational databases for cortical stimulation mapping and single unit recording data. these separate databases are encapsulated in web services that accept queries in the xml query language xquery. a distributed xquery processor accepts queries over one or more of these data sources, sends individual query fragments to the separate data sources, and packages the separate results into a single xml file. a web-based application called dxbrain allows the user to formulate distributed xqueries and visualize the returned xml result in various ways, including raw xml, html and 3-d. when the user requests a 3-d visualization of the returned data, dxbrain reformulates the returned xml results as a mindseer library file, and automatically displays the results on a choice of 3-d surfaces – either a canonical brain surface to which all data have been normalized, or a patient-specific cortical surface from our repository. for the canonical brain surface the system downloads the data and launches mindseer in standalone mode through a java web start link. the download for the canonical surface only happens the first time mindseer is launched, so the extra speed and interactivity of standalone mode makes this small download worth the extra time. however, when the user selects a brain from our repository, the required download for each subject would be too large and expensive. therefore, we use the versatility of client-server mode for visualizing data on a single subject. the two different modes are transparent to the user except for the slower response time in client-server mode. the ability to dynamically visualize query results with a single click of a web link has proved to be an invaluable tool for our collaborators, who can quickly adapt and refine queries to highlight the results in which they are interested. it has also proven to be a thorough test of mindseer, as it has routinely and successfully been used on mac, linux and windows systems with various hardware and browser configurations. extending mindseer to test the extensibility of mindseer a computer science undergraduate student,, wrote a series of plugins as a senior thesis project. the goal of this work was to explore ways to highlight the cortical surface with functional data sources. the final result added the capability to color cortical surfaces with functional data like fmri or source localized eeg. in order to integrate his algorithms as plugins he needed to implement two subclasses of the abstract plugin classes- a data wrapper around a volume data model to add new visualization capabilities, and a custom viewport controller. the wrapper binds his surface coloring algorithms, the volume data model and the underlying cortical surface data model. the custom controller allows the user to specify the exact surface coloring algorithm, as well as how multiple functional volumes interact. the new data volume wrapper made it easy to leverage existing decoders for surface and volume data, as well as the corresponding data models. it also made it possible for his subsystem to handle new decoders for volumetric data without modification. furthermore, by using the specialized gui widgets in his controller, his subsystem was able to work in client-server mode without additional effort. the default user interface layout also made it so that his controls naturally work with the existing interface. the end result is that much of his time was spent experimenting with visualization algorithms instead of reinventing the wheel. discussion these five case studies show that mindseer achieves the ten design goals previously described. the achievement of these goals provides a basis for future enhancements. in particular, the plugin mechanism should allow an undergraduate-level computer science or similar student to add new image modalities and visualization approaches with relative ease. for example, the ability to plot points could be extended to draw curves and to calculate areas, as in the measure program. furthermore, there is nothing in the code that restricts mindseer to functional brain imaging data; with proper file encoders and decoders or external file converters, the system should be able to display gene expression data on developmental atlases such as the mouse, and with new data model plugins should be able to display 3-d molecular structures. other data that can be placed in a or 4d grid could be visualized using mindseer. these include computed tomography, among others. additionally, while mindseer's default units are in millimeters, the units can be configured to display sub-millimeter data such as μmri, optical projection tomography, episcopic fluorescence image capture and confocal microscopy. other possible enhancements include the ability to display 4-d data via animations or a time slider in the 3-d viewport; the ability to complement the java web start client with an ajax style client similar to google maps, thereby eliminating all setup requirements; the ability to click on regions of the 3-d brain and send queries to the backend databases, thereby allowing mindseer to be a visual query interface as well as a display interface; the ability to generate 3-d reconstructions from serial sections; and the ability to generate interactive anatomical scenes for anatomy education. we believe that the addition of each of these features would be relatively straightforward because of mindseer's modular and extensible architecture, all of which is open source.  in this paper we have presented mindseer, a new application for visualizing multimodality neuroimaging data that is extensible to other biomedical data as well. although there are many 3-d visualization programs available, mindseer combines the best of many of them while retaining portability and extensibility. in addition, mindseer is free and open source, thereby making it a candidate for extension to the needs of specific user communities. availability and requirements • project name: mindseer • project home page: • operating system: windows, linux, mac • programming language: java, java3d • other requirements: java +, java3d • license: gpl • any restrictions to use by non-academics: none abbreviations 3-d – three-dimensional ajax – asynchronous javascript and xml csm – cortical stimulation mapping erp – event related potential fmri – functional magnetic resonance imaging gpl – gnu general public license gui – graphical user interface html – hypertext markup language mri – magnetic resonance imaging mvc – model-view-controller nifti – neuroimaging informatics technology initiative rmi – remote method invocation xml – extensible markup language competing interests the author declares that there are no competing interests. authors' contributions em – primary designer and implementer of mindseer, primary author of manuscript. ap – neuroscience user requirements, software tester, user and maintainer. pl – fmri surface coloring plugin. jb – lab director, problem and use case specifications, software tester, manuscript preparation, funding support. all authors have read and approved the final version of the manuscript. 
however, few if any of these combine both stand-alone and remote multi-modality visualization in an open source, portable and extensible tool that is easy to install and use, yet can be included as a component of a larger information system. we have developed a new open source multimodality 3-d visualization application, called mindseer, that has these features: integrated and interactive 3-d volume and surface visualization, java and java3d for true cross-platform portability, one-click installation and startup, integrated data management to help organize large studies, extensibility through plugins, transparent remote visualization, and the ability to be integrated into larger information management systems. a number of applications are available that include some aspect of 3-d visualization, including both free and commercial products. we describe the design and implementation of the system, as well as several case studies that demonstrate its utility. these case studies are available as tutorials or demos on the associated website:.
 three-dimensional visualization of multimodality neuroimaging data provides a powerful technique for viewing the relationship between structure and function. a number of applications are available that include some aspect of 3-d visualization, including both free and commercial products. these applications range from highly specific programs for a single modality, to general purpose toolkits that include many image processing functions in addition to visualization. however, few if any of these combine both stand-alone and remote multi-modality visualization in an open source, portable and extensible tool that is easy to install and use, yet can be included as a component of a larger information system.  we have developed a new open source multimodality 3-d visualization application, called mindseer, that has these features: integrated and interactive 3-d volume and surface visualization, java and java3d for true cross-platform portability, one-click installation and startup, integrated data management to help organize large studies, extensibility through plugins, transparent remote visualization, and the ability to be integrated into larger information management systems. we describe the design and implementation of the system, as well as several case studies that demonstrate its utility. these case studies are available as tutorials or demos on the associated website:.  mindseer provides a powerful visualization tool for multimodality neuroimaging data. its architecture and unique features also allow it to be extended into other visualization domains within biomedicine. 