mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-12 15:14:35 +00:00
virtuals removed
virtuals removed and replaced with override where necessary, clang-tidy to the rescue.
This commit is contained in:
parent
88a43f3137
commit
efbe5e90f5
255 changed files with 2164 additions and 2164 deletions
|
|
@ -39,8 +39,8 @@ class AssimpShapeLoader : public TSShapeLoader
|
|||
protected:
|
||||
const struct aiScene* mScene;
|
||||
|
||||
virtual bool ignoreNode(const String& name);
|
||||
virtual bool ignoreMesh(const String& name);
|
||||
bool ignoreNode(const String& name) override;
|
||||
bool ignoreMesh(const String& name) override;
|
||||
void detectDetails();
|
||||
void extractTexture(U32 index, aiTexture* pTex);
|
||||
|
||||
|
|
@ -58,11 +58,11 @@ public:
|
|||
~AssimpShapeLoader();
|
||||
|
||||
void releaseImport();
|
||||
void enumerateScene();
|
||||
void enumerateScene() override;
|
||||
void updateMaterialsScript(const Torque::Path &path);
|
||||
void processAnimations();
|
||||
|
||||
void computeBounds(Box3F& bounds);
|
||||
void computeBounds(Box3F& bounds) override;
|
||||
|
||||
bool fillGuiTreeView(const char* shapePath, GuiTreeViewCtrl* tree);
|
||||
|
||||
|
|
|
|||
|
|
@ -39,8 +39,8 @@ class ColladaAppNode : public AppNode
|
|||
friend class ColladaAppMesh;
|
||||
|
||||
MatrixF getTransform(F32 time);
|
||||
void buildMeshList();
|
||||
void buildChildList();
|
||||
void buildMeshList() override;
|
||||
void buildChildList() override;
|
||||
|
||||
protected:
|
||||
|
||||
|
|
@ -69,10 +69,10 @@ public:
|
|||
const domNode* getDomNode() const { return p_domNode; }
|
||||
|
||||
//-----------------------------------------------------------------------
|
||||
const char *getName() { return mName; }
|
||||
const char *getParentName() { return mParentName; }
|
||||
const char *getName() override { return mName; }
|
||||
const char *getParentName() override { return mParentName; }
|
||||
|
||||
bool isEqual(AppNode* node)
|
||||
bool isEqual(AppNode* node) override
|
||||
{
|
||||
const ColladaAppNode* appNode = dynamic_cast<const ColladaAppNode*>(node);
|
||||
return (appNode && (appNode->p_domNode == p_domNode));
|
||||
|
|
@ -80,21 +80,21 @@ public:
|
|||
|
||||
// Property look-ups: only float properties are stored, the rest are
|
||||
// converted from floats as needed
|
||||
bool getFloat(const char* propName, F32& defaultVal)
|
||||
bool getFloat(const char* propName, F32& defaultVal) override
|
||||
{
|
||||
Map<StringTableEntry,F32>::Iterator itr = mProps.find(propName);
|
||||
if (itr != mProps.end())
|
||||
defaultVal = itr->value;
|
||||
return false;
|
||||
}
|
||||
bool getInt(const char* propName, S32& defaultVal)
|
||||
bool getInt(const char* propName, S32& defaultVal) override
|
||||
{
|
||||
F32 value = defaultVal;
|
||||
bool ret = getFloat(propName, value);
|
||||
defaultVal = (S32)value;
|
||||
return ret;
|
||||
}
|
||||
bool getBool(const char* propName, bool& defaultVal)
|
||||
bool getBool(const char* propName, bool& defaultVal) override
|
||||
{
|
||||
F32 value = defaultVal;
|
||||
bool ret = getFloat(propName, value);
|
||||
|
|
@ -102,9 +102,9 @@ public:
|
|||
return ret;
|
||||
}
|
||||
|
||||
MatrixF getNodeTransform(F32 time);
|
||||
bool animatesTransform(const AppSequence* appSeq);
|
||||
bool isParentRoot() { return (appParent == NULL); }
|
||||
MatrixF getNodeTransform(F32 time) override;
|
||||
bool animatesTransform(const AppSequence* appSeq) override;
|
||||
bool isParentRoot() override { return (appParent == NULL); }
|
||||
};
|
||||
|
||||
#endif // _COLLADA_APPNODE_H_
|
||||
|
|
|
|||
|
|
@ -47,10 +47,10 @@ public:
|
|||
ColladaShapeLoader(domCOLLADA* _root);
|
||||
~ColladaShapeLoader();
|
||||
|
||||
void enumerateScene();
|
||||
bool ignoreNode(const String& name);
|
||||
bool ignoreMesh(const String& name);
|
||||
void computeBounds(Box3F& bounds);
|
||||
void enumerateScene() override;
|
||||
bool ignoreNode(const String& name) override;
|
||||
bool ignoreMesh(const String& name) override;
|
||||
void computeBounds(Box3F& bounds) override;
|
||||
|
||||
static bool canLoadCachedDTS(const Torque::Path& path);
|
||||
static bool checkAndMountSketchup(const Torque::Path& path, String& mountPoint, Torque::Path& daePath);
|
||||
|
|
|
|||
|
|
@ -672,14 +672,14 @@ public:
|
|||
}
|
||||
|
||||
/// Most primitives can use these common implementations
|
||||
const char* getElementName() { return primitive->getElementName(); }
|
||||
const char* getMaterial() { return (FindMatch::isMatchMultipleExprs(ColladaUtils::getOptions().neverImportMat, primitive->getMaterial(), false)) ? NULL : primitive->getMaterial(); }
|
||||
const domInputLocalOffset_Array& getInputs() { return primitive->getInput_array(); }
|
||||
S32 getStride() const { return stride; }
|
||||
const char* getElementName() override { return primitive->getElementName(); }
|
||||
const char* getMaterial() override { return (FindMatch::isMatchMultipleExprs(ColladaUtils::getOptions().neverImportMat, primitive->getMaterial(), false)) ? NULL : primitive->getMaterial(); }
|
||||
const domInputLocalOffset_Array& getInputs() override { return primitive->getInput_array(); }
|
||||
S32 getStride() const override { return stride; }
|
||||
|
||||
/// Each supported primitive needs to implement this method (and convert
|
||||
/// to triangles if required)
|
||||
const domListOfUInts *getTriangleData() { return NULL; }
|
||||
const domListOfUInts *getTriangleData() override { return NULL; }
|
||||
};
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
|
|
|
|||
|
|
@ -182,7 +182,7 @@ protected:
|
|||
void install();
|
||||
|
||||
public:
|
||||
TSShapeLoader() : boundsNode(0), shape(NULL) { }
|
||||
TSShapeLoader() : shape(NULL), boundsNode(0) { }
|
||||
virtual ~TSShapeLoader();
|
||||
|
||||
static const Torque::Path& getShapePath() { return shapePath; }
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ class TSMaterialList : public MaterialList
|
|||
TSMaterialList();
|
||||
TSMaterialList(const TSMaterialList*);
|
||||
~TSMaterialList();
|
||||
void free();
|
||||
void free() override;
|
||||
|
||||
U32 getFlags(U32 index);
|
||||
void setFlags(U32 index, U32 value);
|
||||
|
|
@ -91,7 +91,7 @@ class TSMaterialList : public MaterialList
|
|||
/// @}
|
||||
|
||||
protected:
|
||||
virtual void mapMaterial( U32 index );
|
||||
void mapMaterial( U32 index ) override;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -552,17 +552,17 @@ public:
|
|||
void setupVertexTransforms();
|
||||
|
||||
/// Returns maximum bones used per vertex
|
||||
virtual U32 getMaxBonesPerVert();
|
||||
U32 getMaxBonesPerVert() override;
|
||||
|
||||
virtual void convertToVertexData();
|
||||
virtual void copySourceVertexDataFrom(const TSMesh* srcMesh);
|
||||
void convertToVertexData() override;
|
||||
void copySourceVertexDataFrom(const TSMesh* srcMesh) override;
|
||||
|
||||
void printVerts();
|
||||
|
||||
void addWeightsFromVertexBuffer();
|
||||
|
||||
void makeEditable();
|
||||
void clearEditable();
|
||||
void makeEditable() override;
|
||||
void clearEditable() override;
|
||||
|
||||
public:
|
||||
typedef TSMesh Parent;
|
||||
|
|
@ -587,24 +587,24 @@ public:
|
|||
void updateSkinBones( const Vector<MatrixF> &transforms, Vector<MatrixF>& destTransforms );
|
||||
|
||||
// render methods..
|
||||
void render( TSVertexBufferHandle &instanceVB );
|
||||
void render( TSVertexBufferHandle &instanceVB ) override;
|
||||
void render( TSMaterialList *,
|
||||
const TSRenderState &data,
|
||||
bool isSkinDirty,
|
||||
const Vector<MatrixF> &transforms,
|
||||
TSVertexBufferHandle &vertexBuffer,
|
||||
const char *meshName );
|
||||
const char *meshName ) override;
|
||||
|
||||
// collision methods...
|
||||
bool buildPolyList( S32 frame, AbstractPolyList *polyList, U32 &surfaceKey, TSMaterialList *materials );
|
||||
bool castRay( S32 frame, const Point3F &start, const Point3F &end, RayInfo *rayInfo, TSMaterialList *materials );
|
||||
bool buildConvexHull(); // does nothing, skins don't use this
|
||||
bool buildPolyList( S32 frame, AbstractPolyList *polyList, U32 &surfaceKey, TSMaterialList *materials ) override;
|
||||
bool castRay( S32 frame, const Point3F &start, const Point3F &end, RayInfo *rayInfo, TSMaterialList *materials ) override;
|
||||
bool buildConvexHull() override; // does nothing, skins don't use this
|
||||
|
||||
void computeBounds( const MatrixF &transform, Box3F &bounds, S32 frame, Point3F *center, F32 *radius );
|
||||
void computeBounds( const MatrixF &transform, Box3F &bounds, S32 frame, Point3F *center, F32 *radius ) override;
|
||||
|
||||
/// persist methods...
|
||||
void assemble( bool skip );
|
||||
void disassemble();
|
||||
void assemble( bool skip ) override;
|
||||
void disassemble() override;
|
||||
|
||||
/// Helper method to add a blend tuple for a vertex
|
||||
inline void addWeightForVert(U32 vi, U32 bi, F32 w)
|
||||
|
|
|
|||
|
|
@ -212,12 +212,12 @@ public:
|
|||
static TSShapeConstructor* findShapeConstructorByAssetId(StringTableEntry path);
|
||||
static TSShapeConstructor* findShapeConstructorByFilename(const FileName& path);
|
||||
|
||||
bool onAdd();
|
||||
bool onAdd() override;
|
||||
|
||||
void onScriptChanged(const Torque::Path& path);
|
||||
void onActionPerformed();
|
||||
|
||||
bool writeField(StringTableEntry fieldname, const char* value);
|
||||
bool writeField(StringTableEntry fieldname, const char* value) override;
|
||||
void writeChangeSet();
|
||||
|
||||
void notifyShapeChanged();
|
||||
|
|
|
|||
|
|
@ -176,11 +176,11 @@ class TSShapeInstance
|
|||
MeshObjectInstance();
|
||||
virtual ~MeshObjectInstance() {}
|
||||
|
||||
void render( S32 objectDetail, TSVertexBufferHandle &vb, TSMaterialList *, TSRenderState &rdata, F32 alpha, const char *meshName );
|
||||
void render( S32 objectDetail, TSVertexBufferHandle &vb, TSMaterialList *, TSRenderState &rdata, F32 alpha, const char *meshName ) override;
|
||||
|
||||
void updateVertexBuffer( S32 objectDetail, U8 *buffer );
|
||||
void updateVertexBuffer( S32 objectDetail, U8 *buffer ) override;
|
||||
|
||||
bool bufferNeedsUpdate(S32 objectDetail);
|
||||
bool bufferNeedsUpdate(S32 objectDetail) override;
|
||||
|
||||
/// Gets the mesh with specified detail level
|
||||
TSMesh * getMesh(S32 num) const { return num<object->numMeshes ? *(meshList+num) : NULL; }
|
||||
|
|
@ -188,15 +188,15 @@ class TSShapeInstance
|
|||
/// @name Collision Routines
|
||||
/// @{
|
||||
|
||||
bool buildPolyList( S32 objectDetail, AbstractPolyList *polyList, U32 &surfaceKey, TSMaterialList *materials );
|
||||
bool getFeatures( S32 objectDetail, const MatrixF &mat, const Point3F &n, ConvexFeature *feature, U32 &surfaceKey );
|
||||
void support( S32 od, const Point3F &v, F32 *currMaxDP, Point3F *currSupport );
|
||||
bool castRay( S32 objectDetail, const Point3F &start, const Point3F &end, RayInfo *info, TSMaterialList *materials );
|
||||
bool buildPolyList( S32 objectDetail, AbstractPolyList *polyList, U32 &surfaceKey, TSMaterialList *materials ) override;
|
||||
bool getFeatures( S32 objectDetail, const MatrixF &mat, const Point3F &n, ConvexFeature *feature, U32 &surfaceKey ) override;
|
||||
void support( S32 od, const Point3F &v, F32 *currMaxDP, Point3F *currSupport ) override;
|
||||
bool castRay( S32 objectDetail, const Point3F &start, const Point3F &end, RayInfo *info, TSMaterialList *materials ) override;
|
||||
bool castRayRendered( S32 objectDetail, const Point3F &start, const Point3F &end, RayInfo *info, TSMaterialList *materials );
|
||||
|
||||
bool buildPolyListOpcode( S32 objectDetail, AbstractPolyList *polyList, const Box3F &box, TSMaterialList* materials );
|
||||
bool castRayOpcode( S32 objectDetail, const Point3F &start, const Point3F &end, RayInfo *info, TSMaterialList *materials );
|
||||
bool buildConvexOpcode( const MatrixF &mat, S32 objectDetail, const Box3F &bounds, Convex *c, Convex *list );
|
||||
bool castRayOpcode( S32 objectDetail, const Point3F &start, const Point3F &end, RayInfo *info, TSMaterialList *materials ) override;
|
||||
bool buildConvexOpcode( const MatrixF &mat, S32 objectDetail, const Box3F &bounds, Convex *c, Convex *list ) override;
|
||||
|
||||
/// @}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue