Code covered by the BSD License  

Highlights from
Volume Browser, Release 1.03

image thumbnail
from Volume Browser, Release 1.03 by Eike Rietsch
GUI for visualization of data volumes via slices, contour lines, isosurfaces, and animation.

background_callback(varargin)
function background_callback(varargin)
% Change background color
%
% Modified by E. Rietsch: October 15, 2006

handles=varargin{3};

global V3D_HANDLES

figure_handle=V3D_HANDLES.figure_handle;

axis_handle=get(figure_handle,'CurrentAxes');

%	Switch from white to black background and vice versa
whitebg(figure_handle);

%       Check background color
if mean(get(axis_handle,'color'))==0 
   set(handles.bgschwarz,'Value',1);
else
   set(handles.bgschwarz,'Value',0);
end

Contact us at files@mathworks.com