Io::RendererViewport class reference
[Core module]

Declaration  

#include <Goptical/Io/RendererViewport>

namespace Goptical {
namespace Io {
class RendererViewport;
};
};

This class is a member of the Io namespace.

This abstract class contains pure virtuals.

Inheritance  

Description  

This class defines an interface for rendering drivers which rely on viewport windows, scaling and 2d projection operations. It's designed to be used as a base class for such renderers; this mainly includes pixel based output renderers.

Renderers which write output in vector format in world coordinates directly do not need this class as base.

Members  

See also the full member list section for this class.

Inherited members  

Functions  

Members detail  

RendererViewport()  

No documentation available

virtual void draw_pages_grid(const Rgb &rgb = rgb_gray)  

Draw separations between pages, output window must have been setup before.

virtual Math::Transform<3> get_camera_transform() const = 0;  

Get reference to 3d camera transform

double get_fov() const  

Get field of view in degrees.

See also set_fov function.

const Math::VectorPair2 & get_window() const  

Get current viewport window

virtual void set_2d_size(double width, double height)  

Update 2d output size, not all drivers support this

void set_camera_direction(const Math::Vector3 &dir)  

Set 3d camera rotation from direction vector

void set_camera_position(const Math::Vector3 &pos)  

Set 3d camera rotation from direction vector

virtual void set_camera_transform(const Math::Transform<3> &t) = 0;  

Get modifiable reference to 3d camera transform

void set_fov(double fov)  

Set field of view in degrees.

See also get_fov function.

void set_margin(double left, double bottom, double right, double top)  

Set amount of 2d margin space for set_window operation in world coordinates units.

void set_margin(double width, double height)  

See set_margin function.

void set_margin_output(double left, double bottom, double right, double top)  

Set amount of 2d margin space for set_window operation in output size units (usually pixels).

void set_margin_output(double width, double height)  

See set_margin_output function.

void set_margin_ratio(double left, double bottom, double right, double top)  

Set amount of 2d margin space for set_window operation as ratio of window.

void set_margin_ratio(double width, double height)  

See set_margin_ratio function.

void set_numeric_format(std::ios_base::fmtflags format, unsigned int precision)  

Set format used to print numeric values

virtual void set_page(unsigned int page)  

Select current page when multiple pages layout is in use.

See also set_page_layout function.

virtual void set_page_layout(unsigned int cols, unsigned int rows)  

This function can be used to setup a pages grid. Current output page must be selected with set_page.

virtual void set_perspective() = 0;  

Set 3d perspective projection mode. This function reset the viewport window to (-1,1).

See also set_window function and set_fov function.

virtual void set_window(const Math::Vector2 &center, const Math::Vector2 &size, bool keep_aspect = true)  

Set 2d viewport window. This function set 3d projection to orthographic.

void set_window(const Math::VectorPair2 &window, bool keep_aspect = true)  

Set 2d viewport window. This function set 3d projection to orthographic.

void set_window(const Math::Vector2 &center, double radius, bool keep_aspect = true)  

Set 2d viewport window. This function set 3d projection to orthographic.

Valid XHTML 1.0 StrictGenerated by diaxen on Sun Jan 8 00:47:24 2012 using MkDoc