PS3 Coldboot MP3 hack (experimental)

Discussion in 'XMB Modifications' started by DeViL303, Feb 11, 2020.

  1. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    Experimental Coldboot MP3 hack:

    I posted about this already, but think its worth a thread. This could be used to save space on flash in CFW.

    With just a few simple 2 byte patches and one file swapped we can have the PS3 play MP3s instead of AC3s for coldboots (and probably gameboots - untested)

    Step 1: you replace the libac3dec.sprx with a copy of libmp3dec.sprx in dev_blind\sys\external\


    Step 2: Patch custom_render_plugin.sprx lke this:

    upload_2020-2-11_18-30-50.png

    upload_2020-2-11_18-31-11.png

    Then put your mp3s on flash in dev_blind\vsh\resource. You can delete the ac3s.
    upload_2020-2-11_18-31-30.png


    This needs to be explored more to see what unwanted side effects there are from swapping this file, There will most likely be issues with movies with ac3 audio.
     
    Last edited: Feb 12, 2020
    jeka26, DADi590, hekel and 7 others like this.
  2. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    This is another custom_render_plugin patch that could be used to save space on CFW. Get rid of the "_multi.ac3" files and have both read from the "_stereo.ac3" file. This works with mp3s too.

    upload_2020-2-11_18-38-44.png

    upload_2020-2-11_18-41-12.png
     
    jeka26, Louis Garry and Algol like this.
  3. 3,288
    5,405
    522
    aldostools

    aldostools Developer Developer

    Joined:
    Oct 30, 2014
    Messages:
    3,288
    Likes Received:
    5,405
    Trophy Points:
    522
    Any chance to make it read the mp3 from dev_hdd0 or usb (fat32)?
     
    DeViL303 likes this.
  4. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    HDD is no problem, I have loaded large 30 minute ac3s from hdd before. Not sure about usb. I can test in a while and report back.
     
  5. 350
    108
    97
    ayassinsayed

    ayassinsayed Member

    Joined:
    Mar 16, 2018
    Messages:
    350
    Likes Received:
    108
    Trophy Points:
    97
    Gender:
    Male
    any chance to make it for HEN users?


    Sent from my iPhone using Tapatalk
     
  6. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    No, not really.
     
  7. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    Looks like I mixed up some files, I had my libac3dec.sprx swapped for libmp3dec.sprx. Need to do some more testing.

    I've edited the first post to remove the bit about vsh.self.
     
    Last edited: Feb 12, 2020
  8. 3,288
    5,405
    522
    aldostools

    aldostools Developer Developer

    Joined:
    Oct 30, 2014
    Messages:
    3,288
    Likes Received:
    5,405
    Trophy Points:
    522
    When you have finished your tests it would be nice if you could upload the binaries already patched.

    I would love to test the MP3 feature on my Rebug 4.84.2

    I suppose that it isn't a problem if the MP3/ACC file is missing... IIRC it was possible to remove/rename the coldboot files in dev_flash to boot in mute mode, although I normally use the command mute coldboot in boot_init.txt script of webMAN MOD.
     
    DeViL303 likes this.
  9. 1,381
    1,296
    297
    LuanTeles

    LuanTeles Senior Member

    Joined:
    May 15, 2017
    Messages:
    1,381
    Likes Received:
    1,296
    Trophy Points:
    297
    Gender:
    Male
    Occupation:
    Civil Engineer
    Location:
    São Paulo - Brazil
    Home Page:
    Isn't a way to nuke the

    <FireEvent object="event:native:/anim_coldboot_Finished" />

    that stops the boot sound in the sprx?
     
  10. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    @aldostools So yeah I messed up, the first vsh.self patch is not required, what actually is making mp3 work is that I replaced the libac3dec.sprx with a copy of libmp3dec.sprx and edited the extension in custom render plugin to "mp3".

    I guess if this sprx was swapped on flash, but then webman remapped it back to its original after booting then it would work ok. Otherwise there will probably be side effects when you try play a movie with ac3 sound.

    There is probably somewhere else that is deciding which sprx gets used at boot, if we could change that then there would be no side effects, that is what I was trying to do in vsh.self, but I must have the wrong place/file.

    Anyway here is what I know so far. If you put this attached libac3dec.sprx on flash in dev_flash\sys\external\ , and also put the attached custom_render_plugin.sprx into dev_flash\vsh\module\ then the ps3 will try to play dev_hdd0\tmp\coldboot.mp3 at boot. I have also edited the path for the gameboot to dev_hdd0\tmp\gameboot.mp3

    Note: the attached libac3dec.sprx is just the libmp3dec renamed, so that much of the patch would work on HEN/OFW. The custom_render_plugin.sprx will not work on OFW.

    upload_2020-2-12_14-4-14.png


    That separate "Background audio on XMB patch" does still work with mp3 in the same way...but it still has the issue with the mouse pointer and xmb clicks not playing so its not perfect.
     

    Attached Files:

    Last edited: Feb 12, 2020
  11. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    Stuff that is still to be tested:
    • will movies with ac3 sound play properly if the files are swapped
    • Do people with 5.1 sound setups need to also replace/remap the libac3dec2.sprx
    • can we remap the file back to a copy of the original using webman, or is this file only loaded once at boot
    • Try to find where the call is made to the ac3 plugin, and edit it there instead for a better patch.

    HDD paths and USB paths do work, usb did not work for me sometimes, I think this might be due to the speed of the stick and how fast it initializes.
     
  12. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    @aldostools now that we know the system can play mp3 at boot instead, I wonder can we force the system to keep the libac3dec.sprx loaded somehow after the xmb has loaded? ,so the audio stays playing. I can make it stay playing by removing the "coldboot finished" line from the animation script in the rco, but that has other unwanted effects.

    We almost have background music on xmb working, just a couple of webman mod remaps could do it with no system patches. That's If webman is loaded early enough in the boot process?
     
    Last edited: Feb 12, 2020
    jeka26 likes this.
  13. 3,288
    5,405
    522
    aldostools

    aldostools Developer Developer

    Joined:
    Oct 30, 2014
    Messages:
    3,288
    Likes Received:
    5,405
    Trophy Points:
    522
    Could you try remapping libac3dec.sprx to libmp3dec.sprx, wait 10 seconds, then remove the mapping?

    It can be done using the script commands in boot_init.txt

    My hypothesis is that once the mp3 is loaded and start playing, the mapping could be removed. So the movies are not affected.

    Another option is remap libac3dec.sprx to libmp3dec.sprx using boot_init.txt, then use a custom combo to remove the mapping.

    ATM I cannot use the console to test myself.
     
    DeViL303 likes this.
  14. 1,381
    1,296
    297
    LuanTeles

    LuanTeles Senior Member

    Joined:
    May 15, 2017
    Messages:
    1,381
    Likes Received:
    1,296
    Trophy Points:
    297
    Gender:
    Male
    Occupation:
    Civil Engineer
    Location:
    São Paulo - Brazil
    Home Page:
    Aldo can we set a script to load music in background?
     
  15. 3,288
    5,405
    522
    aldostools

    aldostools Developer Developer

    Joined:
    Oct 30, 2014
    Messages:
    3,288
    Likes Received:
    5,405
    Trophy Points:
    522
    There isn't any command to play music in wMM. However, with DeViL303's mod it is possible to remap any MP3 to the coldboot.mp3 (or .ac3) when the system starts using the script boot_init.txt.

    What I mean in my post above is that once the music starts, I think it is possible to remove the mappings (10 seconds later) and the music should continue playing.
     
  16. 8,072
    9,298
    797
    DeViL303

    DeViL303 Developer PSX-Place Supporter

    Joined:
    Jan 23, 2016
    Messages:
    8,072
    Likes Received:
    9,298
    Trophy Points:
    797
    @aldostools I didn't have much time to test this, but does not seem to work. Maybe I am doing something wrong or maybe webman mod is not loaded early enough... not sure.

    Code:
    map /dev_flash/sys/external/libac3dec.sprx=/dev_flash/sys/external/libmp3dec.sprx
    map /dev_flash/vsh/resource/coldboot_stereo.ac3=/dev_flash/vsh/resource/coldboot_stereo.mp3
    map /dev_flash/vsh/resource/coldboot_multi.ac3=/dev_flash/vsh/resource/coldboot_stereo.mp3
    I had not bothered with the delay and unmap yet to keep it simple.
     
  17. 3,288
    5,405
    522
    aldostools

    aldostools Developer Developer

    Joined:
    Oct 30, 2014
    Messages:
    3,288
    Likes Received:
    5,405
    Trophy Points:
    522
    I don't have much time either... I don't recall if the order of the parameters is inverted, it could be tried.
    You can try also changing the order of the lines.,

    webMAN is loaded early enough because the command "mute coldboot" works (it remaps the coldboot files to a dummy file).

    if the VSH is patched to use mp3, I think you only would need to redirect the sprx

    Or you could do it the opposite... have the files already patched or swapped, then use the script to "unpatch" the files, redirecting them to the original files.

    In this case, the timing is irrelevant because the redirection could be done few seconds later.
     
    DeViL303 likes this.

Share This Page