Template:RCO TOC reference types: Difference between revisions

From PS3 Developer wiki
Jump to navigation Jump to search
mNo edit summary
No edit summary
 
(19 intermediate revisions by the same user not shown)
Line 1: Line 1:
{| class="wikitable" style="font-size:x-small;"
{| class="wikitable" style="font-size:small;"
|+RCO TOC reference types {{ed right|RCO TOC reference types}}
|+RCO TOC reference types {{ed right|RCO TOC reference types}}
! Reference_type !! Pointer type !! Method !! Loader !! Loads !! From !! Example (XML) !! Notes
! <abbr title="First byte = ref_type, second byte = ref_id, last 2 bytes = padding">reference_type</abbr> !! pointer !! Method !! Loader !! Loads !! From !! Example (XML) !! Notes
|-{{cellcolors|lightgrey}}
| 0xFFFF0000 || 0xFFFFFFFF || ''n/a'' || All || Nothing || None || class="nowrap | {{#tag:syntaxhighlight|<Entry reference="nothing"/>|lang=xml|inline=yes}} ||
|-
|-
| rowspan="2" | 0x04000000 || rowspan="2" | relative || rowspan="2" | '''event:''' || rowspan="2" | [[RCOXML Objects]]<br>[[RCOXML Animations]] || code function || associated [[Plugin Interfaces|.SPRX]] || ''event:native:/runFuctionX'' ||  
| rowspan="2" | 0x04000000 || rowspan="2" | <abbr title="relative to the start of the '''event_string_table'''">relative</abbr> || rowspan="2" | '''event:''' || rowspan="2" | [[RCOXML Objects]]<br>[[RCOXML Animations]] || Code function || Associated [[Plugin Interfaces|.SPRX]] || class="nowrap | {{#tag:syntaxhighlight|<Entry event="event:native:/runFuctionX"/>|lang=xml|inline=yes}} ||  
|-
|-
| '''VSMXFile'''/[[RCOXML Script]] function || [[VSMX]] inside [[Resource Container (RCO)|RCO]] || ''event:script:/main/runFuctionX'' ||  
| '''ScriptTree'''/[[RCOXML Script|Script]] || File inside [[Resource Container (RCO)|RCO]] || class="nowrap | {{#tag:syntaxhighlight|<Entry event="event:script:/main/runFuctionX"/>|lang=xml|inline=yes}} ||  
|-
|-
| 0x04010000 || # (0-based) || '''text:''' || [[RCOXML Objects]]<br>[[XMBML Coding|XMBML Code]] || '''TextTree'''/[[RCOXML Texts]] strings || [[Languages|<language>.xml]] inside [[Resource Container (RCO)|RCO]] || ''text:msg_mytext'' ||  
| 0x04010000 || <abbr title="The text entry #.  For example, 0 = the first text entry"># (0-based)</abbr> || '''text:''' || [[RCOXML Objects]]<br>[[XMBML Coding|XMBML Code]] || '''TextTree'''/[[RCOXML Texts|Text]] || Strings inside [[Resource Container (RCO)|RCO]] || class="nowrap | {{#tag:syntaxhighlight|<Entry text="text:msg_mytext"/>|lang=xml|inline=yes}} ||  
|-
|-
| 0x04020000 || absolute || '''image:''' || [[RCOXML Objects]]<br>[[XMBML Coding|XMBML Code]] || '''ImageTree'''/[[RCOXML Images]] textures || .GIM .PNG .JPG inside [[Resource Container (RCO)|RCO]] || ''image:tex_mytexture'' ||  
| 0x04020000 || absolute || '''image:''' || [[RCOXML Objects]]<br>[[XMBML Coding|XMBML Code]] || '''ImageTree'''/[[RCOXML Images|Image]] || File inside [[Resource Container (RCO)|RCO]] || class="nowrap | {{#tag:syntaxhighlight|<Entry image="image:tex_mytexture"/>|lang=xml|inline=yes}} ||  
|-
|-
| 0x04030000 || absolute || '''model:''' || [[RCOXML Objects]] || '''ModelTree'''/[[RCOXML Models]] || .GMO inside [[Resource Container (RCO)|RCO]] || ''model:mymodel'' ||  
| 0x04030000 || absolute || '''model:''' || [[RCOXML Objects]] || '''ModelTree'''/[[RCOXML Models|Model]] || File inside [[Resource Container (RCO)|RCO]] || class="nowrap | {{#tag:syntaxhighlight|<Entry model="model:mymodel"/>|lang=xml|inline=yes}} ||  
|-{{cellcolors|#ff7777}}
|-{{cellcolors|#ff7777}}
| 0x04040000 || absolute ? || '''sound:''' ? || associated .SPRX || '''SoundTree'''/[[RCOXML Sounds]] || .VAG inside [[Resource Container (RCO)|RCO]] || sound:mysound ? || <abbr title="never found used in RCOXML code... but the reference_types for text, images, model, sound, font... follows the same order than the entry_types for TestTree, ImageTree, ModelTree, SoundTree, FontTree... so is highly probable ths is a reference to a sound file">speculation</abbr>
| 0x04040000 || absolute ? || '''sound:''' ? || associated .SPRX || '''SoundTree'''/[[RCOXML Sounds|Sound]] || File inside [[Resource Container (RCO)|RCO]] || class="nowrap | {{#tag:syntaxhighlight|<Entry sound="sound:mysound"/>|lang=xml|inline=yes}} ? || <abbr title=" the reference_types follows the same order than the entry_types for TextTree, ImageTree, ModelTree, SoundTree, FontTree... so is highly probable this is a reference to a sound file from SoundTree">speculation</abbr>
|-
|-
| 0x04050000 || absolute || '''font:''' || [[RCOXML Objects]] || '''FontTree'''/[[RCOXML Fonts]] styles || ? || ''font:fontstyle_sanserif'' || <abbr title="font management is not fully implemented in rcomage, the pointer could be aiming to one of the '''unknown data tables''' in the RCO header that should be renamed to '''font table'''... so this could be a reference to a font file">speculation</abbr>
| 0x04050000 || absolute || '''font:''' || [[RCOXML Objects]] || '''FontTree'''/[[RCOXML Fonts|Font]] || File inside [[Resource Container (RCO)|RCO]] ? || class="nowrap | {{#tag:syntaxhighlight|<Entry font="font:fontstyle_sanserif"/>|lang=xml|inline=yes}} ||
|-{{cellcolors|#ff7777}}
|-{{cellcolors|#ff7777}}
| 0x04060000 || absolute ? || ''unknown'' || || || || || <abbr title="the position matches with the '''unknownTree''' in the RCO header that seems to point to one of the '''unknown data tables''' in the RCO header... so this could be a reference to a file">speculation</abbr>
| 0x04060000 || absolute ? || '''anim2:''' ? || [[RCOXML Objects]] ? || '''AnimTree'''/[[RCOXML Animations|Animation]] ? || [[RCOXML Coding|RCOXML code]] ? || class="nowrap | {{#tag:syntaxhighlight|<Entry anim2="anim2:myanimation"/>|lang=xml|inline=yes}} ? || <abbr title="last 4 reference types could be crosslinks in between objecttree and animtree">speculation</abbr>
|-
|-
| 0x04070000 || absolute || '''object2:''' || [[RCOXML Objects]] || '''ObjectTree'''/[[RCOXML Objects]] || [[RCOXML Coding|RCOXML code]] || ''object2:plane_myplane'' || <abbr title="maybe the object2 found is just a variant of object where is specifyed with a sufix the xml hierarchy depth, so to go down in the xml hierarchy maybe is posible to use object3, object4 and so on">speculation</abbr>
| 0x04070000 || absolute || '''object2:''' || [[RCOXML Objects]] || '''ObjectTree'''/[[RCOXML Objects|Object]] || [[RCOXML Coding|RCOXML code]] || class="nowrap | {{#tag:syntaxhighlight|<Entry object2="object2:plane_myplane"/>|lang=xml|inline=yes}} ||
|-
|-
| 0x04080000 || absolute || '''anim:''' || [[RCOXML Animations]] || '''AnimTree'''/[[RCOXML Animations]] || [[RCOXML Coding|RCOXML code]] || ''anim:myanimation'' ||  
| 0x04080000 || absolute || '''anim:''' || [[RCOXML Animations]] || '''AnimTree'''/[[RCOXML Animations|Animation]] || [[RCOXML Coding|RCOXML code]] || class="nowrap | {{#tag:syntaxhighlight|<Entry anim="anim:myanimation"/>|lang=xml|inline=yes}} ||  
|-
|-
| 0x04090000 || absolute || '''object:''' || [[RCOXML Animations]] || '''ObjectTree'''/[[RCOXML Objects]] || [[RCOXML Coding|RCOXML code]] || ''object:plane_myplane'' ||  
| 0x04090000 || absolute || '''object:''' || [[RCOXML Animations]] || '''ObjectTree'''/[[RCOXML Objects|Object]] || [[RCOXML Coding|RCOXML code]] || class="nowrap | {{#tag:syntaxhighlight|<Entry object="object:plane_myplane"/>|lang=xml|inline=yes}} ||  
|-{{cellcolors|lightgrey}}
|}
| 0xFFFF0000 || 0xFFFFFFFF || '''nothing''' ||  ||  ||  ||  ||
*A reference attribute is composed by two values, the first is the '''reference_type''' that indicates the "tree" of the entry that is going to be loaded, and the second is a '''pointer''' to a text string with the '''label''' of the entry that is going to be loaded
|}<noinclude>[[Category:Templates]]</noinclude>
*The reference_type '''event''' doesnt loads an entry from a "tree" though, it runs a code function from either a .sprx (by storing the text '''native:/''' as part of the text string inside the RCO) or from a [[VSMX]] script (by storing the text '''script:/''' as part of the text string inside the RCO)
*First two bytes are swapped based on architecture (PSP in little endian, PS3 in big endian). The table shows the values in big endian
<noinclude>[[Category:Templates]]</noinclude>

Latest revision as of 16:46, 23 April 2023

RCO TOC reference types
reference_type pointer Method Loader Loads From Example (XML) Notes
0xFFFF0000 0xFFFFFFFF n/a All Nothing None <Entry reference="nothing"/>
0x04000000 relative event: RCOXML Objects
RCOXML Animations
Code function Associated .SPRX <Entry event="event:native:/runFuctionX"/>
ScriptTree/Script File inside RCO <Entry event="event:script:/main/runFuctionX"/>
0x04010000 # (0-based) text: RCOXML Objects
XMBML Code
TextTree/Text Strings inside RCO <Entry text="text:msg_mytext"/>
0x04020000 absolute image: RCOXML Objects
XMBML Code
ImageTree/Image File inside RCO <Entry image="image:tex_mytexture"/>
0x04030000 absolute model: RCOXML Objects ModelTree/Model File inside RCO <Entry model="model:mymodel"/>
0x04040000 absolute ? sound: ? associated .SPRX SoundTree/Sound File inside RCO <Entry sound="sound:mysound"/> ? speculation
0x04050000 absolute font: RCOXML Objects FontTree/Font File inside RCO ? <Entry font="font:fontstyle_sanserif"/>
0x04060000 absolute ? anim2: ? RCOXML Objects ? AnimTree/Animation ? RCOXML code ? <Entry anim2="anim2:myanimation"/> ? speculation
0x04070000 absolute object2: RCOXML Objects ObjectTree/Object RCOXML code <Entry object2="object2:plane_myplane"/>
0x04080000 absolute anim: RCOXML Animations AnimTree/Animation RCOXML code <Entry anim="anim:myanimation"/>
0x04090000 absolute object: RCOXML Animations ObjectTree/Object RCOXML code <Entry object="object:plane_myplane"/>
  • A reference attribute is composed by two values, the first is the reference_type that indicates the "tree" of the entry that is going to be loaded, and the second is a pointer to a text string with the label of the entry that is going to be loaded
  • The reference_type event doesnt loads an entry from a "tree" though, it runs a code function from either a .sprx (by storing the text native:/ as part of the text string inside the RCO) or from a VSMX script (by storing the text script:/ as part of the text string inside the RCO)
  • First two bytes are swapped based on architecture (PSP in little endian, PS3 in big endian). The table shows the values in big endian