Motive Animation System
An open source project by FPL.
 All Classes Functions Variables Typedefs Friends Pages
flatbuffers.h
1 // Copyright 2014 Google Inc. All rights reserved.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 
15 #ifndef MOTIVE_IO_FLATBUFFERS_H_
16 #define MOTIVE_IO_FLATBUFFERS_H_
17 
18 namespace motive {
19 
20 class AnimTable;
21 class MatrixAnim;
22 struct MatrixAnimFb;
23 class OvershootInit;
24 struct OvershootParameters;
25 class RigAnim;
26 struct RigAnimFb;
27 class SplineInit;
28 struct SplineParameters;
29 struct Settled1f;
30 struct Settled1fParameters;
31 
32 /// Convert from FlatBuffer params to Motive init, for Overshoot.
33 void OvershootInitFromFlatBuffers(const OvershootParameters& params,
34  OvershootInit* init);
35 
36 /// Convert from FlatBuffer params to Motive init, for Spline.
37 void SplineInitFromFlatBuffers(const SplineParameters& params,
38  SplineInit* init);
39 
40 /// Convert from FlatBuffer params to Motive Settled1f.
41 void Settled1fFromFlatBuffers(const Settled1fParameters& params,
42  Settled1f* settled);
43 
44 /// Convert from FlatBuffer params to Motive MatrixAnim.
45 void MatrixAnimFromFlatBuffers(const MatrixAnimFb& params, bool repeat,
46  MatrixAnim* anim);
47 
48 /// Convert from FlatBuffer params to Motive MatrixAnim.
49 void RigAnimFromFlatBuffers(const RigAnimFb& params, RigAnim* anim);
50 
51 } // namespace motive
52 
53 #endif // MOTIVE_IO_FLATBUFFERS_H_