Hi,
After some frustration with my last problem (posting) I decided that I need a ResourceMgr. One problem that I am seeing is how to implement a "Handle" that uniquely identifies a resource (be it a texture or sound). One suggestion was using a "Hash value" however, creating a hash might take some CPU time (slow). Magic Number's might be the way to go, but I think I would be limiting myslef to a limited set of numbers. ("MAX_MAGIC = 32; MAIC_NUMBER = 1 << MAX_MAGIC;"), GID well...
What do you guys do to generate a HANDLE that is unigue? "Hashing a filename", "Magic Number", GUID. Anything else to concider using for a handle?
Sabrina
"Creative minds what to know".
After some frustration with my last problem (posting) I decided that I need a ResourceMgr. One problem that I am seeing is how to implement a "Handle" that uniquely identifies a resource (be it a texture or sound). One suggestion was using a "Hash value" however, creating a hash might take some CPU time (slow). Magic Number's might be the way to go, but I think I would be limiting myslef to a limited set of numbers. ("MAX_MAGIC = 32; MAIC_NUMBER = 1 << MAX_MAGIC;"), GID well...
What do you guys do to generate a HANDLE that is unigue? "Hashing a filename", "Magic Number", GUID. Anything else to concider using for a handle?
Sabrina
"Creative minds what to know".