DriveHQ Start Menu
Cloud Drive Mapping
Folder Sync
Cloud Backup
True Drop Box
FTP/SFTP Hosting
Group Account
DriveHQ Start Menu
Online File Server
My Storage
|
Manage Shares
|
Publishes
|
Drop Boxes
|
Group Account
WebDAV Drive Mapping
Cloud Drive Home
|
WebDAV Guide
|
Drive Mapping Tool
|
Drive Mapping URL
Complete Data Backup
Backup Guide
|
Online Backup Tool
|
Cloud-to-Cloud Backup
FTP, Email & Web Service
FTP Home
|
FTP Hosting FAQ
|
Email Hosting
|
EmailManager
|
Web Hosting
Help & Resources
About
|
Enterprise Service
|
Partnership
|
Comparisons
|
Support
Quick Links
Security and Privacy
Download Software
Service Manual
Use Cases
Group Account
Online Help
Blog
Contact
Cloud Surveillance
Sign Up
Login
Features
Business Features
Online File Server
FTP Hosting
Cloud Drive Mapping
Cloud File Backup
Email Backup & Hosting
Cloud File Sharing
Folder Synchronization
Group Management
True Drop Box
Full-text Search
AD Integration/SSO
Mobile Access
IP Camera & DVR Solution
More...
Personal Features
Personal Cloud Drive
Backup All Devices
Mobile APPs
Personal Web Hosting
Sub-Account (for Kids)
Home/PC/Kids Monitoring
More...
Software
DriveHQ Drive Mapping Tool
DriveHQ FileManager
DriveHQ Online Backup
DriveHQ Mobile Apps
Pricing
Business Plans & Pricing
Personal Plans & Pricing
Price Comparison with Others
Feature Comparison with Others
Install Mobile App
Sign up
Creating account...
Invalid character in username! Only 0-9, a-z, A-Z, _, -, . allowed.
Username is required!
Invalid email address!
E-mail is required!
Password is required!
Password is invalid!
Password and confirmation do not match.
Confirm password is required!
I accept
Membership Agreement
Please read the Membership Agreement and check "I accept"!
Free Quick Sign-up
Sign-up Page
Log in
Signing in...
Username or e-mail address is required!
Password is required!
Keep me logged in
Quick Login
Forgot Password
Up
Upload
Download
Share
Publish
New Folder
New File
Copy
Cut
Delete
Paste
Rate
Upgrade
Rotate
Effect
Edit
Slide
History
#pragma once #include "..\precompiled.h" #include
#include "NxExtended.h" using namespace std; using namespace stdext; namespace GameFactory{ #define toPVector3(vec3) {reinterpret_cast
(&(vec3))} #define fromPVector3(vector3) {reinterpret_cast
(&(vector3))} #define toPNxVec3(vec3) {reinterpret_cast
(&(vec3))} #define fromPNxVec3(nxvec3) {reinterpret_cast
(&(nxvec3))} struct less_str { bool operator()(String x, String y) const { //return (strcmp(x, y)>0); //differ return x.compare(y)>0;//differ } }; template
class MyIterator{ public: hash_map
::iterator iter; MyIterator(hash_map
::iterator iterator):iter(iterator){}; MyIterator(){hash_map
::iterator iterator;iter = hash_map
::iterator(iterator);}; void Next(){iter++;}; DataType* GetCurrent(){return (DataType*)iter->second;}; }; template
class MyHashTable{ private: hash_map
> mPool; public: DataType* Get(String key){ return (DataType*)(mPool.find(key)->second); }; void Put(const String& key, const DataType* value){ String localKey(key); //CLONE_STR(localKey,key); mPool.insert(pair
(localKey,(void*)value)); }; bool Exist(const String& key){return mPool.find(key)!=mPool.end();}; MyIterator
Begin(){ return MyIterator
(mPool.begin()); } bool IsEnd(MyIterator
iter){ return iter.iter==mPool.end(); } }; class MyListElement{ public: list
::iterator iter; }; //class MyList{//store in reversed order of pushing //private: // list
pool; //public: // inline void Put(MyListElement& value){ // pool.push_front(&value);//cannot use push_back because iter.end does not valid, see the line below // value.iter = pool.begin();//this iteration must be from the just added one // } // inline void Remove(MyListElement& value){//only remove, not delete the object // pool.erase(value.iter); // } // inline list
& GetPool(){return pool;} //}; template
//now support DataType! class MyList{//store in reversed order of pushing private: list
pool; public: inline void Put(DataType& value){ pool.push_front(&value);//cannot use push_back because iter.end does not valid, see the line below (static_cast
(&value))->iter = pool.begin();//this iteration must be from the just added one } inline void Remove(DataType& value){//only remove, not delete the object pool.erase((static_cast
(&value))->iter); } inline list
& GetPool(){return pool;} inline void Clear(){pool.clear();}; }; template
class MyListNonRemovable{ private: list
pool; public: inline void Put(DataType value){ pool.push_back(value);//to reserve the order of push and pop } inline list
& GetPool(){return pool;} inline void Clear(){ pool.clear(); } }; class Vec3: public Vector3{ public: //Real x,y,z; Vec3(){}; Vec3(Real x, Real y, Real z):Vector3(x,y,z){}; //OGRE specifics Vec3(const Vector3& s){ x=s.x;y=s.y;z=s.z; } //operator Vector3() const{ // return Vector3(x,y,z); //} //operator Vector3*(){ // return reinterpret_cast
(this); //} //PhysX specifics Vec3(const NxVec3& s){ x=s.x;y=s.y;z=s.z; } operator NxVec3() const{ return NxVec3(x,y,z); } operator NxVec3*(){ return reinterpret_cast
(this); } Vec3(const NxExtendedVec3& s){ x=s.x;y=s.y;z=s.z; } operator NxExtendedVec3() const{ return NxExtendedVec3(x,y,z); } }; class GFQuat: public Quaternion{ public: //Real x,y,z,w; GFQuat(){}; //OGRE specifics GFQuat(const Quaternion s){ x=s.x;y=s.y;z=s.z;w=s.w; } //operator Quaternion() const{ // return Quaternion(w,x,y,z); //} //PhysX specifics GFQuat(const NxQuat s){ x=s.x;y=s.y;z=s.z;w=s.w; } operator NxQuat() const{ return NxQuat(NxVec3(x,y,z),w); } }; }
DataTypes.h
Page URL
File URL
Prev
14/55
Next
Download
( 4 KB )
Note: The DriveHQ service banners will NOT be displayed if the file owner is a paid member.
Comments
Total ratings:
0
Average rating:
Not Rated
Would you like to comment?
Join DriveHQ
for a free account, or
Logon
if you are already a member.