Editing RCOXML Coding

Jump to navigation Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
=Description=
=Description=
An RCOXML file is a XML file that represents the contents of a RCO file. This RCOXML files doesnt exists inside the RCO file (are just a representation of it). In the compilation enviroment used officially by sony this RCOXML files "should" work as a "pre-build" layout, contains all the info and settings needed to build an RCO file
RCOXML files are the XML descriptor files implicit inside [[Resource Container (RCO)]] files (.rco)


Tools like [[Rcomage]] generates this RCOXML files that can be used to rebuild the RCO, or to build a custom RCO from scratch, this RCOXML files generated by rcomage "should" be pretty similar to the officials because all the info is based in the TOC area of the RCO that is structured as an XML so the conversion from TOC to XML format is direct (also, rcomage adds some info for rebuilding purposes that is not part of the TOC), see [[Resource Container (RCO)]]
This RCOXML files doesnt exists inside the .rco container, tools like [[Rcomage]] extracts the info as XML as a representation of the data inside the .rco container
{{RCOXML contents PS3}}
 
Are composed by tables, some of this tables works simply as an index of the contents inside the container (texts, sounds, languages), and others tables contains "pages" that builds the XMB items, animations, effects, dialog menues, selection windows, widgets, etc...
 
Note the name "page" here in wiki is used as a generic name for all types of pages, rcomage uses specific names for some types of pages wich purpose was identifyed, this names can vary between different versions of rcomage tool
 
For specific examples of the contents of this rcoxml files see the [[Plugin Interfaces]] page, most resource containers (.rco) uses the same name than his associated plugin (.sprx), but there are a few that doesnt follows this rule so is a bit harder to know from how many plugins .sprx can be called (and this is a problem for wiki by now because the way pages are ordered and named)
 
audioplayer_plugin_util.rco
avc_game_plugin.rco
checker_plugin.rco
explore_plugin_full.rco
friendim_plugin_game.rco
friendml_plugin_game.rco
friendtrophy_plugin_game.rco
game_plugin.rco
impose_plugin.rco
msgdialog_plugin.rco
profile_plugin_mini.rco
search_service.rco
subdisplay_plugin.rco
sv_pseudoaudioplayer_plugin.rco
system_plugin.rco
xmb_plugin_normal.rco
 
= RCOXML Contents (PS3) =


= RCOXML Structure =
= RCOXML Structure =
This is a '''not-working''' example intended to place all together as an overview. Not all nodes below are required, and various object/anim entries are omitted.
Not all nodes below are required, and various object/anim entries are omitted.
 
{{Boxcode|code=<syntaxhighlight lang="xml">
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- This XML representation of an RCO structure was generated by Rcomage v1.1.2 -->
<RcoFile UMDFlag="0" rcomageXmlVer="1.1" type="psp" minFirmwareVer="1.5"> <!-- XML root element, generally does not need to be modified -->
<MainTree name="sample"> <!-- root RCO node from which everything must descend from -->
<VSMXFile name="main" src="main.vsmx"></VSMXFile> <!-- attached virtual machine instruction code, only one may exist in an RCO file -->
<ImageTree> <!-- parent node from which all image resources descend from -->
<Image name="texture" src="texture.gim" format="gim" compression="zlib" unknownByte="0" />
</ImageTree>
<FontTree> <!-- parent node from which all fonts descend from -->
<FontStyle name="fontstyle_default" unknownShort1="0x0" unknownShort2="0x0" unknownInt3="0x0" unknownInt4="0x41600000" />
</FontTree>
<TextTree> <!-- parent node from which all text language resources descend from -->
<TextLang src="00_Japanese.xml" language="00_Japanese" format="utf16" />
</TextTree>
<ModelTree> <!-- parent node from which all model resources descend from -->
<Model name="page_model" src="page_model.gmo" format="gmo" compression="zlib" unknownByte="0" />
</ModelTree>
<SoundTree> <!-- parent node from which all sound resources descend from -->
<Sound name="sound" src="sound.ch*.vag" format="vag" channels="2" />
</SoundTree>
<ObjectTree> <!-- parent node from which all object pages descend from -->
<Page name="main_page" pageMode="0x111" pageOnInit="event:script:/main/onInitMainPage" pageOnCancel="nothing" pageOnContext="nothing" pageOnActivate="nothing">
<Plane name="main_page_plane" ...standard object attributes here... planeImage="image:texture" planeResizeMode="0x0">
<ModelObject name="main_page_model"  ...standard object attributes here...  modelobjectModel="model:page_model"></ModelObject>
<Action name="go" actionText="text:msg_go"></Action>
</Plane>
</Page>
</ObjectTree>
<AnimTree> <!-- parent node from which all animation sequences descend from -->
<Animation name="main_page_fade">
<Fade object="object:main_page_plane" duration="100" accelMode="0x0" transparency="1" />
<FireEvent event="anim:main_page_fade" />
</Animation>
</AnimTree>
</MainTree>
</RcoFile>
</syntaxhighlight>}}


