taskGnash - The GNU Flash player - Tasks: task #6672, Provide chracter_def instances...

 
 
Show feedback again

You are not allowed to post comments on this tracker with your current authentification level.

task #6672: Provide chracter_def instances with "character_id" info

Submitted by:  Sandro Santilli <strk>
Submitted on:  Thu 22 Mar 2007 05:48:18 PM UTC  
 
Should Start On: Wed 21 Mar 2007 11:00:00 PM UTCShould be Finished on: Wed 21 Mar 2007 11:00:00 PM UTC
Category: NonePriority: 1 - Later
Status: NonePrivacy: Public
Percent Complete: 0%Assigned to: Bastiaan Jacques <bjacques>
Open/Closed: OpenEffort: 0.00

Fri 24 Aug 2007 10:48:26 AM UTC, comment #4:

OK, tested here. character id 0 is valid.

Zou Lunkai <zoulunkai>
Fri 24 Aug 2007 10:45:55 AM UTC, comment #3:

Just a note: if we really do NOT need the id stored in the character_def, we may just drop that member. This would reduce memory use.

On the other hand, if we find an use for it, then it's worth changing the CharacterDictionary to maintain a std::set instead of a std::map thus using the id stored in the character_def rather then duplicating it.

Sandro Santilli <strk>
Project Member
Fri 24 Aug 2007 08:19:41 AM UTC, comment #2:

If we want to use -1 then we'll need an int32 in order to support the max expressible number in an uint16. 16 more bits for a single flag... a boolean member would take less. So, worth verifying if character id 0 is valid, or numeric_limit<uint16>::max ?

Sandro Santilli <strk>
Project Member
Thu 23 Aug 2007 06:01:49 AM UTC, comment #1:

> What I would like to do is know from a character_def it's id.


exactly! This is what i'd expect.

> An id of -1 can be used for non-SWF-defined characters,
> altought I'd prefer 0 (but -1 is the current one...).


We just not sure whether 0 is a valid ID or not, the data type of ID in SWF is UINT16. -1 should be safe enough.

Zou Lunkai <zoulunkai>
Thu 22 Mar 2007 05:48:18 PM UTC, original submission:

Currently, character_def::m_id is a private member with NO setter or getter, always initialized to -1.
I might be missing something, but if I'm not I think we should
initialize that member with the value found in the SWF.
So far it wasn't useful, it seems, but at least for debugging
I'd have a use for it.

So, first verify, then implement if missing.
What I would like to do is know from a character_def
it's id. An id of -1 can be used for non-SWF-defined characters,
altought I'd prefer 0 (but -1 is the current one...).

Sandro Santilli <strk>
Project Member

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by zoulunkai (Posted a comment)
  • -unavailable- added by strk (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter 421 here (basic anti-spam test):

     

     

    No Changes Have Been Made to This Item
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup