[Bf-blender-cvs] [1ba0afc] soc-2014-bge: gameengine scenegraph: whitespace and comment cleanup - KX_VertexParentRelation
Ines Almeida
noreply at git.blender.org
Sat Jul 19 03:41:50 CEST 2014
Commit: 1ba0afc58eda6cc15de94389bd9c4fdb83011454
Author: Ines Almeida
Date: Mon Jul 14 13:41:07 2014 +0100
https://developer.blender.org/rB1ba0afc58eda6cc15de94389bd9c4fdb83011454
gameengine scenegraph: whitespace and comment cleanup - KX_VertexParentRelation
===================================================================
M source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp
M source/gameengine/Ketsji/KX_SG_NodeRelationships.h
===================================================================
diff --git a/source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp b/source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp
index 7e734ac..6099220 100644
--- a/source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp
+++ b/source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp
@@ -100,25 +100,16 @@ KX_NormalParentRelation::KX_NormalParentRelation()
*/
- KX_VertexParentRelation *
-KX_VertexParentRelation::
-New(
-) {
+KX_VertexParentRelation* KX_VertexParentRelation::New()
+{
return new KX_VertexParentRelation();
}
-
+
/**
* Method inherited from KX_ParentRelation
*/
-
- bool
-KX_VertexParentRelation::
-UpdateChildCoordinates(
- SG_Spatial * child,
- const SG_Spatial * parent,
- bool& parentUpdated
-) {
-
+bool KX_VertexParentRelation::UpdateChildCoordinates(SG_Spatial *child, const SG_Spatial *parent, bool &parentUpdated)
+{
MT_assert(child != NULL);
if (!parentUpdated && !child->IsModified())
@@ -139,28 +130,23 @@ UpdateChildCoordinates(
/**
* Method inherited from KX_ParentRelation
*/
-
- SG_ParentRelation *
-KX_VertexParentRelation::
-NewCopy(
-) {
+SG_ParentRelation* KX_VertexParentRelation::NewCopy()
+{
return new KX_VertexParentRelation();
-};
+}
-KX_VertexParentRelation::
-~KX_VertexParentRelation(
-) {
+KX_VertexParentRelation::~KX_VertexParentRelation()
+{
//nothing to do
}
-
-KX_VertexParentRelation::
-KX_VertexParentRelation(
-) {
+KX_VertexParentRelation::KX_VertexParentRelation()
+{
//nothing to do
}
+
/**
* Slow parent relationship
*/
diff --git a/source/gameengine/Ketsji/KX_SG_NodeRelationships.h b/source/gameengine/Ketsji/KX_SG_NodeRelationships.h
index 3b3f499..38157b4 100644
--- a/source/gameengine/Ketsji/KX_SG_NodeRelationships.h
+++ b/source/gameengine/Ketsji/KX_SG_NodeRelationships.h
@@ -86,47 +86,33 @@ class KX_VertexParentRelation : public SG_ParentRelation
public :
/**
- * Allocate and construct a new KX_VertexParentRelation
- * on the heap.
+ * Allocate and construct a new KX_VertexParentRelation on the heap.
*/
-
- static
- KX_VertexParentRelation *
- New(
- );
+ static KX_VertexParentRelation* New();
/**
* Method inherited from KX_ParentRelation
+ * Update the child's global coordinates based upon the local ones and the parent's global coordinates.
*/
-
- bool
- UpdateChildCoordinates(
- SG_Spatial * child,
- const SG_Spatial * parent,
- bool& parentUpdated
- );
+ bool UpdateChildCoordinates(SG_Spatial *child, const SG_Spatial *parent, bool &parentUpdated);
/**
* Method inherited from KX_ParentRelation
+ * This should return a pointer to a new duplicate allocated on the heap.
+ * Responsibility for deleting the duplicate resides with the caller of this method.
*/
-
- SG_ParentRelation *
- NewCopy(
- );
+ SG_ParentRelation * NewCopy();
- ~KX_VertexParentRelation(
- );
+ ~KX_VertexParentRelation();
- bool
- IsVertexRelation(
- ) {
+ bool IsVertexRelation()
+ {
return true;
}
private :
- KX_VertexParentRelation(
- );
+ KX_VertexParentRelation();
#ifdef WITH_CXX_GUARDEDALLOC
More information about the Bf-blender-cvs
mailing list