==MainTree==
RcoFile - XML root element; generally does not need to be modified
All RCOXML files starts with the tag:
MainTree - root RCO node from which everything must descend from
<MainTree name="label">
VSMXFile - attached UMD virtual machine instruction code, for UMD and some LFTV RCOs.  Only one may exist in an RCO file
MainTree represents the root of the container, so it seems the label is the name of the .rco container and is working as an identifyer of it
ImageTree - parent node from which all image resources descend from
Image
Image
...
TextTree - parent node from which all text language resources descend from
TextLang
TextLang
...
ModelTree - parent node from which all model resources descend from
Model
Model
...
SoundTree - parent node from which all sound resources descend from
Sound
Sound
...
ObjectTree - parent node from which all object pages descend from
<Page>
page objects go here
<Page>
page objects go here
...
AnimTree - parent node from which all animation sequences descend from
<Animation>
animation entries go here
<Animation>
animation entries go here
...
==VSMXFile==
None of the PS3 rco's uses a VSMXFile
==ImageTree==
*All PS3 rco's uses a ImageTree except:
**[[ap_plugin]].rco
**[[audioplayer_plugin_dummy]].rco
**[[audioplayer_plugin_mini]].rco
**[[audioplayer_plugin_util]].rco
**[[avc2_game_plugin]].rco
**[[bdp_disccheck_plugin]].rco
**[[bdp_storage_plugin]].rco
**[[checker_plugin]].rco
**[[data_copy_plugin]].rco
**[[dtcpip_util]].rco
**[[game_plugin]].rco
**[[gamedata_plugin]].rco
**[[gameupdate_plugin]].rco
**[[idle_plugin]].rco
**[[ingame_manual_plugin]].rco
**[[msgdialog_plugin]].rco
**[[musicbrowser_plugin]].rco
**[[newstore_effect]].rco
**[[pesm_plugin]].rco
**[[photolist_plugin]].rco
**[[podl_plugin]].rco
**[[poweroff_plugin]].rco
**[[ps3_savedata_plugin_game_mini]].rco
**[[rec_plugin]].rco
**[[remotedownload_plugin]].rco
**[[scenefolder_plugin]].rco
**[[screenshot_plugin]].rco
**[[search_service]].rco
**[[strviewer_plugin]].rco
**[[subdisplay_plugin]].rco
**[[thumthum_plugin]].rco
**[[user_info_plugin]].rco
**[[videoplayer_util]].rco


*Is unknown how this labels works and his purpose, but follows a few rules:
==TextTree==
**The same label can be used by several .rco's that shares functions
*All PS3 rco's uses a TextTree except:
**This label names doesnt appears in the associated .sprx
**[[ap_plugin]].rco
**[[avc2_game_video_plugin]].rco
**[[checker_plugin]].rco
**[[custom_render_plugin]].rco
**[[game_indicator_plugin]].rco
**[[gamelib_plugin]].rco
**[[idle_plugin]].rco
**[[musicbrowser_plugin]].rco
**[[newstore_effect]].rco
**[[osk_plugin]].rco
**[[pesm_plugin]].rco
**[[photolist_plugin]].rco
**[[podl_plugin]].rco
**[[rec_plugin]].rco
**[[scenefolder_plugin]].rco
**[[subdisplay_plugin]].rco


*Other .rco files from previous firmwares (not present in latest firmwares) using the MainTree name '''sample'''
==ModelTree==
**xai_plugin.rco
None of the PS3 rco's uses a ModelTree
**In PSP firmware there are also some .rco files using the MainTree name '''sample'''
==SoundTree==
*Rco files in PS3 firmware 4.76 using a SoundTree:
**[[edy_plugin]].rco
**[[eula_net_plugin]].rco
**[[osk_plugin]].rco
**[[regcam_plugin]].rco
**[[system_plugin]].rco
**[[videoeditor_plugin]].rco
==ObjectTree==
*All PS3 rco's uses a ObjectTree except:
**[[audioplayer_plugin_dummy]].rco
**[[avc2_game_plugin]].rco
**[[category_setting_plugin]].rco
**[[newstore_effect]].rco <------- this file is a wtf, it seems to be empty
**[[search_service]].rco


