kottore / away3d

Automatically exported from code.google.com/p/away3d
0 stars 0 forks source link

[Lite] Sprite3D add and remove fails #116

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Patch the Away3DLite ExSprite3D.as example in the trunk with the attached 
testSprite patch
2. Build and run the patched ExSprite3D example
3. Witness errors as addSprite or removeSprite in ObjectContainer3D attempts to 
alter the 
lengths of fixed Vectors

What is the expected output? What do you see instead?
When working correctly, the patched example should continuously add and remove 
sprites.

What version of the product are you using? On what operating system?
URL: svn+ssh://svn/repos/soft/webflock_flash/branches/3.0_core
Repository Root: svn+ssh://svn/repos/soft/webflock_flash
Repository UUID: 2f0d9c9a-db4e-0410-9f96-9543c6fb484e
Revision: 1208

Please provide any additional information below.

1) I altered the addSprite/removeSprite methods to unlock the altered vectors.
2) At this point new errors pop up, since the sprite objects are removed from 
the _sprites Vector 
via splice, so the Sprite3D objects following the splice all have an off-by-one 
error in their 
"index" property.
3) After tracking down/sorting out the bad index assignments, the clipping step 
begins to fail 
because the _screenVertices and _faces Vectors still have data for the missing 
Sprite.
4) Once this is remedied, adding/removing sprites seems to work fine.  

The attached patch contains the steps listed above.

Thanks!

Original issue reported on code.google.com by ken.rai...@gmail.com on 24 May 2010 at 10:24

Attachments:

GoogleCodeExporter commented 8 years ago
Oops, I pasted the version info from the wrong terminal :(
Here is the actual version info:

Macintosh:src grazer$ svn info
Path: .
URL: http://away3d.googlecode.com/svn/trunk/fp10/Examples/Away3DLite/as/src
Repository Root: http://away3d.googlecode.com/svn
Repository UUID: 6da1ee2c-932f-0410-8bb4-73b2b089c45a
Revision: 2521
Node Kind: directory
Schedule: normal
Last Changed Author: katopz
Last Changed Rev: 2269
Last Changed Date: 2010-02-26 06:51:24 -0600 (Fri, 26 Feb 2010)

Original comment by ken.rai...@gmail.com on 24 May 2010 at 10:27

GoogleCodeExporter commented 8 years ago

Original comment by katopz on 26 May 2010 at 3:03