V-Gears 0
Free Final Fantasy VII engine.
DrawSkeleton.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2022 The V-Gears Team
3 *
4 * This file is part of V-Gears
5 *
6 * V-Gears is free software: you can redistribute it and/or modify it under
7 * terms of the GNU General Public License as published by the Free Software
8 * Foundation, version 3.0 (GPLv3) of the License.
9 *
10 * V-Gears is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 */
15
16#pragma once
17
18#include <Ogre.h>
19
23struct Bone{
24
28 Bone(): length(0), parent_id(-1){}
29
33 float length;
34
39};
40
41typedef std::vector<Bone> Skeleton;
42
49void DrawSkeleton(const Skeleton& skeleton, const Ogre::MeshPtr& mesh);
50
58void DrawBone(const Skeleton& skeleton, int parent_index, Ogre::RGBA* colours);
59
std::vector< Bone > Skeleton
Definition: DrawSkeleton.h:41
void DrawBone(const Skeleton &skeleton, int parent_index, Ogre::RGBA *colours)
Draws a bone.
Definition: DrawSkeleton.cpp:108
void DrawSkeleton(const Skeleton &skeleton, const Ogre::MeshPtr &mesh)
Draws a skeleton.
Definition: DrawSkeleton.cpp:50
A skeleton bone.
Definition: DrawSkeleton.h:23
Bone()
Initializer.
Definition: DrawSkeleton.h:28
int parent_id
Parent bone ID.
Definition: DrawSkeleton.h:38
float length
Bone length.
Definition: DrawSkeleton.h:33