===VSMXFile===
==AnimTree==
None of the PS3 rco's uses a VSMXFile. But some PSP .rco's uses it
*Rco files in PS3 firmware 4.76 using a AnimTree:
**[[bdp_plugin]].rco
**[[custom_render_plugin]].rco
**[[friendim_plugin]].rco
**[[friendim_plugin_game]].rco
**[[gamelib_plugin]].rco
**[[impose_plugin]].rco
**[[npsignin_plugin]].rco
**[[premo_plugin]].rco
**[[sacd_plugin]].rco
**[[system_plugin]].rco


*rough explain of how it works
=RCOXML Modifications=
**The purpose of this script is to communicate with the associated module/sprx, the code inside the script is [[PlayStation JavaScript]] based (see also [[VSMX]] format) and it can call functions with parameters from the module/sprx. It works as a simple way to store predefined actions for the .sprx inside the .rco with a bit of code control involved. The [[RCOXML Objects]] captures the button presses from the controller and based on them loads the script using the buttons as parameters, then the code inside the script is processed and triggers the .sprx
All modifications made in the main XML file that represents the structure of the RCO extracted by [[rcomage]] belongs to this category
**An script can contain several different actions (are actually .js code functions) and his names are the same than the action names used in [[RCOXML Objects]], as example: '''OnFocusRight''' (action triggered when moving right in the controller)


===ImageTree===
==Changing color, size & shadow of TEXTS== <!-- iirc there is a setting for the font type too -->


===FontTree===
Tutorial link: [http://www.tortuga-cove.com/forums/viewtopic.php?f=128&t=5361&p=28094#p28094 Changing the XMB Colour]
Only used in PS3, only used in sysconf_plugin.rco and hknw_plugin.rco


===TextTree===
Located into .xml files of .rco files, scale <span style="color:#ff0000"> R </span><span style="color:#008000"> G </span><span style="color:#0000ff"> B </span>α colors go between 0 to 1.


===ModelTree===
e.g.: Decimal value divided by 255 to get into this scale.
None of the PS3 rco's uses a ModelTree


===SoundTree===
==Gameboot Animation==
In [[gamelib_plugin]].rco
{{Boxcode|content=<syntaxhighlight lang="xml">
<Animation name="anim_gameboot">
<Lock unknownInt0="0xffffffff" />
<Fade object="object:ps3logo" duration="0" accelMode="0x0" transparency="0" />
<Resize object="object:ps3logo" duration="0" accelMode="0x0" width="0.938" height="0.938" depth="1" />
<Delay time="500" />
<Fade object="object:ps3logo" duration="863" accelMode="0x3" transparency="1" />
<Resize object="object:ps3logo" duration="863" accelMode="0x4" width="1" height="1" depth="1" />
<Delay time="1100" />
<Fade object="object:ps3logo" duration="174" accelMode="0x1" transparency="0" />
<Resize object="object:ps3logo" duration="174" accelMode="0x1" width="1.284" height="1.284" depth="1" />
<Delay time="1000" />
<Delay time="200" />
<FireEvent event="event:native:/GameLibApp_OnBootAnimationFinished" />
</Animation>
</syntaxhighlight>}}


===ObjectTree===
In [[custom_render_plugin]].rco
*in [http://ctfs.wiki.fc2.com/wiki/RCOmageXML this page] under the section "ObjectTree" are explained what seems to be a few golden rules related to:
{{Boxcode|content=<syntaxhighlight lang="xml">
**object display priority
<Animation name="anim_gameboot">
**children objects inherited attributes from parent object
<Lock unknownInt0="0xffffffff" />
<Fade object="object:ps3logo" duration="0" accelMode="0x0" transparency="0" />
<Resize object="object:ps3logo" duration="0" accelMode="0x0" width="0.938" height="0.938" depth="1" />
<FireEvent event="event:native:/anim_gameboot_BG2" />
<Delay time="500" />
<Fade object="object:ps3logo" duration="863" accelMode="0x3" transparency="1" />
<Resize object="object:ps3logo" duration="863" accelMode="0x4" width="1" height="1" depth="1" />
<FireEvent event="event:native:/anim_gameboot_BG3" />
<Delay time="1100" />
<Fade object="object:ps3logo" duration="174" accelMode="0x1" transparency="0" />
<Resize object="object:ps3logo" duration="174" accelMode="0x1" width="1.284" height="1.284" depth="1" />
<Delay time="1000" />
<Delay time="200" />
<FireEvent event="event:native:/anim_gameboot_Finished" />
</Animation>
</syntaxhighlight>}}


===AnimTree===


{{File Formats}}
{{System Firmware}}<noinclude>[[Category:Main]]</noinclude>
<noinclude>[[Category:Main]]</noinclude>
Please note that all contributions to PS3 Developer wiki are considered to be released under the GNU Free Documentation License 1.2 (see PS3 Developer wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following hCaptcha:

Cancel Editing help (opens in new window)