[Back to Index]

[00:10] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/JfWbH
[00:10] <Scummette> scummvm/master 48e949e sev-: MOHAWK: Fix typo in Italian Riven menu
[00:35] <ScummBot> Port build status changed with 8ff38d74: Success: master-psp2full, master-wii, master-ps3
[01:29] <ScummBot> Port build status changed with 8ff38d74: Success: master-psp2, master-caanoo, master-dingux, master-gamecube, master-gp2xwiz
[01:32] <-- SylvainTV left irc: Read error: Connection reset by peer
[01:36] --> DominusExult joined #scummvm.
[01:36] <-- DominusExult left irc: Changing host
[01:36] --> DominusExult joined #scummvm.
[01:40] <-- Dominus left irc: Ping timeout: 256 seconds
[01:40] Nick change: DominusExult -> Dominus
[01:49] <ScummBot> Port build status changed with 8ff38d74: Success: master-gcw0
[01:51] <-- omgpizzaguy left irc: Ping timeout: 256 seconds
[01:55] <ScummBot> Port build status changed with 8ff38d74: Success: master-switch
[02:14] <Scummette> [scummvm] ScummVM-Translations pushed 2 new commits to master: https://git.io/JfWxH
[02:16] <Scummette> scummvm/master 431a194 IlDucci: I18N: Update translation (Spanish)
[02:16] <Scummette> scummvm/master 6f0d281 antoniou79: I18N: Update translation (Greek)
[02:16] <Scummette> [scummvm] dreammaster pushed 1 new commits to master: https://git.io/JfWxx
[02:16] <Scummette> scummvm/master 88cdad7 dreammaster: XEEN: Fix loading of wall items from savegame
[02:25] --> BeefEats joined #scummvm.
[02:45] <-- speachy left irc: Quit: WeeChat 2.8
[03:07] <Lightkey> monyarm: Just looked at Persona 3 and it's using RenderWare.. good luck with that. That reminds me that last month, the RenderWare engine for Grand Theft Auto III was fully reversed, by implementing one function at a time, I heard about it in #openrw though they are unrelated: https://github.com/GTAmodding/re3
[03:17] --> travis-ci joined #scummvm.
[03:17] <travis-ci> scummvm/scummvm#13248 (master - 88cdad7 : Paul Gilbert): The build has errored.
[03:17] <travis-ci> Change view : https://github.com/scummvm/scummvm/compare/6f0d281eed66...88cdad7f84bf
[03:17] <travis-ci> Build details : https://travis-ci.org/scummvm/scummvm/builds/685475852
[03:17] travis-ci (travis-ci@ left #scummvm.
[03:31] --> speachy joined #scummvm.
[03:44] <-- mataniko left irc: Quit: ZNC - https://znc.in
[03:46] --> mataniko joined #scummvm.
[03:46] #scummvm: mode change '+o mataniko' by ChanServ!ChanServ@services.
[04:05] <-- mataniko left irc: Ping timeout: 240 seconds
[04:05] --> mataniko_ joined #scummvm.
[04:05] #scummvm: mode change '+o mataniko_' by ChanServ!ChanServ@services.
[04:49] --> Shine joined #scummvm.
[04:51] --> mataniko joined #scummvm.
[04:51] #scummvm: mode change '+o mataniko' by ChanServ!ChanServ@services.
[04:53] <-- mataniko_ left irc: Ping timeout: 272 seconds
[05:26] <-- dreammaster left irc:
[05:31] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/JflvN
[05:44] <Scummette> scummvm/master 78e7df4 sev-: DIRECTOR: Return to Launcher is not really supported.
[05:44] <Scummette> [scummvm] sev- pushed 3 new commits to master: https://git.io/JflfB
[05:44] <Scummette> scummvm/master bcc9c81 sev-: PSP: Fix compilation
[05:44] <Scummette> scummvm/master fc54286 sev-: ANDROID: Fix compilation
[05:44] <Scummette> scummvm/master 449f895 sev-: 3DS: Fix compilation
[05:52] <Scummette> [scummvm] sev- closed pull request #2214: IMAGE: Add support for Crusader: No Remorse movie decoding (master...crusader_movie_decoding) https://git.io/JfO6E
[05:52] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/JflJJ
[05:52] <Scummette> scummvm/master 818e681 mduggan: IMAGE: Add support for Crusader: No Remorse movie decoding
[05:57] --> travis-ci joined #scummvm.
[05:57] <travis-ci> scummvm/scummvm#13249 (master - 78e7df4 : Eugene Sandulenko): The build passed.
[05:57] <travis-ci> Change view : https://github.com/scummvm/scummvm/compare/88cdad7f84bf...78e7df4293ed
[05:57] <travis-ci> Build details : https://travis-ci.org/scummvm/scummvm/builds/685510525
[05:57] travis-ci (travis-ci@ left #scummvm.
[06:10] --> Begasus joined #scummvm.
[06:26] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/Jflkk
[06:26] <Scummette> scummvm/master b11a2ae sev-: ANDROID: Fix reference
[06:30] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/Jflku
[06:30] <Scummette> scummvm/master ca25a95 sev-: 3DS: Remove extra dereferencing
[06:30] <-- Shine left irc: Read error: Connection reset by peer
[06:46] <-- Begasus left irc: Ping timeout: 240 seconds
[06:48] --> Begasus joined #scummvm.
[06:50] <-- ced117 left irc: Ping timeout: 240 seconds
[06:52] --> ced117 joined #scummvm.
[07:07] <-- Lightkey left irc: Ping timeout: 240 seconds
[07:14] --> Shine joined #scummvm.
[07:20] --> Lightkey joined #scummvm.
[07:29] <ScummBot> Port build status changed with 818e6817: Success: master-pspfull
[07:31] <ScummBot> Port build status changed with 818e6817: Success: master-psp
[07:43] <-- Shine left irc: Read error: Connection reset by peer
[07:44] <-- _sev left irc: Quit: This computer has gone to sleep
[07:46] <ScummBot> Port build status changed with ca25a95e: Success: master-3ds
[07:53] --> _sev joined #scummvm.
[07:53] #scummvm: mode change '+o _sev' by ChanServ!ChanServ@services.
[07:57] <-- yuv422 left irc: Remote host closed the connection
[07:57] --> yuv422 joined #scummvm.
[07:57] #scummvm: mode change '+o yuv422' by ChanServ!ChanServ@services.
[08:04] --> vliaskov joined #scummvm.
[08:05] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/JflYw
[08:05] <Scummette> scummvm/master a211e9d sev-: ANDROID: Instantiate static class variable
[08:09] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/JflYQ
[08:09] <Scummette> scummvm/master 2f9c28a sev-: ANDROID: Another blind attempt to fix compilation. Sigh
[08:10] <grogbot> <sev> 🤦
[08:10] <grogbot> <sev> how many more attempts to fix the thing...
[08:11] --> Shine__ joined #scummvm.
[08:13] nutron (~nutron@unaffiliated/nutron) got netsplit.
[08:13] freanux (~freanux@unaffiliated/freanux) got netsplit.
[08:15] nutron (~nutron@unaffiliated/nutron) returned to #scummvm.
[08:15] <bgK> the 3DS port still looks incorrect because of using the same PauseToken for two different things. I'll test and fix when switching back from work stuff
[08:17] <grogbot> <sev> thanks!
[08:20] <ScummBot> Port build status changed with 2f9c28a6: Success: master-android_x86, master-android_x86_64, master-android_arm_v7a, master-android_arm64
[08:24] freanux (~freanux@unaffiliated/freanux) got lost in the net-split.
[08:40] --> ajax16384 joined #scummvm.
[08:40] #scummvm: mode change '+o ajax16384' by ChanServ!ChanServ@services.
[09:21] <-- _sev left irc: Quit: This computer has gone to sleep
[09:22] --> _sev joined #scummvm.
[09:22] <-- _sev left irc: Changing host
[09:22] --> _sev joined #scummvm.
[09:22] #scummvm: mode change '+o _sev' by ChanServ!ChanServ@services.
[09:37] <-- _sev left irc: Read error: Connection reset by peer
[09:37] --> _sev_ joined #scummvm.
[09:37] #scummvm: mode change '+o _sev_' by ChanServ!ChanServ@services.
[09:55] <-- BeefEats left irc: Quit: Bye
[10:08] <-- yuv422 left irc: Remote host closed the connection
[10:09] --> yuv422 joined #scummvm.
[10:09] #scummvm: mode change '+o yuv422' by ChanServ!ChanServ@services.
[10:21] <Scummette> [scummvm] mduggan pushed 2 new commits to master: https://git.io/JflcE
[10:36] <grogbot> <Henke37> thanks for putting in the effort to clean up my mess.
[11:02] --> JohnnyonFlame joined #scummvm.
[11:25] <-- yuv422 left irc: Remote host closed the connection
[11:25] --> yuv422 joined #scummvm.
[11:25] #scummvm: mode change '+o yuv422' by ChanServ!ChanServ@services.
[11:27] <yuv422> I've been playing around with music support for Blazing Dragons. I copied the tinsel engine and added a midiplayer that converts the PS1 SEQ format into standard SMF
[11:27] <yuv422> Obviously with standard instruments it sounds terrible
[11:28] <yuv422> I converted the PS1 VAB data into a soundfont2 file and everything sounds great.
[11:28] <yuv422> I was wondering how people would feel if I added support to automatically convert the VAb data into soundfont format and load it into the midi driver
[11:29] <yuv422> I really don't want to have to reimplement a whole SEQ player when it is soo close to the SMF standard
[11:30] <yuv422> This would also help discworld PS1 music support
[12:04] --> grogbot3 joined #scummvm.
[12:04] <-- grogbot left irc: Remote host closed the connection
[12:05] Nick change: grogbot3 -> grogbot
[12:14] <Scummette> scummvm/master 3666253 mduggan: ULTIMA8: Correct capitalization of mouse functions
[12:14] <Scummette> scummvm/master bfb32aa mduggan: ULTIMA8: Add basic avatar keyboard movement
[12:14] <Scummette> [scummvm] ScummVM-Translations pushed 1 new commits to master: https://git.io/Jfl8B
[12:31] <Scummette> scummvm/master 03c44d2 : I18N: Update translation (French)
[12:31] <Scummette> [scummvm] antoniou79 pushed 1 new commits to master: https://git.io/Jfl4m
[12:31] <Scummette> scummvm/master 210d50c antoniou79: BLADERUNNER: Add explanatory comment on the check of _gameJustLaunched flag
[12:32] --> brooksy joined #scummvm.
[12:33] <-- borosky left irc: Ping timeout: 272 seconds
[13:03] <-- yuv422 left irc: Remote host closed the connection
[13:04] --> yuv422 joined #scummvm.
[13:04] #scummvm: mode change '+o yuv422' by ChanServ!ChanServ@services.
[13:06] <grogbot> <sev> ScummVM has been accepted to Google Season of Docs!
[13:09] <grogbot> <𝚗7
[13:13] <grogbot> <Henke37> oh? is this different from gsoc?
[13:20] <grogbot> <sev> @Henke37 https://developers.google.com/season-of-docs
[13:23] <grogbot> <Henke37> i will have to look into that
[13:59] <-- _sev_ left irc: Quit: This computer has gone to sleep
[14:01] --> _sev_ joined #scummvm.
[14:01] #scummvm: mode change '+o _sev_' by ChanServ!ChanServ@services.
[14:24] <grogbot> <monyarm> You guys remember how we talked about nested archives the other day?
[14:24] <grogbot> <monyarm> I found a really weird example out in the wild
[14:25] <grogbot> <monyarm> Rosario+Vampire Capu 2 for the PS2 has a file called RVCAPU2.AFS AFS is a criware format that usually just hold ADX audio. RVCAPU2.AFS contains 6 files, 1 bin file, and 5 AFS files, all 6 of these files are nameless, And each AFS file is a regular AFS file containing different files within itself.
[14:29] <grogbot> <Henke37> okay. so far so good.
[14:29] <grogbot> <Henke37> let's hear the twist
[14:30] <grogbot> <monyarm> AFS files containing AFS files, That's like having zip files in zip files
[14:31] <grogbot> <Henke37> been there, seen that. is that all that's strange about it?
[14:40] <grogbot> <madmoose> Its pretty strange in a game with where disc io is usually a sparse resource.
[14:40] <grogbot> <madmoose> Zips in zips are still strange even if youve seen the before.
[15:28] --> systwi joined #scummvm.
[15:28] <-- systwi_ left irc: Ping timeout: 260 seconds
[15:30] --> omgpizzaguy joined #scummvm.
[15:35] <grogbot> <trembyle> Is anyone who works on the softsynths on this discord / irc?
[15:35] <grogbot> <trembyle> I wanted to ask if it was possible to port the Nuked-OPN2 code for use in FM Towns.
[15:35] <grogbot> <trembyle> and how difficult that is
[15:40] <grogbot> <trembyle> Actually it looks like nukeykt himself originally ported Nuked-OPL3 to ScummVM. So maybe asking him would make more sense.
[16:08] <-- girafe2 left irc: Ping timeout: 246 seconds
[16:29] <Scummette> [scummvm] bgK pushed 1 new commits to master: https://git.io/Jflwp
[16:29] <Scummette> scummvm/master dad5571 bgK: 3DS: Fix crash when closing the console while the 3DS options dialog is open
[16:30] <bgK> any reason for not having an API like this: EnginePauser pauser(g_engine); that would be null safe?
[16:39] <-- omgpizzaguy left irc: Ping timeout: 256 seconds
[16:39] <grogbot> <sev> bgK: no reason
[16:40] <grogbot> <monyarm> f.open isn't finding my file, even though it exists, is there any kind of function I can use to print all files/folders Searchman can find
[16:43] <grogbot> <sev> yes, warning() or debug()
[16:43] <grogbot> <monyarm> OK, let me rephrase, what function should I use to get a list of all files
[16:46] <grogbot> <sev> for (and-put-iterators-over-hash-of-files)
[16:47] <grogbot> <monyarm> You misunderstand, I'm not looking to iterate over the files in my archive. It can't find my archive. I'm trying to ask how to get the list of file that I'd iterate through
[16:53] <grogbot> <sev> and I understand you correctly. that is how you can obtain the file list
[16:54] <grogbot> <sev> of course, there are other much more complicated things like inserting hooks into your OS and showing what the process reads from the disk, but anyway, you will have to resort on some kind of printf()
[16:54] <grogbot> <monyarm> But how do I obtain the hashmap I'm supposed to iterate over, that's the part in asking about
[16:54] <grogbot> <sev> or maybe lsof will work
[16:55] <grogbot> <monyarm> I know how to log and how to iterate
[16:55] <grogbot> <sev> in the Archive class?
[16:55] <grogbot> <monyarm> No
[16:55] <grogbot> <monyarm> In my engine
[16:55] <grogbot> <sev> Yes
[16:55] <grogbot> <sev> File::open uses Archive internally
[16:56] <grogbot> <sev> so, go in there, print that out
[16:59] <grogbot> <monyarm> in common/archive.cpp?
[16:59] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/Jflrb
[16:59] <Scummette> scummvm/master 3f82f6d sev-: DIRECTOR: LINGO: Fixed preprocessor for play and sound clauses
[17:03] <grogbot> <monyarm> Common::ArchiveMemberList list; SearchMan.listMembers(list); for(auto l : list) { auto _l = l.get(); debug(_l->getName().c_str()); } I ended up doing this, and i think i figured out the issue
[17:05] <grogbot> <monyarm> Common::Archive *pak = makePAKArchive("STREAM.PAK"); SearchMan.add("STREAM.pak", pak, 99, false); I did this in my constructor, and when i listed all of the files searchman can find, it shows them all, but i was expecting it to show a STREAM.PAK, and for me to have to make a fsnode out of it to get the actual contents, and not for them to be included with the rest
[17:07] <grogbot> <sev> fsnode is for files on FS
[17:07] <grogbot> <monyarm> Infact, looking through the whole list, it's also listing files in directories which i haven't added to SearchMan
[17:07] <grogbot> <sev> how you can get fsnode from inside of your archive?
[17:07] <grogbot> <sev> and why do you need fsnode after all?
[17:07] <grogbot> <monyarm> I was under the impression that i'd have to use the name i gave it in order to access the files
[17:08] <-- ced117 left irc: Ping timeout: 256 seconds
[17:08] <grogbot> <monyarm> cause otherwise i'm not sure what the point of SearchMan.add is?
[17:09] <grogbot> <madmoose> @monyarm SearchMan is a mystery to me 🙂
[17:09] --> ced117 joined #scummvm.
[17:09] <grogbot> <monyarm> Same here
[17:10] <grogbot> <monyarm> what i want is to be able to find files based on the archive they're supposed to be from, not have them all dropped in the same place.
[17:12] <grogbot> <DreamMaster> Cases like that it why Common::File::open has an optional parameter for a specific archive to use. Otherwise, as I understand SearchMan, when you specify to open a file, it iterates over each archive implementation registered with SearchMan, and passes the filename to it. It's then up to the methods of the Archive like hasFile and createReadStream to know whether the file is present in your archive and return a reference to erad it
[17:14] <grogbot> <monyarm> I see, so i'm gonna have to keep variables for each of my archives, and when i want to open a file from a specific archive, pass that to searchman, and then wonder how this would work for the games that have nested archives
[17:15] <grogbot> <antoniou79> @sev I'm thinking about making minor tweaks for the boot parameters feature for Blade Runner. Stuff like parameter validation and launching directly to the selected scene even if there are saved games (currently it launches into KIA first in that case, and if you load a saved game it overrides the boot parameter).
[17:16] <grogbot> <antoniou79> Is this ok? Or did we intend to remove this feature? I will also document it on the wiki (on the Blade Runner page, since it's not official boot parameters)
[17:17] <-- _sev_ left irc: Ping timeout: 256 seconds
[17:18] --> _sev joined #scummvm.
[17:18] #scummvm: mode change '+o _sev' by ChanServ!ChanServ@services.
[17:20] <grogbot> <sev> well, bootparams are excellent tool for debugging purposes, especially when there are no savegames, or they're broken
[17:20] <grogbot> <sev> any advancements to that are always useful
[17:20] <grogbot> <antoniou79> ok, then
[17:22] <Scummette> [scummvm] sev- pushed 1 new commits to master: https://git.io/Jflo5
[17:22] <Scummette> scummvm/master 5743331 sev-: DIRECTOR: LINGO: Fixed 'play' keyword preprocessing
[17:25] --> girafe joined #scummvm.
[17:42] <grogbot> <SupSuper> @monyarm you only need SearchMan when you want to find a file and you don't know where it is. once you got an Archive you can query it directly for contents
[17:51] --> omgpizzaguy joined #scummvm.
[17:55] <-- _sev left irc: Quit: Leaving
[17:56] <grogbot> <Henke37> i think the problem here is that he wants to automatically navigate a tree of archives (many nested).
[17:59] <grogbot> <monyarm> Ya, someting like that
[18:01] <grogbot> <SupSuper> right, at that point it might be better rolling your own finder. my understanding is that SearchMan treats archives as an aggregate whole, so it's good when you have files that might be in a multitude of flat archives and you don't really care where, but not when they're a tree with a common root
[18:02] <grogbot> <monyarm> Ya, making my own would be best, for the current game, just keeping a hashmap of archive names to archives, and using f.open will do, but for others i'll need a custom solution
[18:04] <grogbot> <SupSuper> if you know the type of every archive by file extension you can probably write something that takes a path like "A.FOO/B.BAR/C.ZIP/D.000/E.FGH" and resolves each part one by one
[18:05] <grogbot> <SupSuper> or write something like FSNode that caches and iterates the whole filesystem tree and you can poke at it later
[18:05] <grogbot> <SupSuper> since you're basically dealing with virtual filesystems
[18:06] <grogbot> <monyarm> That'll work for the most part, untill you get to the Persona games which have about 5 different formats for bin files, 4 of which are archives. and they're all named stuff like 001.bin or bg005.bin
[18:07] <grogbot> <Henke37> you may need some sort of rule system to determinate which archive format to use. which isn't just based on the file extension
[18:09] <grogbot> <monyarm> will probably have to have either a single archive class for all of the bins, which detects which one it is, or have my finder try all of them, untill it finds one that works.
[18:11] <grogbot> <Henke37> or use a rule database that knows which formats are used where in the virtual file system that the archives make up. or a sniffer that can tell which format a file has.
[18:11] <grogbot> <monyarm> will also need to have it be weighted, and have virtual folders So for Persona 5 for example: "data/whateverfile" data would search mod.cpk, ps4.cpk, ps3.cpk, hdd.cpk, data.cpk in that order, since p5 has multiple data archives, and has different priority for the different ones
[18:12] <grogbot> <SupSuper> that sort of stuff is what SearchMan is good for
[18:12] <grogbot> <monyarm> I think the following would work: Have it assume based on the file extension, then test, if it's right, it uses what it assumed, if not, then it'll test all of them
[18:13] <grogbot> <monyarm> Ya, but combining searchman and directories like i want will be the issue here. Hmm, maybe i can have it so paths can be set to use an archive/searchset, that would work.
[18:14] <grogbot> <SupSuper> right when i say SearchMan i mean something similar, since it's basically a global Archive, you can make your own if it suits you
[18:15] --> SylvainTV joined #scummvm.
[18:15] #scummvm: mode change '+o SylvainTV' by ChanServ!ChanServ@services.
[18:19] <Scummette> [scummvm] dwatteau opened pull request #2241: AGOS: Fix compatibility with strict-alignment architectures (master...fix/agos-strict-alignment) https://git.io/Jfl6F
[18:22] <grogbot> <monyarm> well, i've added it as an issue to my fork https://github.com/monyarm/NovelVM/issues/2 hopefully i'll finish it soon, and can then create a pull request, and push it upstream, cause i imagine it's something that would be useful for others, not just me
[18:28] <grogbot> <monyarm> hmm, this isn't working i'm getting no matching function for call to Common::File::open(const char [10], Common::ScopedPtr<Common::Archive>::PointerType) 93 | if (!f.open("BGM01.WAV", _archives["STREAM.PAK"].get())) _archives is a Common::HashMap<Common::String, Common::ScopedPtr<Common::Archive>, Common::IgnoreCase_Hash, Common::IgnoreCase_EqualTo> What am i missing? f.open was supposed to be able to take an archive
[18:33] <grogbot> <DreamMaster> Try doing a * on the _archives[.. to get a reference to the archive rather than just the pointer.. maybe?
[18:33] <grogbot> <monyarm> Ya, that worked, thanks
[18:33] <grogbot> <DreamMaster> Cool
[18:35] <grogbot> <monyarm> Though now i'm having another issue, inside my Archive Subclass, f.open() doesn't work I used debug() to log all of the files that Searchman can find, and it only finds the files in the working directory, not in the game directory
[18:37] <grogbot> <DreamMaster> One gotcha that I've encountered previously is that you should only register your archives with SearchMan inside the engine's run method, or an initialization method you call from it. Not the engine's constructor. At the point the constructor is called, the paths aren't yet properly set up.
[18:38] <grogbot> <DreamMaster> Or something along the lines. I can't remember the details exactly, just that setting up things like that in the constructor caused all sorts of issues for me previously
[18:38] <grogbot> <monyarm> I'm not using searchman for my archives, i'm using a hashmap, and f.open to get files from my archives
[18:38] <grogbot> <DreamMaster> But are you opening the contents of the archive up at that point each time, or are you trying to load an index for the archive when you first create it?
[18:38] <grogbot> <monyarm> But even so, moving my code to run made it work
[18:39] <grogbot> <monyarm> Common::Archive *A98FAST_PAK = makePAKArchive("A98FAST.PAK"); _archives["A98FAST.PAK"].reset(A98FAST_PAK); Common::Archive *A98SYS_PAK = makePAKArchive("A98SYS.PAK"); _archives["A98SYS.PAK"].reset(A98SYS_PAK); Common::Archive *STREAM_PAK = makePAKArchive("STREAM.PAK"); _archives["STREAM.PAK"].reset(STREAM_PAK); /* Common::Archive *VOICE_PAK = makePAKArchive("VOICE.PAK"); Common::Archive *VOICE2_PAK =
[18:39] <grogbot> makePAKArchive("VOICE2.PAK"); */
[18:39] <grogbot> <monyarm> this is the code, to answer your question
[18:39] <grogbot> <DreamMaster> Cool 🙂
[18:39] <grogbot> <monyarm> Though, you know one thing i hate? When games have files with the same extensions that are different formats
[18:40] <grogbot> <DreamMaster> I hear you. It was an unfortunate early design decision from Infocom to call their games' extension '.ZIP' in the years before zip files become a common format. 😛
[18:41] <grogbot> <DreamMaster> Z-Machine Interpreter Program
[18:41] <grogbot> <monyarm> Actually i was referring to the PAK files from the game i'm working on
[18:41] <grogbot> <monyarm> there's a reason the two VOICE files are commented out
[18:44] <grogbot> <monyarm> Say, which is the preferred way to open a file in an archive auto bw = _archives["STREAM.PAK"].get()->createReadStreamForMember("BGM01.WAV"); if (!f.open("BGM01.WAV", *_archives["STREAM.PAK"].get())) { debug("can't read archive"); }
[18:45] <-- Begasus left irc: Quit: Ex-Chat
[18:47] <grogbot> <Henke37> from a data point, the File class retains the filename. the stream does not
[18:48] <grogbot> <DreamMaster> I'm not sure either matters too much. Though I take a leaning towards using Common::File, since when a Common::File goes out of context, it will automatically close and delete the stream without you having to explicitly do it.
[18:50] --> ny00123 joined #scummvm.
[18:53] <grogbot> <monyarm> There's that, but when using file, it seems i'll have to try and figure out the stream size
[19:00] <grogbot> <monyarm> Since a pure SeekableAudioStream isn't allowed, what should i use instead? Audio::SeekableAudioStream str; str = Audio::makeWAVStream(f.readStream(f.size()),DisposeAfterUse::NO); _mixer->playStream(Audio::Mixer::SoundType::kMusicSoundType, &sh, &str);
[19:02] <grogbot> <DreamMaster> I'm not sure what you mean by "isn't allowed". That also looks dangerous.. you should have Audio::SeekableAudioStream *str = ..., DisposeAfterUse::YES. Then pass the seekable audio stream pointer into playStream, also with DisposeAfterUse::YES. That way everything will be cleaned up for you without you having to keep a reference to the audio stream separately and manually clean it up
[19:03] <grogbot> <monyarm> object of abstract class is not allowed, that's what i mean
[19:05] <grogbot> <DreamMaster> That's likely because you're trying to instantiate SeekableAudioStream in your first line, rather than it being a pointer. makeWAVStream internally creates an object that's a descendant of SeekableAudioStream and returns it, which is why you need str to be a pointer.. It doesn't need to know what type the make methods returns, just that it will always support whatever SeekableAudioStream does
[19:05] <grogbot> <monyarm> and now i'm getting a seg fault
[19:05] <grogbot> <DreamMaster> Also even if it worked, by not having str be a pointer, it would go out of context and be freed at the end of the method
[19:06] <grogbot> <DreamMaster> And you'd have playStream trying to access an already destroyed object
[19:07] <grogbot> <monyarm> Ya, i just noticed and fixed that Audio::SoundHandle *sh = new Audio::SoundHandle(); if (!f.open("BGM01.WAV", *_archives["STREAM.PAK"].get())) { debug("can't read archive"); } Audio::SeekableAudioStream *str; str = Audio::makeWAVStream(f.readStream(f.size()),DisposeAfterUse::YES); _mixer->playStream(Audio::Mixer::SoundType::kMusicSoundType, sh, str); But i'm still getting a sig fault at playStream.
[19:07] <grogbot> <monyarm> any ideas?
[19:10] <grogbot> <monyarm> is it my f.readStream(f.size()) ? I assume that that would create a seekablestream out of the whole file
[19:12] <grogbot> <SupSuper> i think you can pass f directly since Files are SeekableReadStreams
[19:14] <grogbot> <monyarm> Ya, i can, but i'm still getting the same seg fault #0 EngineName::EngineNameEngine::run() (this=0x5555564c7510) at engines/enginename/enginename.cpp:84 #1 0x00005555555b35aa in runGame(Plugin const*, OSystem&, Common::String const&) (plugin=0x555555a7f9e0, system=..., edebuglevels=...) at base/main.cpp:292 #2 0x00005555555b48bf in scummvm_main(int, char const* const*) (argc=1, argv=0x7fffffffdc18) at base/main.cpp:559 #3
[19:14] <grogbot> 0x00005555555b0ddc in main(int, char**) (argc=1, argv=0x7fffffffdc18) at backends/platform/sdl/posix/posix-main.cpp:45
[19:15] <-- ajax16384 left irc: Quit: Leaving
[19:16] --> ajax16384 joined #scummvm.
[19:16] #scummvm: mode change '+o ajax16384' by ChanServ!ChanServ@services.
[19:16] <grogbot> <DreamMaster> No, actually, f.readStream(f.size()) is a good idea, because since f isn't a pointer, but a Common::File, it will close and go out of context when the method ends. Calling f.readStream creates a separate stream instance in memory that can belong to whatever the makeWavStream creates
[19:17] <grogbot> <monyarm> Ok, changing it back to f.readStream(f.size())
[19:18] <grogbot> <Henke37> btw, there is a better option than the debug function for actual errors. error I think it was?
[19:18] <grogbot> <DreamMaster> Oh, and I'm not sure about creating soundHandle dynamically. I normally keep it as a field of whatever class I call the playStream within, so I can later query it to see if the stream is playing or not
[19:18] <grogbot> <DreamMaster> Yep. error
[19:18] <-- omgpizzaguy left irc: Ping timeout: 256 seconds
[19:19] <grogbot> <monyarm> ok, i just made it into a field, still same seg fault though
[19:19] <grogbot> <DreamMaster> Though error force quits the game, so warning is better if you want to just give a warning message but still allow to keep running
[19:21] <grogbot> <DreamMaster> It may help if I can see the context. If you could commit in what you have so far, and paste a Github URL for it?
[19:22] <grogbot> <monyarm> github.com/monyarm/novelvm do you also want a copy of the stream.pak archive, to be able to actually run the engine to test it?
[19:24] <grogbot> <DreamMaster> Well, let me look at the code first, see if I can notice anything wrong. Which file is the code in question in?
[19:25] <grogbot> <monyarm> the game is nsfw, so i'm not sure if i can say it here, so i'll pm you the filename
[19:27] <Scummette> [scummvm] antoniou79 pushed 1 new commits to master: https://git.io/JflXm
[19:27] <Scummette> scummvm/master a772bbb antoniou79: BLADERUNNER: Validation of boot params and skip of KIA screen
[19:55] <-- ajax16384 left irc: Quit: Leaving
[20:06] --> omgpizzaguy joined #scummvm.
[20:20] --> criezy joined #scummvm.
[20:20] #scummvm: mode change '+o criezy' by ChanServ!ChanServ@services.
[20:33] <-- Shine__ left irc: Read error: Connection reset by peer
[20:33] --> BeefEats joined #scummvm.
[20:55] <grogbot> <antoniou79> just a quick check, is anyone else having trouble switching to full-screen mode on Linux (I'm trying on Ubuntu 16.04 -- I know it's old, but I won't upgrade to the new one just yet)
[20:56] <grogbot> <rootfather> I can only speak for Ubuntu 18.04 and Ubuntu 20.04 (running GNOME and KDE) and I didn't ran into issues
[20:56] <grogbot> <antoniou79> hmm, ok. It may be something misconfigured on my side
[20:57] <grogbot> <rootfather> what's happening exactly when you try to toggle full screen?
[20:59] <grogbot> <antoniou79> I either get a black screen with a cursor, but then I'm unable to even close the app (no shortcuts work, neither Alt-Tab) so I have to switch to a another terminal (via eg. Ctrl-Alt-F1) and kill the process. Or, I'll get thrown back to the terminal that I launched Scummvm from, and I can only Ctrl-C my way out of it then. WIndowed works fine
[20:59] <grogbot> <rootfather> hm. Unity or GNOME?
[20:59] <grogbot> <Henke37> anything in the log?
[21:00] <grogbot> <antoniou79> Unity
[21:00] <grogbot> <antoniou79> Hm let me check
[21:01] <grogbot> <Henke37> let's see if it's another PauseToken issue. it seems to be that week.
[21:01] <grogbot> <antoniou79> Nothing special on the log
[21:01] <grogbot> <antoniou79> I mean it looks exactly the same with launching in windowed mode and then quiting
[21:02] <grogbot> <antoniou79> I'll try a reboot too
[21:06] --> _sev joined #scummvm.
[21:06] <-- _sev left irc: Changing host
[21:06] --> _sev joined #scummvm.
[21:06] #scummvm: mode change '+o _sev' by ChanServ!ChanServ@services.
[21:23] --> _athrxx joined #scummvm.
[21:23] <-- _athrxx left irc: Client Quit
[21:23] <grogbot> <monyarm> I'm on the I3 desktop environment, and it's working fine for me
[21:25] --> _athrxx joined #scummvm.
[21:27] <-- _athrxx left irc: Client Quit
[21:28] <grogbot> <monyarm> Can someone give me a bare minimum example of loading image data and showing it on screen?
[21:29] <grogbot> <rootfather> for a bare minimum engine, I suggest to look at PLUMBERS
[21:29] <grogbot> <rootfather> since the engine does basically nothing but exactly this 😉
[21:31] <-- _sev left irc: Quit: This computer has gone to sleep
[21:35] --> _sev joined #scummvm.
[21:35] <-- _sev left irc: Changing host
[21:35] --> _sev joined #scummvm.
[21:35] #scummvm: mode change '+o _sev' by ChanServ!ChanServ@services.
[21:35] <grogbot> <antoniou79> ok, the snap store version works correctly for me. It's my builds that have the issue -- so it could some badly configured or outdated library issue
[21:35] <grogbot> <antoniou79> (Snap store version is 2.1.2 May 2)
[21:40] <grogbot> <monyarm> Ok, only question about loading an image from a stream, my image is a 1024 byte palette (256*4) then the image data. I've got my engine set to true color, how do i get my data into something that would be accepted by an image decoder? Is there a way to give it raw image data and a palette and dimensions and be done with it?
[21:45] <grogbot> <SupSuper> if it's raw data, you don't need a decoder, just read those pixels into a Surface
[21:46] <grogbot> <DreamMaster> Right. If your image has a palette, then presumably each pixel is a byte, and is an index into that palette. So you could create a 32-bit Graphics::Surface, and then iterate through the pixel bytes to add entries from your palette for each pixel.
[21:47] <grogbot> <Henke37> seems like something that should be automated by the graphics subsystem
[21:47] <grogbot> <monyarm> I'm currently just testing to see if i'm doing things right, i'm going to automate the boring stuff later
[21:48] <grogbot> <Henke37> i mean that your new engine is far from the first engine that has paletted graphics
[21:49] <grogbot> <DreamMaster> Well, Graphics::ManagedSurface has methods for setting a local palette just for that surface, and then you can blit the resulting surface.
[21:50] <grogbot> <SupSuper> right, it's not about converting formats, just getting the data into something scummvm understands
[21:51] <grogbot> <SupSuper> you can have surfaces with any pixel format and let the graphics system convert it to the display format, or convert them ahead of time, or whatever depending on what works for you
[21:51] <grogbot> <antoniou79> Sorry to interrupt again, but I'm happy to report that the issue with the full screen got resolved. I uninstalled all SDL2 related stuff and build SDL2 from source, and now it's working fine 🙂
[21:51] <grogbot> <DreamMaster> Things are easier in cases where the entire game uses a standardized palette, then you can just use g_system->getPaletteManager().setPalette to set the palette, and have 8-bit surfaces that can blitted to the screen
[21:51] <grogbot> <monyarm> Problem is my game doesn't, it's true color and each image has it's own palette
[21:51] <grogbot> <monyarm> So, is Surface or Managed Surface better for doing what i want to do?
[21:52] <grogbot> <SupSuper> if the palette is just a format optimization it's better to just convert it to RGB pixels
[21:52] <-- omgpizzaguy left irc: Remote host closed the connection
[21:52] <grogbot> <DreamMaster> Both have their good points. Graphics::Surface may be easier to start off with.. it just means you'll have to create the surface as 32-bit, and manually set each pixel from entries in your palette based on the pixel data
[21:52] --> omgpizzaguy joined #scummvm.
[21:53] <grogbot> <SupSuper> Surface and ManagedSurface are mostly the same. the latter has more convenience methods and manages the buffers for you, but also seems to be less tested, so ymmv
[21:53] <grogbot> <monyarm> ya, the palette is format only
[21:53] <grogbot> <Henke37> meanwhile, letting the surface know ahead of time means that you aren't writing duplicate code
[21:55] <grogbot> <DreamMaster> If you've set up a 32-bit video mode, you can pass g_system->getScreenFormat() as a parameter to the surface create to get it to be the same format. Then getPixels() and getBasePtr methods can be used to get a pointer to the data contents of the surface to write. In this case, you'd just need to cast it to an uint32 * and set values for row in sequence
[21:56] <grogbot> <Henke37> does that work on all platforms? seems like the platform would decide the screen format at least in some cases?
[21:57] <grogbot> <DreamMaster> Well, when you instantiate the video mode, you can specify the wanted pixel format you want
[21:57] Last message repeated 1 time(s).
[21:57] <grogbot> <Henke37> in general it seems overly complicated. if you "know" the format the screen should be, why query for it? just hardcode the format used to create the surface.
[21:58] <grogbot> <DreamMaster> Then if a system doesn't support that mode, then the system can't run the given engine. I know there's different methods to get a list of supported video modes, but I've never really used them.
[21:58] <grogbot> <monyarm> I'm currently doing something, which i'm not sure wheter it's smart or not, i'm creating the surface and setting it's pixels in my TMX reading code
[21:58] <grogbot> <DreamMaster> True, you could just as easy do likewise. So long as your pixel format is a field of the engine class, and not some stand-alone global variable, which is bad practice.
[22:00] <grogbot> <DreamMaster> That kind of thing is fine, and is pretty much what all the image decoders do. They create their own surface, and then decode any image onto it, and then have a method const Graphics::Surface *getSurface() const to return a reference to it that can be used for blitting to the screen
[22:00] <grogbot> <Henke37> if you are writing custom code to load pixel data, said code will likely only support one format. might as well hardcode the format it uses then.
[22:03] <grogbot> <monyarm> just one last question, when setting the pixel format, do i have to make it myself, or are there global pixelformats i can just reference?
[22:03] --> ldevulder_ joined #scummvm.
[22:03] <grogbot> <SupSuper> i think there's some const for the common formats like 8-bit and 32-bit
[22:04] <grogbot> <monyarm> also the pixels are BGRA, if creating my own format, do i use byteshift for that?
[22:04] <grogbot> <SupSuper> you can specify that in the pixel format as well
[22:04] <-- girafe left irc: Ping timeout: 258 seconds
[22:05] <grogbot> <monyarm> ya, but how, i'm guessing the 4 byteshift parameters, but how do i use them?
[22:06] <grogbot> <Henke37> i'd take a peek at the conversion functions in pixelformat.h
[22:06] <grogbot> <SupSuper> there's also colormasks.h
[22:07] <grogbot> <SupSuper> i suspect the graphics system has had a lot of evolutions because a lot of stuff isn't super clear, who maps what and converts what where
[22:07] <-- ldevulder left irc: Ping timeout: 256 seconds
[22:07] <grogbot> <SupSuper> i just find the closest engine and copy that 😛
[22:09] <grogbot> <DreamMaster> Ditto 🙂
[22:10] <grogbot> <monyarm> surface->format = Graphics::createPixelFormat<8888>(); This give me what i want
[22:11] <grogbot> <DreamMaster> I've never used that particular method. But cool if it works. It just means you can't manually specify the RGB ordering
[22:12] <grogbot> <DreamMaster> RGBA byte ordering
[22:12] <grogbot> <monyarm> 8888 defaults to BGRA from what i read
[22:12] <grogbot> <monyarm> also i'm now getting a segfault novelvm: graphics/surface.cpp:156: void Graphics::Surface::copyRectToSurface(const Graphics::Surface&, int, int, Common::Rect): Assertion `srcSurface.format == format' failed.
[22:13] --> girafe joined #scummvm.
[22:13] <grogbot> <Henke37> that's not a segfault.
[22:13] <grogbot> <DreamMaster> What's calling it? It sounds like you've got a mismatch of surface types you're copying from/to. Graphics::Surface is fairly limited in the kind of copies it can do
[22:14] <grogbot> <Henke37> ManagedSurface seems like a fix for that
[22:14] <grogbot> <monyarm> i just logged my pixel formats, and my game is defaulting to RGB888
[22:15] <grogbot> <DreamMaster> Perhaps. Though in this case, it may be simpler to pass in the pixel format you got to all the places where you create surfaces so they're all in a common format
[22:15] <grogbot> <monyarm> What if i were to force my game to be BGRA8888?
[22:16] <grogbot> <DreamMaster> You call initGraphics with the specific pixel format you got from createPixelFormat
[22:20] <grogbot> <monyarm> That doesn't seem right
[22:20] <grogbot> <monyarm> https://cdn.discordapp.com/attachments/581224061091446795/709530935611097129/2020-05-12-012152_1920x1080_scrot.png
[22:23] <-- ny00123 left irc: Quit: Leaving
[22:31] <grogbot> <monyarm> i fixed that, but now it's just a grey square on the screen
[22:33] <grogbot> <monyarm> Common::Array<byte> image; for (size_t i = 0; i < dat.formatsettings.width * dat.formatsettings.height; i++) { image.push_back(palette[pixels[i *4 +3]]); image.push_back(palette[pixels[i *4 +2]]); image.push_back(palette[pixels[i *4 +1]]); image.push_back(palette[pixels[i *4 +0]]); } surface = new Graphics::ManagedSurface();
[22:33] <grogbot> surface->w = dat.formatsettings.width; surface->h = dat.formatsettings.height; surface->setPixels(image.data()); debug(Graphics::createPixelFormat<8888>().toString().c_str()); surface->format = Graphics::createPixelFormat<8888>(); Common::Event e; while (!shouldQuit()) { g_system->getEventManager()->pollEvent(e); g_system->delayMillis(10); Graphics::Surface
[22:33] <grogbot> *screen = g_system->lockScreen(); screen->fillRect(Common::Rect(0, 0, g_system->getWidth(), g_system->getHeight()), 0); Graphics::ManagedSurface *surface = _tmx.getSurface(); // = tmxData int w = CLIP<int>(surface->w, 0, g_system->getWidth()); int h = CLIP<int>(surface->h, 0, g_system->getHeight()); int x = (g_system->getWidth() - w) / 2; int y = (g_system->getHeight() - h) / 2;
[22:33] <grogbot> screen->copyRectToSurface(*surface, x, y, Common::Rect(0, 0, w, h)); g_system->unlockScreen(); g_system->updateScreen(); } And yes, i am drawing to the screen every frame, this is just a test so it's fine.
[22:34] <grogbot> <monyarm> This is my code, any ideas why it isn't working?
[22:40] <grogbot> <DreamMaster> That decoding looks support. You have a palette array set up separately, but your image bytes are only bytes? It would make more sense to have your Common::Array<uint32>, and then push the entirety of the palette value based on the given source pixel
[22:41] <grogbot> <monyarm> Ya, but i'm rearanging the palette to fit the 8888 format (ARGB)
[22:43] <grogbot> <DreamMaster> But the point is that the screen is 32-bits bits presumably. You're also creating the ManagedSurface without specifying it's pixel format.. you're just setting the w/h/pixels
[22:43] <grogbot> <monyarm> i'm setting the pixel format after setting the w/h/pixels
[22:44] <grogbot> <DreamMaster> Oh right.
[22:44] <grogbot> <monyarm> changing the setting of the format to be before the pixels doesn't change the end result
[22:46] <grogbot> <DreamMaster> Your palette is presumably 32-bit rgba values, correct? But your pixel array is a Common::Array<byte>. So you shouldn't be doing four reads of pixels and four palette entries just to read one pixel. Plus, you're never even incrementing pixels in your decode loop, so it's always pointing at the start of your pixel data.
[22:47] <grogbot> <DreamMaster> I'd think something like the following: Common::Array<uint32> image; for (size_t i = 0; i < dat.formatsettings.width * dat.formatsettings.height; i++, pixels++) { image.push_back(palette[pixels[i *4]]); }
[22:47] <grogbot> <DreamMaster> Actually, sorry, just (palettte[*pixels]);
[22:48] <grogbot> <monyarm> the palette is 8888BGRA it increments with i++ And why do i need to increment pixels?
[22:49] <grogbot> <DreamMaster> Because currently you're reading in four different pixels each iteration and getting their palette entries, and forcing it down a single byte in your output. Rather, your output array should be uint32 values, to be one per pixel. But you're right, you could just increment i++, and then do image.push_back(palette[pixels[i]);
[22:50] <grogbot> <monyarm> Well, with your code all that changed is the square is now grey, instead of blue
[22:51] <grogbot> <DreamMaster> Progress 🙂
[22:55] <grogbot> <monyarm> well, i decited to dump my image array to a file, and try and open it, and it's broken earlier when i was dumping my palette and image seperately, it was fine
[22:57] <grogbot> <monyarm> doing it your way, give me a red channel, but the other channels are completely black
[22:58] <grogbot> <monyarm> wait i figured it out, the reason why i didn't have image as a uint32 array, my palette data, and my palette untiling function (the palette data is tiled), expect bytes
[23:07] <-- _sev left irc: Quit: This computer has gone to sleep
[23:07] <grogbot> <monyarm> and now i'm getting a seg fault, just great
[23:08] <grogbot> <monyarm> #0 0x00007ffff5c883f5 in __memmove_avx_unaligned_erms () at /usr/lib/libc.so.6 #1 0x0000555555718386 in Graphics::Surface::copyRectToSurface(void const, int, int, int, int, int) (this=0x555555c9f568, buffer=0x7fffc886e010, srcPitch=0, destX=704, destY=284, width=512, height=512) at graphics/surface.cpp:149 #2 0x0000555555718471 in Graphics::Surface::copyRectToSurface(Graphics::Surface const&, int, int, Common::Rect)
[23:08] <grogbot> (this=0x555555c9f568, srcSurface=..., destX=704, destY=284, subRect=...) at graphics/surface.cpp:158 #3 0x00005555555ce95f in SMT::SMTEngine::run() (this=0x5555564f2b80) at engines/smt/smt.cpp:102 #4 0x00005555555b35aa in runGame(Plugin const, OSystem&, Common::String const&) (plugin=0x555555ca2390, system=..., edebuglevels=...) at base/main.cpp:292 #5 0x00005555555b48bf in scummvm_main(int, char const* const*) (argc=1, argv=0x7fffffffdc18) at
[23:08] <grogbot> base/main.cpp:559 #6 0x00005555555b0ddc in main(int, char**) (argc=1, argv=0x7fffffffdc18) at backends/platform/sdl/posix/posix-main.cpp:45
[23:16] <grogbot> <monyarm> Ok why isn't this working, i've got an array of w*h*4 palette entries I've got an array w*h indexes i the 4 bytes of color data for each index, and add them to an image array i then use the image array, but i tried dumping it, and it's not right
[23:17] --> _sev joined #scummvm.
[23:17] <-- _sev left irc: Changing host
[23:17] --> _sev joined #scummvm.
[23:17] #scummvm: mode change '+o _sev' by ChanServ!ChanServ@services.
[23:20] <-- _sev left irc: Client Quit
[23:21] --> _sev joined #scummvm.
[23:21] <-- _sev left irc: Changing host
[23:21] --> _sev joined #scummvm.
[23:21] #scummvm: mode change '+o _sev' by ChanServ!ChanServ@services.
[23:22] <grogbot> <monyarm> Ok, what the hell, I dumped the image data, and imported it in gimp, it's the correct image, I try giving it to my surface, i get a box, with a strip of color
[23:24] <Lightkey> You need to *putsonsunglasses* think outside the box. Yeeeah!
[23:24] <grogbot> <monyarm> I want to slap you for that
[23:25] <grogbot> <SupSuper> i'd suggest breaking the problem down. make a surface of just all white or all black pixels, see if that shows up correctly, and work your way up
[23:28] <grogbot> <monyarm> all black shows up correctly, the issue seems to be when copying my surface
[23:31] <grogbot> <monyarm> And now without changing anything the behavior changed
[23:36] <-- omgpizzaguy left irc: Read error: Connection reset by peer
[23:36] --> omgpizzaguy joined #scummvm.
[23:42] <-- vliaskov left irc: Remote host closed the connection
[23:44] <grogbot> <monyarm> Could it be the alpha channel that's screwing things up?
[23:52] <-- gus left irc: Quit: No Ping reply in 180 seconds.
[23:53] --> gus joined #scummvm.
[00:00] --- Tue May 12 2020