|
1 /* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ |
|
2 /* This Source Code Form is subject to the terms of the Mozilla Public |
|
3 * License, v. 2.0. If a copy of the MPL was not distributed with this |
|
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
|
5 |
|
6 #include "assert.h" |
|
7 #include "ANPBase.h" |
|
8 #include <android/log.h> |
|
9 |
|
10 #define LOG(args...) __android_log_print(ANDROID_LOG_INFO, "GeckoPlugins" , ## args) |
|
11 #define ASSIGN(obj, name) (obj)->name = anp_matrix_##name |
|
12 |
|
13 /** Return a new identity matrix |
|
14 */ |
|
15 ANPMatrix* |
|
16 anp_matrix_newMatrix() |
|
17 { |
|
18 NOT_IMPLEMENTED(); |
|
19 return 0; |
|
20 } |
|
21 |
|
22 /** Delete a matrix previously allocated by newMatrix() |
|
23 */ |
|
24 void |
|
25 anp_matrix_deleteMatrix(ANPMatrix*) |
|
26 { |
|
27 NOT_IMPLEMENTED(); |
|
28 } |
|
29 |
|
30 |
|
31 ANPMatrixFlag |
|
32 anp_matrix_getFlags(const ANPMatrix*) |
|
33 { |
|
34 NOT_IMPLEMENTED(); |
|
35 return 0; |
|
36 } |
|
37 |
|
38 |
|
39 void |
|
40 anp_matrix_copy(ANPMatrix* dst, const ANPMatrix* src) |
|
41 { |
|
42 NOT_IMPLEMENTED(); |
|
43 } |
|
44 |
|
45 |
|
46 void |
|
47 anp_matrix_get3x3(const ANPMatrix*, float[9]) |
|
48 { |
|
49 NOT_IMPLEMENTED(); |
|
50 } |
|
51 |
|
52 void |
|
53 anp_matrix_set3x3(ANPMatrix*, const float[9]) |
|
54 { |
|
55 NOT_IMPLEMENTED(); |
|
56 } |
|
57 |
|
58 |
|
59 void |
|
60 anp_matrix_setIdentity(ANPMatrix*) |
|
61 { |
|
62 NOT_IMPLEMENTED(); |
|
63 } |
|
64 |
|
65 void |
|
66 anp_matrix_preTranslate(ANPMatrix*, float tx, float ty) |
|
67 { |
|
68 NOT_IMPLEMENTED(); |
|
69 } |
|
70 |
|
71 void |
|
72 anp_matrix_postTranslate(ANPMatrix*, float tx, float ty) |
|
73 { |
|
74 NOT_IMPLEMENTED(); |
|
75 } |
|
76 |
|
77 void |
|
78 anp_matrix_preScale(ANPMatrix*, float sx, float sy) |
|
79 { |
|
80 NOT_IMPLEMENTED(); |
|
81 } |
|
82 |
|
83 void |
|
84 anp_matrix_postScale(ANPMatrix*, float sx, float sy) |
|
85 { |
|
86 NOT_IMPLEMENTED(); |
|
87 } |
|
88 |
|
89 void |
|
90 anp_matrix_preSkew(ANPMatrix*, float kx, float ky) |
|
91 { |
|
92 NOT_IMPLEMENTED(); |
|
93 } |
|
94 |
|
95 void |
|
96 anp_matrix_postSkew(ANPMatrix*, float kx, float ky) |
|
97 { |
|
98 NOT_IMPLEMENTED(); |
|
99 } |
|
100 |
|
101 void |
|
102 anp_matrix_preRotate(ANPMatrix*, float degrees) |
|
103 { |
|
104 NOT_IMPLEMENTED(); |
|
105 } |
|
106 |
|
107 void |
|
108 anp_matrix_postRotate(ANPMatrix*, float degrees) |
|
109 { |
|
110 NOT_IMPLEMENTED(); |
|
111 } |
|
112 |
|
113 void |
|
114 anp_matrix_preConcat(ANPMatrix*, const ANPMatrix*) |
|
115 { |
|
116 NOT_IMPLEMENTED(); |
|
117 } |
|
118 |
|
119 void |
|
120 anp_matrix_postConcat(ANPMatrix*, const ANPMatrix*) |
|
121 { |
|
122 NOT_IMPLEMENTED(); |
|
123 } |
|
124 |
|
125 |
|
126 bool |
|
127 anp_matrix_invert(ANPMatrix* dst, const ANPMatrix* src) |
|
128 { |
|
129 NOT_IMPLEMENTED(); |
|
130 return false; |
|
131 } |
|
132 |
|
133 void |
|
134 anp_matrix_mapPoints(ANPMatrix*, float dst[], const float src[], |
|
135 int32_t count) |
|
136 { |
|
137 NOT_IMPLEMENTED(); |
|
138 } |
|
139 |
|
140 |
|
141 void InitMatrixInterface(ANPMatrixInterfaceV0 *i) { |
|
142 _assert(i->inSize == sizeof(*i)); |
|
143 ASSIGN(i, newMatrix); |
|
144 ASSIGN(i, deleteMatrix); |
|
145 ASSIGN(i, getFlags); |
|
146 ASSIGN(i, copy); |
|
147 ASSIGN(i, get3x3); |
|
148 ASSIGN(i, set3x3); |
|
149 ASSIGN(i, setIdentity); |
|
150 ASSIGN(i, preTranslate); |
|
151 ASSIGN(i, postTranslate); |
|
152 ASSIGN(i, preScale); |
|
153 ASSIGN(i, postScale); |
|
154 ASSIGN(i, preSkew); |
|
155 ASSIGN(i, postSkew); |
|
156 ASSIGN(i, preRotate); |
|
157 ASSIGN(i, postRotate); |
|
158 ASSIGN(i, preConcat); |
|
159 ASSIGN(i, postConcat); |
|
160 ASSIGN(i, invert); |
|
161 ASSIGN(i, mapPoints); |
|
162 } |
|
163 |
|
164 |