~ubuntu-branches/debian/sid/coin2/sid

« back to all changes in this revision

Viewing changes to src/geo/SbGeoAngle.h

  • Committer: Bazaar Package Importer
  • Author(s): Steve M. Robbins
  • Date: 2008-06-28 02:38:17 UTC
  • mfrom: (1.2.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20080628023817-lgrh0u677j1gcqgf
Tags: 2.5.0-2
* debian/control: Change suggests from libopenal0 to libopenal0a.
  Closes: #488001.  Change ${Source-Version} to ${binary:Version}.
  Update to standards version 3.8.0.

* debian/rules: Do not ignore errors in clean rule.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#ifndef COIN_SBGEOANGLE_H
 
2
#define COIN_SBGEOANGLE_H
 
3
 
 
4
/**************************************************************************\
 
5
 *
 
6
 *  This file is part of the Coin 3D visualization library.
 
7
 *  Copyright (C) 1998-2007 by Systems in Motion.  All rights reserved.
 
8
 *
 
9
 *  This library is free software; you can redistribute it and/or
 
10
 *  modify it under the terms of the GNU General Public License
 
11
 *  ("GPL") version 2 as published by the Free Software Foundation.
 
12
 *  See the file LICENSE.GPL at the root directory of this source
 
13
 *  distribution for additional information about the GNU GPL.
 
14
 *
 
15
 *  For using Coin with software that can not be combined with the GNU
 
16
 *  GPL, and for taking advantage of the additional benefits of our
 
17
 *  support services, please contact Systems in Motion about acquiring
 
18
 *  a Coin Professional Edition License.
 
19
 *
 
20
 *  See http://www.coin3d.org/ for more information.
 
21
 *
 
22
 *  Systems in Motion, Postboks 1283, Pirsenteret, 7462 Trondheim, NORWAY.
 
23
 *  http://www.sim.no/  sales@sim.no  coin-support@coin3d.org
 
24
 *
 
25
\**************************************************************************/
 
26
 
 
27
class SbGeoAngle {
 
28
public:
 
29
 
 
30
  SbGeoAngle(const double d = 0.0);
 
31
  SbGeoAngle(const double deg,
 
32
             const double min,
 
33
             const double sec,
 
34
             const char direction = 'N');
 
35
 
 
36
  SbGeoAngle(const SbGeoAngle & ang);
 
37
 
 
38
  SbGeoAngle & operator=(const double d);
 
39
  SbGeoAngle & operator=(SbGeoAngle a);
 
40
 
 
41
  void setDegree(const int d);
 
42
 
 
43
  double rad(void) const;
 
44
  int    deg(void) const;
 
45
  int    minutes(void) const;
 
46
  double seconds(void) const;
 
47
 
 
48
  operator double() const { return this->rad(); }
 
49
 
 
50
  SbGeoAngle & operator+=(const SbGeoAngle & a);
 
51
  SbGeoAngle & operator-=(const SbGeoAngle & a);
 
52
  SbGeoAngle operator-() const;
 
53
  SbGeoAngle operator+(SbGeoAngle a) const;
 
54
  SbGeoAngle operator-(SbGeoAngle a) const;
 
55
  SbGeoAngle operator+(double d) const;
 
56
  SbGeoAngle operator-(double d) const;
 
57
  friend SbGeoAngle operator+(double d, SbGeoAngle a);
 
58
  friend SbGeoAngle operator-(double d, SbGeoAngle a);
 
59
 
 
60
  SbGeoAngle & operator*=(double d);
 
61
  SbGeoAngle operator*(double d) const;
 
62
  friend SbGeoAngle operator*(double d, SbGeoAngle a);
 
63
 
 
64
  SbGeoAngle & operator/=(double d);
 
65
  SbGeoAngle operator/(double d) const;
 
66
 
 
67
  bool operator==(const SbGeoAngle & p) const;
 
68
  bool operator!=(const SbGeoAngle & a) const;
 
69
 
 
70
  bool operator<(const SbGeoAngle & v) const;
 
71
  bool operator>(const SbGeoAngle & v) const;
 
72
  bool operator<=(const SbGeoAngle & v) const;
 
73
  bool operator>=(const SbGeoAngle & v) const;
 
74
 
 
75
private:
 
76
 
 
77
  double degrees(void) const;
 
78
  double a;
 
79
};
 
80
 
 
81
#endif // ANGLE_H