Open Broadcaster Software
Free, open source software for live streaming and recording
axisang.h
Go to the documentation of this file.
1
/******************************************************************************
2
Copyright (C) 2013 by Hugh Bailey <obs.jim@gmail.com>
3
4
This program is free software: you can redistribute it and/or modify
5
it under the terms of the GNU General Public License as published by
6
the Free Software Foundation, either version 2 of the License, or
7
(at your option) any later version.
8
9
This program is distributed in the hope that it will be useful,
10
but WITHOUT ANY WARRANTY; without even the implied warranty of
11
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
GNU General Public License for more details.
13
14
You should have received a copy of the GNU General Public License
15
along with this program. If not, see <http://www.gnu.org/licenses/>.
16
******************************************************************************/
17
18
#pragma once
19
20
#include "../util/c99defs.h"
21
22
#ifdef __cplusplus
23
extern
"C"
{
24
#endif
25
26
struct
quat
;
27
28
struct
axisang
{
29
union
{
30
struct
{
31
float
x
,
y
,
z
,
w
;
32
};
33
float
ptr
[4];
34
};
35
};
36
37
static
inline
void
axisang_zero(
struct
axisang
*dst)
38
{
39
dst->
x
= 0.0f;
40
dst->
y
= 0.0f;
41
dst->
z
= 0.0f;
42
dst->
w
= 0.0f;
43
}
44
45
static
inline
void
axisang_copy(
struct
axisang
*dst,
struct
axisang
*aa)
46
{
47
dst->
x
= aa->
x
;
48
dst->
y
= aa->
y
;
49
dst->
z
= aa->
z
;
50
dst->
w
= aa->
w
;
51
}
52
53
static
inline
void
axisang_set(
struct
axisang
*dst,
float
x,
float
y,
float
z,
54
float
w)
55
{
56
dst->
x
= x;
57
dst->
y
= y;
58
dst->
z
= z;
59
dst->
w
= w;
60
}
61
62
EXPORT
void
axisang_from_quat
(
struct
axisang
*dst,
const
struct
quat
*q);
63
64
#ifdef __cplusplus
65
}
66
#endif
axisang
Definition:
axisang.h:28
axisang::ptr
float ptr[4]
Definition:
axisang.h:33
axisang::w
float w
Definition:
axisang.h:31
axisang::z
float z
Definition:
axisang.h:31
axisang::y
float y
Definition:
axisang.h:31
EXPORT
#define EXPORT
Definition:
c99defs.h:49
axisang_from_quat
EXPORT void axisang_from_quat(struct axisang *dst, const struct quat *q)
quat
Definition:
quat.h:41
axisang::x
float x
Definition:
axisang.h:31
libobs
graphics
axisang.h
Generated on Sun Oct 13 2019 00:00:00 for Open Broadcaster Software by
1.8.15