source: nanovis/branches/1.1/Grid.h @ 4923

Last change on this file since 4923 was 4904, checked in by ldelgass, 9 years ago

Merge serveral changes from trunk. Does not include threading, world space
changes, etc.

  • Property svn:eol-style set to native
File size: 1.1 KB
RevLine 
[2798]1/* -*- mode: c++; c-basic-offset: 4; indent-tabs-mode: nil -*- */
[3502]2/*
3 * Copyright (c) 2004-2013  HUBzero Foundation, LLC
4 *
5 */
[4889]6#ifndef NV_GRID_H
7#define NV_GRID_H
[776]8
[4904]9#include <vrmath/Vector3f.h>
[4890]10#include <vrmath/Color4f.h>
[2844]11
[932]12#include "Axis.h"
13#include "AxisRange.h"
[776]14
[4889]15namespace nv {
16
[4890]17namespace util {
18class Fonts;
19}
[2844]20
21class Grid
22{
23public:
24    Grid();
[2953]25    virtual ~Grid();
[776]26
[2844]27    bool isVisible() const
28    {
29        return _visible;
30    }
[932]31
[2844]32    void setVisible(bool visible)
33    {
34        _visible = visible;
[932]35    }
[2844]36
37    void setAxisColor(float r, float g, float b, float a)
38    {
[2910]39        _axisColor.set(r, g, b, a);
[934]40    }
[2844]41
42    void setLineColor(float r, float g, float b, float a)
43    {
[2910]44        _majorColor.set(r, g, b, a);
[2844]45        _minorColor = _majorColor;
[934]46    }
[2844]47
[862]48    void render();
[2844]49
[3463]50    void setFont(nv::util::Fonts *font);
[2844]51
[4904]52    void getBounds(vrmath::Vector3f& bboxMin,
53                   vrmath::Vector3f& bboxMax) const;
54
[2844]55    Axis xAxis;
56    Axis yAxis;
57    Axis zAxis;
58
59private:
[4890]60    vrmath::Color4f _axisColor, _majorColor, _minorColor;
[3463]61    nv::util::Fonts *_font;
[2844]62    bool _visible;
[776]63};
64
[4889]65}
[776]66
67#endif
Note: See TracBrowser for help on using the repository browser.