Graphics |
Overview
MATLAB automatically selects the best renderer based on the complexity of the graphics objects and the options available on your system.
More Details
A renderer is the software that processes graphics data (such as vertex coordinates) into a form that MATLAB can use to draw into the figure. MATLAB supports three renderers:
Painters
Painters method is faster when the figure contains only simple or small graphics. It cannot be used with lighting.
Z-Buffer
Z-buffering is the process of determining how to render each pixel by drawing only the front-most object, as opposed to drawing all objects back to front, redrawing objects that obscure those behind. The pixel data is buffered and then blitted to the screen all at once.
Z-buffering is generally faster for more complex graphics, but can be slower for very simple graphics. You can set the Renderer
property to whatever produces the fastest drawing (either zbuffer
or painters
), or let MATLAB decide which method to use by setting the RendererMode
property to auto
(the default).
Printing from Z-Buffer. You can select the resolution of the PostScript file produced by the print
command using the -r
option. By default, MATLAB prints Z-buffered figures at a medium resolution of 150 dpi (the default with Renderer
set to painters
is 864 dpi).
The size of the file generated from a Z-buffer figure does not depend on its contents, just the size of the figure. To decrease the file size, make the PaperPosition
property smaller before printing (or set PaperPositionMode
to auto
and resize the figure window).
OpenGL
OpenGL is available on many computer systems. It is generally faster than either painters or Z-buffer and in some cases enables MATLAB to use the system's graphics hardware (which results in significant speed increase). See the figure Renderer
property for more information.
Limitations of OpenGL. OpenGL has two limitations when compared to painters and Z-buffer:
Double Buffering | Specifying the Figure Pointer |
© 1994-2005 The MathWorks, Inc.