[Back to Index]

[00:20] <-- t0by left irc: Quit: t0by
[00:26] --> Mellified_Man_ joined #scummvm.
[00:39] <-- Mellified_Man left irc: Quit: Bye!
[00:39] <-- Unseen2 left irc: Read error: Connection reset by peer
[00:39] Nick change: Mellified_Man_ -> Mellified_Man
[00:39] --> Unseen2 joined #scummvm.
[00:39] Nick change: Mellified_Man -> Mellified
[00:52] <-- Henke37 left irc: Quit: ERR_SHUTDOWN
[01:05] <-- SylvainTV left irc: Read error: Connection reset by peer
[01:25] --> GitHub190 joined #scummvm.
[01:25] <GitHub190> [scummvm] dreammaster pushed 1 new commit to master: https://git.io/vHA20
[01:25] <GitHub190> scummvm/master eedbb7d Paul Gilbert: TITANIC: Fix single incorrect frame showing when Bellbot leaves
[01:25] GitHub190 (GitHub190@192.30.252.42) left #scummvm.
[01:33] <-- Dominus left irc: Ping timeout: 260 seconds
[01:34] --> Dominus joined #scummvm.
[01:45] <-- dreammaster left irc:
[01:47] <-- Mia left irc: Ping timeout: 240 seconds
[02:30] Nick change: EmeraldM2 -> mataniko
[02:30] Nick change: mataniko -> Mataniko
[03:06] <-- ST left irc: Disconnected by services
[03:06] --> ST1 joined #scummvm.
[04:30] <Simei> Morning!
[04:46] <-- Lightkey left irc: Ping timeout: 240 seconds
[04:59] --> Strangerke joined #scummvm.
[04:59] --> Lightkey joined #scummvm.
[05:47] --> ny00123 joined #scummvm.
[06:13] --> waltervn joined #scummvm.
[06:13] #scummvm: mode change '+o waltervn' by ChanServ!ChanServ@services.
[06:15] <-- Strangerke left irc: Ping timeout: 260 seconds
[06:20] --> rootfather joined #scummvm.
[06:45] <-- LittleToonCat left irc: Remote host closed the connection
[06:57] <TMM> morning all
[07:04] --> Joefish joined #scummvm.
[07:04] #scummvm: mode change '+v Joefish' by ChanServ!ChanServ@services.
[07:25] <-- TMM left irc: Quit: Ex-Chat
[07:40] <-- rootfather left irc: Changing host
[07:40] --> rootfather joined #scummvm.
[07:40] #scummvm: mode change '+o rootfather' by ChanServ!ChanServ@services.
[07:49] --> omer_mor joined #scummvm.
[07:51] --> Strangerke|work joined #scummvm.
[07:51] <Strangerke|work> hi guys
[07:52] <-- omer_mor_ left irc: Ping timeout: 260 seconds
[07:54] --> t0by joined #scummvm.
[07:56] --> exmensa_ joined #scummvm.
[07:59] <-- exmensa left irc: Ping timeout: 260 seconds
[08:15] <-- exmensa_ left irc: Ping timeout: 246 seconds
[08:37] --> Henke37 joined #scummvm.
[08:42] --> TMM joined #scummvm.
[08:42] #scummvm: mode change '+o TMM' by ChanServ!ChanServ@services.
[08:59] <Simei> t0by, _sev: Hi, I'm working on replacing sdl input event. It works in general, but there are several stuffs I don't know how to deal with.
[08:59] <Simei> 1. there is "SDL_GetModState() & KMOD_CTRL == true", both right click and left click treated as right click
[09:00] <Simei> when there is*
[09:00] <Simei> 2. alt+f4 to force quit
[09:00] <Simei> 3. And some key inputs related to full screen: alt+enter to full screen, windows key to leave full screen and alt+f to switch to/from screen mode.
[09:03] <-- ST1 left irc: Quit: Leaving.
[09:10] --> ST joined #scummvm.
[09:10] #scummvm: mode change '+o ST' by ChanServ!ChanServ@services.
[09:16] --> borosky joined #scummvm.
[09:24] --> exmensa joined #scummvm.
[09:41] <t0by> Simei: hey
[09:41] <t0by> How did your projects go?
[09:41] <Simei> hey
[09:42] <-- borosky left irc: Ping timeout: 268 seconds
[09:44] <Simei> Good, I think. And almost finished, that's the good part x)
[09:44] <Simei> Only some cross evaluation reports for others to hand in later.
[09:47] <t0by> Simei: I'm sorry, what's your question there?
[09:47] <t0by> I would *guess* scummvm captures alt+enter itself.
[09:48] <Simei> Something in the input I don't know how to deal with
[09:49] <t0by> Oh, no, it doesn't
[09:50] <Simei> 1. When a button press detected, it does a "SDL_GetModState() & KMOD_CTRL == true" check first, if so, both right click and left click will be treated as right click
[09:50] <Simei> Ah, ok, so what do we usually do to deal with window sizes ?
[09:51] <t0by> A second
[09:51] <t0by> I seem to remember we did some sort of fallthrough
[09:56] <Simei> _sev, t0by: Ok, but although these handles exist in the code, they don't seem to have effects using the original sludge engine under linux, except for alt+f4
[09:56] <t0by> A second, I am finding an example
[09:56] <Simei> Ah, ok, great
[09:56] <t0by> I might be completely wrong too, a second
[09:57] --> borosky joined #scummvm.
[09:57] <wjp> Simei: I hope "SDL_GetModState() & KMOD_CTRL == true" is not literal code?
[09:57] <Simei> No, without == true
[09:58] <wjp> ok, because that is wrong in two ways :-)
[09:59] <wjp> (& has lower precedence than ==)
[09:59] <Simei> wjp, ah, ok, I didn't know that, thanks
[10:02] <t0by> Yes, the engine *seems* to handle Common::EVENT_QUIT by doing some clean up and then letting it fall through.
[10:04] <t0by> Simei: grep Common::EVENT_QUIT
[10:04] <t0by> you should get the idea
[10:06] <t0by> it's defined in events.h
[10:06] <t0by> I have the vague suspicion that fullscreen is handled on a per-engine basis
[10:06] <t0by> let me see if I'm right
[10:07] <Simei> t0by, why Common::EVENT_QUIT ? What are we trying to resolve here ?
[10:08] <Simei> Yes, I think scummvm already has alt+f4 to force quit, so don't mind about this one
[10:08] <t0by> Well, a Common::EVENT_QUIT is raised by the event system when the user wants to quit
[10:09] <t0by> This can be caused by alt+f4 but also something completely different (consier systems that don't have an F4 key at all...)
[10:09] <t0by> The exact way is defined in the various backends
[10:09] <t0by> conside for example backends/events/sdl/
[10:10] <t0by> So you don't handle ALT+F4 directly but handle the event
[10:10] <Simei> Ok, I see.
[10:11] <t0by> I *think* you'll get a Common::EVENT_SCREEN_CHANGED if/when the viewport is resized, e.g. as a consequence of maximizing the window
[10:12] <-- rootfather left irc: Ping timeout: 240 seconds
[10:15] <t0by> um
[10:15] <t0by> You *might* not have to handle it
[10:17] <t0by> That seems to be handled by the graphics backends already.
[10:18] <Simei> Ok, so I'll remove them, thanks!
[10:18] <t0by> well, no no no no
[10:18] <t0by> not "handled by the graphics backends"
[10:18] <t0by> those don't get the events
[10:18] <t0by> I meant that the backend seems to do everything for you
[10:19] <t0by> Simei: I currently have SdlEventSource::handleResizeEvent under my nose
[10:19] <t0by> try to have a look in the and follow the calls
[10:22] <t0by> Anyway, I seems to me no one bothers to tell the engine as the backend does all the required resizing and housekeeping, I think you can simply ignore that.
[10:22] <t0by> Simei: it's more worth of note how Common::EVENT_QUIT is handled
[10:23] <-- borosky left irc: Ping timeout: 260 seconds
[10:25] <t0by> I take back whatever I said about falling through.
[10:26] <Simei> Ok, i see. I will take a look at it. Thanks
[10:27] <t0by> It's a WME-specific thing
[10:27] <t0by> You just poll events and handle them.
[10:30] <t0by> On Common::EVENT_QUIT you can do some engine-specific housekeeping, but I think you can ignore it for the time being.
[10:31] --> ajax16384 joined #scummvm.
[10:31] #scummvm: mode change '+o ajax16384' by ChanServ!ChanServ@services.
[10:32] <Simei> Ok, I see
[10:34] <t0by> Simei: sorry again, nevermind: on Common::EVENT_QUIT you apparently have to take action yourself as to exit the main loop.
[10:34] <t0by> Simei: grep it and see how engines handle it.
[10:35] <t0by> Simei: hugo is especially telling in this respect
[10:36] <Simei> Yes, in sludge it's just set a value from 0 to 1 to exit the loop and all cleanings are done after
[10:36] <t0by> Simei: look at HugoEngine::run()
[10:36] <t0by> it's the clearest example
[10:37] <t0by> I was letting WME-specific details derail me
[10:37] <t0by> Simei: look at run() from Hugo.
[10:38] <t0by> Simei: see how it works?
[10:40] <t0by> Simei: there is also the RTL event, i.e. return to (scummvm) launcher which operates in a similar fashion.
[10:41] <t0by> IIRC it's triggered by somethingsomething F6
[10:42] <Simei> What is RTL event ?
[10:42] <t0by> Return to launcher. When playing a game you can press something-something-F6 (ALT, is it?) and be brought back to the ScummVM launcher instead of closing ScummVM altogether
[10:43] <t0by> from the engine's point of view it's almost the same
[10:43] <Simei> Ok, I see
[10:44] <t0by> (I say "almost" because I think you might want to avoid leaking, which is not a cocnern when we are shutting down altogether)
[10:44] <t0by> ah, ALT=F5
[10:44] <t0by> *ALT+F5
[10:45] <Simei> Ok
[10:46] <t0by> For the time being assume that either one means you have to pack up and quit the game loop.
[10:46] <t0by> Disregard fullscreen, which is already handled (when there are windows at all) for you.
[10:46] <Simei> Yes that's what I did
[10:47] <t0by> Don't listen for the literal key combinations.
[10:49] <Simei> Ok
[11:30] --> jamm joined #scummvm.
[12:07] <-- jamm left irc: Ping timeout: 240 seconds
[12:35] --> Mia joined #scummvm.
[12:35] <-- Mia left irc: Changing host
[12:35] --> Mia joined #scummvm.
[14:04] --> jamm joined #scummvm.
[14:17] --> Littleboy joined #scummvm.
[14:17] #scummvm: mode change '+o Littleboy' by ChanServ!ChanServ@services.
[15:00] --> LittleToonCat joined #scummvm.
[15:02] <-- TMM left irc: Quit: Ex-Chat
[15:15] <-- ajax16384 left irc: Read error: Connection reset by peer
[15:39] <snover> so, the DPCM16 decompression in SSCI does not clamp values to the range [-32768, 32767] but instead just calls add/sub on the DX register, so if there is an overflow it ends up wrapping. This wrapping behaviour seems to be necessary for e.g. 5280.VMD in GK2 to prevent a popping noise, but I have not found any other samples where this is necessary.
[15:39] <snover> Nevertheless, would the correct way to perform the wrapping (without UB) just be `if (sample > 32767) sample -= 65536; else if (sample < -32768) sample += 65536;` (where `sample` is int32 here), or is there some better way to do this that my brain just cant think of?
[15:44] <Henke37> the easy way would be to replicate the bug by choosing a datatype that already overflows correctly
[15:45] <Henke37> but that's at best IB
[16:01] --> Farmboy0 joined #scummvm.
[16:01] <-- Farmboy0 left irc: Changing host
[16:01] --> Farmboy0 joined #scummvm.
[16:03] --> WooShell joined #scummvm.
[16:11] <WooShell> meow =^.^=
[16:11] <Simei> Hi
[16:13] <-- Stormkeeper left irc: Quit: KVIrc 4.9.2 Aria http://www.kvirc.net/
[16:15] <Simei> t0by, _sev: Does anyone know how can I get an image displayed with 0.5 opacity? I tried " tmp.blit(backdropSurface, x, y, Graphics::FLIP_NONE, nullptr, TS_ARGB(255 >> 1, 255, 255, 255)); ". But it only gives something a little yellower. Did I mistake here?
[16:15] <Simei> https://usercontent.irccloud-cdn.com/file/8yUljvw3/image.png
[16:17] <Simei> What I expect is like this :
[16:17] <Simei> https://usercontent.irccloud-cdn.com/file/IWZJJxua/image.png
[16:20] <wjp> Do you get alpha if you change the order of the arguments to TS_ARGB?
[16:20] <Simei> Ok, I'll have a try
[16:21] <wjp> (For testing only, since you do have them right; but maybe this is the wrong function to use in this context. I can't look properly now since I'm on a train)
[16:21] <-- enthusi left irc: Ping timeout: 240 seconds
[16:23] <-- Strangerke|work left irc:
[16:23] <t0by> Simei: why do we care about transparency at this point?
[16:23] <Simei> wjp, yes I get 0.5 opacity by using TS_ARGB(255, 255 >> 1, 255, 255)
[16:23] <Simei> it's quite strange
[16:24] <t0by> Simei: link to code as usual :)
[16:24] <wjp> Hrm
[16:24] <Simei> t0by, for all mixOverlay in sludge they were originally set to 0.5 opacity in hard value in the code
[16:24] <t0by> Yes, but... why do we care?
[16:25] <t0by> as in, why is it instrumental in getting input to work?
[16:25] <Simei> t0by, I get the input work now, it's a bug that I meet when I give a first test
[16:26] <t0by> I would suggest we focus on one thing at a time.
[16:26] <t0by> Anyway, please share your code, as usual :)
[16:26] <wjp> (Side note: if drawing at 0.5 alpha is a common thing, it might be worth optimizing low-level code specifically for this, at some point in the future)
[16:30] <wjp> Simei: what was your pixel format again?
[16:30] <Simei> _sev, t0by, I guess I'm done with the input now as I get the cursor work ? Here is the code : https://github.com/yinsimei/scummvm/tree/newWIP1-1
[16:32] <Simei> wjp, it's Graphics::PixelFormat(4, 8, 8, 8, 8, 24, 16, 8, 0)
[16:32] <t0by> Simei: oh really, everything works? It's playable? Super fantastic!
[16:32] <t0by> Simei: where is the relevant lines?
[16:32] <-- jamm left irc: Ping timeout: 268 seconds
[16:33] --> omer_mor_ joined #scummvm.
[16:34] <wjp> Simei: hrm, so not immediately clear to me why this TS_ARGB is behaving oddly. Feel free to remind me later if it's still an issue later (and I'm behind a pc again)
[16:35] <Simei> t0by, wjp, that's the relevant line: https://github.com/yinsimei/scummvm/blob/newWIP1-1/engines/sludge/backdrop.cpp#L962
[16:35] <-- omer_mor left irc: Ping timeout: 260 seconds
[16:35] <Simei> wjp, ok, thanks, I will ask again then
[16:37] <Simei> t0by, _sev: that's the commit about input : https://github.com/yinsimei/scummvm/commit/22c42cd503cf353186ed486d96c9a92a661e1893#diff-8e8636e304b6a0e0e2aa61c8db0e0731L125
[16:40] <t0by> hum
[16:48] <t0by> Simei: have you tried chasing that call down with a debugger?
[16:48] <t0by> At a glance I don't see any obvious reason why it should behave like that
[16:51] <t0by> uuuh
[16:52] <t0by> You *might* have hit upon a TransparentSurface bug
[16:53] <t0by> currently it's only used in WME (from where it came), fullpipe and a few other places
[16:53] <Simei> Not yet. What's the debugger again ? dbg scummvm ?
[16:54] <t0by> You can use gdb, sure, although I would advise using a GUI debugger - mostly for ease of discovery
[16:54] --> ajax16384 joined #scummvm.
[16:54] #scummvm: mode change '+o ajax16384' by ChanServ!ChanServ@services.
[16:55] <t0by> There's plenty of gdb tutorials around, and quite possibly a few GUIs - including emacs gud
[16:56] <t0by> Simei: you would set a breakpoint on that line and step *into* (as opposed to "step over") function calls
[16:56] <t0by> keeping an eye on the values being passed around
[16:56] <t0by> until, hopefully, at some point you see something weird
[16:56] <Simei> Yes, that's true. I'll search about it later.
[16:57] <Simei> Sorry, I should leave now. I'll be back later tonight. :)
[16:57] <t0by> at which point you go "aaaah, it doesn't work because so and so"
[16:57] <t0by> I find that works for me when inspection is of no help.
[16:57] <t0by> Simei: bye!
[16:58] <Simei> Ok, I note it. Sounds quite useful. :)
[16:58] <t0by> Curiosly, fullpipe does int alphac = TS_ARGB(0xff, alpha, 0xff, 0xff);
[17:00] <t0by> hum
[17:00] <t0by> #define TS_ARGB(A,R,G,B) (((R) << 24) | ((G) << 16) | ((B) << 8) | (A))
[17:00] <-- Harekiet left irc: Read error: Connection reset by peer
[17:01] <t0by> TransparentSurface::PixelFormat getSupportedPixelFormat() { return PixelFormat(4, 8, 8, 8, 8, 24, 16, 8, 0); }
[17:01] <t0by> I feel really stupid right now.
[17:05] --> omer_mor joined #scummvm.
[17:05] --> enthusi joined #scummvm.
[17:07] <-- omer_mor_ left irc: Ping timeout: 246 seconds
[17:09] --> exmensa_ joined #scummvm.
[17:11] <-- exmensa left irc: Ping timeout: 240 seconds
[17:16] --> Harekiet joined #scummvm.
[17:19] --> exmensa joined #scummvm.
[17:20] --> TMM joined #scummvm.
[17:20] #scummvm: mode change '+o TMM' by ChanServ!ChanServ@services.
[17:20] <t0by> mh
[17:20] <-- exmensa_ left irc: Ping timeout: 255 seconds
[17:20] <t0by> _sev: that's weird, do you remember why you wrote int alphac = TS_ARGB(0xff, alpha, 0xff, 0xff) ?
[17:21] <t0by> that's fullpipe/gfx.cpp L852
[17:22] <t0by> https://github.com/scummvm/scummvm/blob/master/engines/fullpipe/gfx.cpp#L852
[17:24] --> omer_mor_ joined #scummvm.
[17:26] <-- omer_mor left irc: Ping timeout: 260 seconds
[17:29] --> exmensa_ joined #scummvm.
[17:29] --> borosky joined #scummvm.
[17:30] <-- exmensa left irc: Ping timeout: 255 seconds
[17:33] <-- exmensa_ left irc: Ping timeout: 246 seconds
[17:46] --> _sev_ joined #scummvm.
[17:46] #scummvm: mode change '+o _sev_' by ChanServ!ChanServ@services.
[17:47] <-- _sev left irc: Ping timeout: 255 seconds
[17:48] --> Strangerke joined #scummvm.
[17:50] #scummvm: mode change '+o Strangerke' by ChanServ!ChanServ@services.
[17:51] <Strangerke> re guys
[18:05] <-- enthusi left irc: Ping timeout: 240 seconds
[18:06] <-- Littleboy left irc: Read error: Connection reset by peer
[18:17] <criezy> Hi Strangerke, hi guys
[18:27] <Joefish> hey :)
[18:28] --> jamm joined #scummvm.
[18:28] <-- jamm left irc: Changing host
[18:28] --> jamm joined #scummvm.
[18:36] --> SylvainTV joined #scummvm.
[18:36] #scummvm: mode change '+o SylvainTV' by ChanServ!ChanServ@services.
[18:39] --> enthusi joined #scummvm.
[18:45] <-- borosky left irc: Ping timeout: 246 seconds
[18:47] --> borosky joined #scummvm.
[18:55] kszys[m] <-- (kszysmatri@gateway/shell/matrix.org/x-wjmonrnoaoxyrsml) left irc: Ping timeout: 245 seconds
[18:56] --> Strangerke_ joined #scummvm.
[18:59] lateral[m] <-- (lateralmat@gateway/shell/matrix.org/x-vzblfcbtibheqdmx) left irc: Ping timeout: 246 seconds
[18:59] <-- Strangerke left irc: Ping timeout: 260 seconds
[18:59] Nick change: Strangerke_ -> Strangerke
[18:59] FleetAdmiral[m] <-- (fleetadmir@gateway/shell/matrix.org/x-mzmbmepblzjorecr) left irc: Ping timeout: 264 seconds
[18:59] Coldwine[m] <-- (coldwinema@gateway/shell/matrix.org/x-xbzyyqgrihyprmpc) left irc: Ping timeout: 255 seconds
[19:18] <-- enthusi left irc: Ping timeout: 268 seconds
[19:22] <-- jamm left irc: Ping timeout: 268 seconds
[19:43] <-- ny00123 left irc: Quit: Leaving
[19:55] <-- borosky left irc: Ping timeout: 240 seconds
[19:56] --> borosky joined #scummvm.
[19:57] --> enthusi joined #scummvm.
[20:37] <-- borosky left irc: Ping timeout: 246 seconds
[20:40] <-- ajax16384 left irc: Read error: Connection reset by peer
[20:48] <-- t0by left irc: Quit: t0by
[20:48] --> borosky joined #scummvm.
[21:10] --> exmensa joined #scummvm.
[21:33] lateral[m] --> (lateralmat@gateway/shell/matrix.org/x-sasuhcolhcuyltjz) joined #scummvm.
[21:43] --> dreammaster joined #scummvm.
[21:43] #scummvm: mode change '+o dreammaster' by ChanServ!ChanServ@services.
[21:50] FleetAdmiral[m] --> (fleetadmir@gateway/shell/matrix.org/x-hgsmeskeufqbwdbn) joined #scummvm.
[21:50] kszys[m] --> (kszysmatri@gateway/shell/matrix.org/x-aumzvlwwruwenhhe) joined #scummvm.
[21:51] Coldwine[m] --> (coldwinema@gateway/shell/matrix.org/x-nqpcqigfztwisfyj) joined #scummvm.
[21:51] --> omer_mor joined #scummvm.
[21:53] <-- omer_mor_ left irc: Ping timeout: 240 seconds
[21:57] <-- Strangerke left irc: Ping timeout: 246 seconds
[22:53] --> Strangerke joined #scummvm.
[23:03] <-- Strangerke left irc: Ping timeout: 268 seconds
[23:07] <-- Joefish left irc: Ping timeout: 240 seconds
[23:16] --> ST1 joined #scummvm.
[23:16] <-- ST left irc: Disconnected by services
[23:20] --> antlarr2 joined #scummvm.
[23:21] --> wjp_ joined #scummvm.
[23:21] --> madmoose_ joined #scummvm.
[23:21] --> pigeon_ joined #scummvm.
[23:26] antlarr (~quassel@85.137.244.189.dyn.user.ono.com) got netsplit.
[23:26] pigeon (~pigeon@eth5284.nsw.adsl.internode.on.net) got netsplit.
[23:26] madmoose (~Hat@chef.nerp.net) got netsplit.
[23:26] wjp (~wjp@hmm.wantstofly.org) got netsplit.
[23:31] --> Strangerke joined #scummvm.
[23:32] #scummvm: mode change '+o Strangerke' by ChanServ!ChanServ@services.
[23:37] madmoose (~Hat@chef.nerp.net) got lost in the net-split.
[23:37] wjp (~wjp@hmm.wantstofly.org) got lost in the net-split.
[23:37] pigeon (~pigeon@eth5284.nsw.adsl.internode.on.net) got lost in the net-split.
[23:37] antlarr (~quassel@85.137.244.189.dyn.user.ono.com) got lost in the net-split.
[23:39] Nick change: wjp_ -> wjp
[23:52] <-- waltervn left irc: Quit: Leaving
[00:00] --- Sat Jun 17 2017