I'm tired with testing all that stuff. First part here
OPL do not load ISO in the correct way or maybe something was wrong with my code.
Sometimes it's working and files read ok from the ISO, but sometimes it stuck.
Event 2-3 copies of the same ISO returns different results!!
So I've moved all data to the header files and load everything from the memory. Works fine and I'm happy.
You can use ps2dev/ps2sdk/bin/bin2c program or make your own.
Just a remind that filnames in the disc image should be all uppercases and short because PS2 will reading only from ISO9660 8+3.
To create ISO I've used the command
genisoimage -udf -o ISONAME.ISO bin/ps2_iso_folder
Then another issue with incorrect BMP colors. I found the patch for SDL3 but it was not merged to SDL2 branch. So I've create a fix based on that.
https://github.com/libsdl-org/SDL/issues/12395
https://github.com/libsdl-org/SDL/pull/14226/commits/82778d4ff98ab40b2467fafe9f6ae681e8255e5c
https://github.com/libsdl-org/SDL/commit/faa8fc2917e6c24bc3785facecf35ae29a3176b5
Information about IRX files.
https://www.retroreversing.com/irx-ps2
https://www.psdevwiki.com/ps2/IRX_Files
OPL Loader debug colors
https://github.com/israpps/israpps/blob/main/OPL_EE_CORE_DEBUG_COLORS.MD