Friday, October 29, 2010

"groupID" for graphics items and file formats

A new variable called groupID has been added to all the graphic item classes (i.e. NodeGraphicsItem, ConnectionGraphicsItem, and TextGraphicsItem).

The purpose of this new variable is to group graphics items together. Specifically, it is used to identify all the items that belong in the same scene. Since a single handle can contain multiple graphics items in different scenes, there was no other way to determine which item belongs in which scene. Further, ConnectionGraphicsReader was using position to identify nodes connected to a connection, which is faulty if two or more scenes have items of the same handle at the same position. The new variable is used by ConnectionGraphicsReader to identify the proper nodes. It is also used by ModuleTool to identify which items to load into a new scene.

By default, groupID is empty. This variable will not be made accessible through the C API since it is purely for graphics.

No comments: