Horde3D http://horde3d.org/forums/ |
|
Resource cloning http://horde3d.org/forums/viewtopic.php?f=3&t=432 |
Page 1 of 1 |
Author: | cantele [ 18.07.2008, 21:41 ] |
Post subject: | Resource cloning |
I was trying to clone a camera. Apparently it always returns 0. It's somewhat annoying to find this out *after* reading the documentation. I know there is a TODO in the code, maybe I should read all of those before trying anything new. IMO, it should throw an exception stating something sensible at the very least. |
Author: | swiftcoder [ 18.07.2008, 22:55 ] |
Post subject: | Re: Resource cloning |
cantele wrote: I was trying to clone a camera. Apparently it always returns 0. It's somewhat annoying to find this out *after* reading the documentation. I know there is a TODO in the code, maybe I should read all of those before trying anything new. You are welcome to implement this feature, and submit a patch - the engine is in beta, so patches are good, and one can't expect everything to work flawlessly from the get go.Quote: IMO, it should throw an exception stating something sensible at the very least. It returns a Null reference on failure, as is consistent with the rest of the API. An exception would not be good, because the public API is accessible from C, which does not support exceptions.
|
Author: | marciano [ 19.07.2008, 20:14 ] |
Post subject: | Re: Resource cloning |
cantele wrote: I was trying to clone a camera. Apparently it always returns 0. You probably mean the pipeline resource bound to your camera, right? Because a camera is no resource, so cloneResource won't work on it. But I think it is really a good idea to output a debug level warning for unsupported resource types in cloneResource. |
Page 1 of 1 | All times are UTC + 1 hour |
Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |