FURWARE text/Developers

From Second Life Wiki
< FURWARE text
Revision as of 12:45, 8 July 2013 by Ochi Wolfe (talk | contribs) (Added some initial content)
Jump to navigation Jump to search


This page contains technical information about FURWARE text and is intended for developers and interested users.


Terminology and hierarchy of entities

A "set" is a part of a text display consisting of display prims arranged in rows and columns. Each set has a name, usually assigned using the display creator tool. A linkset may contain multiple sets.

A "box" is a virtual text box within a set. Each set always has a (root) box of the size of the set. Each box has a name which is assigned via a parameter to the fw_addbox command. Additional boxes may be added to a set which are then stacked in layers, depending on the order in which the boxes were added.


This yields the following relations:

  • A box is always part of (and fully contained within) a set.
  • A set consists of one or more prims.
  • A prim may have multiple faces.
  • Each face shows one character of text.


The textual content of a box is often referred to as the box's "data" (note that "data" is sometimes also used with a more general meaning).

The text style configuration of a box (or parts of text) is often referred to as (the box's) "conf".


The main data structure for box, set and prim data

Most of the information about the geometry and contents of the displays is stored in a few lists. Some lists contain indices ("pointers") to data in other lists.

Box data

  • "boxNameList" is a list containing the names of the boxes one after another. The reason for having the box names in a separate list (i.e. not part of "boxDataList", see below) is that the names shall be quickly searchable. For instance, when new text is received, the index of a box given its name must be retrieved.
  • "boxDataList" is a strided list containing more information about each box. One stride contains:
    • The box's text content (string).
    • The box's style configuration (string).
    • A pointer to the start of the set in "setDataList" of the set this box belongs to (integer).
    • The status of the box (e.g. if it's dirty and needs to be refreshed) (bit-packed integer).
    • The box's geometry (column offset, row offset, width, height) (rotation).

Set data

  • "setDataList" is a strided list containing information about each set. One stride contains:
    • The set's geometry (number of prim columns and rows, face count) (vector).
    • A pointer to the start of the prim data stored in the "prim*List"-lists (integer).

Prim data

  • "primLinkList" contains the link numbers of the prims, ordered by sets, rows and columns. The link numbers are not bit-packed because they shall be quickly searchable, e.g. when performing touch queries.
  • "primFillList" contains bit-packed integers storing the state of each face on the respective prim. "The state" of a face means whether it is currently known to be showing whitespace or non-whitespace. This information is used as a cache to avoid SetPrimitiveParams-calls when not necessary.
  • "primLayerList" contains bit-packed integers that store the assignment of faces to layers. The 32 bits of the integer are split into 4 bits for each face and thus each face may be assigned one of 16 different layer IDs. This information is used during rendering to quickly determine which layer a given face of a given prim belongs to.

Basic flow of events

This images is an attempt to visualize the basic flow of events and functions inside FURWARE text when a command that modifies the layout or contents of the display is received.


FURWARE text basic event flow.png


The initialization routine

To do


The rendering routine

To do


Caching strategies

To do


Delayed rendering

To do


KBtip2.png Tip: If you would like to get more info on specific topics, please leave a note on the discussion page. :)