[contrib] generic computeHkl method
[hkl.git] / hkl / hkl-quaternion-private.h
blob3489ba40f17b968e9ace0f2aea80592c5f3a2076
1 /* This file is part of the hkl library.
3 * The hkl library is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 3 of the License, or
6 * (at your option) any later version.
8 * The hkl library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
13 * You should have received a copy of the GNU General Public License
14 * along with the hkl library. If not, see <http://www.gnu.org/licenses/>.
16 * Copyright (C) 2003-2015 Synchrotron SOLEIL
17 * L'Orme des Merisiers Saint-Aubin
18 * BP 48 91192 GIF-sur-YVETTE CEDEX
20 * Authors: Picca Frédéric-Emmanuel <picca@synchrotron-soleil.fr>
22 #ifndef __HKL_QUATERNION_PRIVATE_H__
23 #define __HKL_QUATERNION_PRIVATE_H__
25 #include <stdio.h> // for FILE
26 #include "hkl.h" // for G_BEGIN_DECLS, etc
28 G_BEGIN_DECLS
30 extern HklQuaternion *hkl_quaternion_dup(const HklQuaternion* self);
32 extern void hkl_quaternion_free(HklQuaternion *self);
34 extern void hkl_quaternion_init(HklQuaternion *self,
35 double a, double b, double c, double d);
37 extern void hkl_quaternion_init_from_vector(HklQuaternion *self, const HklVector *v);
39 extern void hkl_quaternion_init_from_angle_and_axe(HklQuaternion *self,
40 double angle, const HklVector *v);
42 extern void hkl_quaternion_fprintf(FILE *file, const HklQuaternion *self);
44 extern int hkl_quaternion_cmp(const HklQuaternion *self, const HklQuaternion *q);
46 extern void hkl_quaternion_minus_quaternion(HklQuaternion *self,
47 const HklQuaternion *q);
49 extern void hkl_quaternion_times_quaternion(HklQuaternion *self,
50 const HklQuaternion *q);
52 extern double hkl_quaternion_norm2(const HklQuaternion *self);
54 extern void hkl_quaternion_conjugate(HklQuaternion *self);
56 extern void hkl_quaternion_to_matrix(const HklQuaternion *self, HklMatrix *m);
58 extern void hkl_quaternion_to_angle_and_axe(const HklQuaternion *self,
59 double *angle, HklVector *v);
61 G_END_DECLS
63 #endif