IRC logs for #opendune on OFTC at 2011-04-21
            
02:10:21 *** glx has quit IRC
12:35:34 *** glx has joined #openDune
12:35:34 *** ChanServ sets mode: +o glx
12:35:55 <glx> hello
16:07:35 *** Alberth has joined #openDune
18:40:29 <Alberth> hmm, y*320 more expensive than accessing a table? :)
18:41:18 * SmatZ wonders about context :)
18:45:13 * Alberth satisfies SmatZ curiosity :) http://paste.openttdcoop.org/show/161/
18:45:26 <SmatZ> :)
18:45:56 <Alberth> emu_get_memory16(emu_cs, emu_bx, 0x17D); is a table of 200 entries of idx*320 :)
18:46:19 <SmatZ> interesting :)
18:47:27 <Alberth> emu_rep_movsw() at line 96 is still a mystery
18:47:47 <SmatZ> those old CPUs had RAM running and the same frequency as CPU
18:48:02 <SmatZ> so the (relative) memory penalty was much lower than nowadays
18:48:53 <Alberth> those were the days, a 6502 at 2!! MHz :)
18:48:56 <SmatZ> :-)
18:49:58 <SmatZ> the counter (number of words moved) seems to be passed as a parameter
18:51:02 <SmatZ> is it some routine responsible for scrolling the viewport?
18:51:41 <Alberth> the routine above here got triggered while the mouse hit the edge of a button iirc
18:52:02 <SmatZ> hum
18:52:10 <Alberth> so perhaps some drawing grey menu surface?
18:53:56 <Alberth> line 83-87 is also interesting, I was thinking some double buffering routine
18:54:55 <Alberth> ie why else carefully subtract 199 ?
18:56:25 <SmatZ> emu_push(0x074A); emu_Unknown_22A6_0E22();
18:56:28 <SmatZ> what are those?
18:56:30 <SmatZ> well
18:56:40 <SmatZ> parameters are x,y source, x,y dest
18:56:52 <SmatZ> where x is in multiplies of 8
18:57:17 <SmatZ> so it might be some location of on-screen pixel, with granularity 8
19:04:36 * SmatZ adds some printf's
19:07:33 <SmatZ> well, it's used when drawing
19:08:26 <SmatZ> indeed
19:08:31 <SmatZ> it might be double buffering
19:08:46 <SmatZ> something like "move dirty blocks from temporary buffer to screen"
19:09:44 <SmatZ> hmm
19:09:51 <Alberth> http://paste.openttdcoop.org/show/162/
19:13:18 <SmatZ> 32 136 32 136 8 64 2 0
19:13:32 <SmatZ> first two and second two parameters are often (if not always) the same
19:13:39 <SmatZ> 0 0 0 0 40 200 2 0
19:13:46 <SmatZ> looks like invalidating whole screen
19:13:57 <SmatZ> (40 is multiplied by 8 first)
19:15:15 <SmatZ> (well, not multiplied - it's multiplied by 4, but movsw moves 2 bytes, and this seems to be the counter)
19:17:16 <Alberth> oh you print those numbers, I was wondering how you got them :)
19:18:57 <SmatZ> :)
19:19:09 <SmatZ> sorry for not explaining my steps :x
19:19:48 <Alberth> http://devs.openttd.org/~alberth/diffs/f__24d0_000d.patch <-- my submitted patch of the decompiled routine above
19:20:22 <Alberth> which also contains that 0 0 0 0 40 200 2 0 sequence :)
19:20:29 <Alberth> that got me wondering :)
19:21:56 <SmatZ> :-)
19:47:47 <SmatZ> movsw: ds = 4915 si = E9C0 es = A000 di = E9C0
19:48:00 <SmatZ> it's really moving from a buffer to the screen
19:48:17 <Alberth> what is the ds doing?
19:48:38 <Alberth> oh, a segement perhaps
19:48:39 <SmatZ> ds is segment of the buffer in main memory
19:49:07 <glx> ES:DI is cleary the screen :)
19:49:14 <SmatZ> "rep movsw" moves cx*2 bytes from ds:si to es:di
19:49:24 <SmatZ> and si+=cx*2, di+=cx*2
19:49:49 <SmatZ> emu_addw(&emu_si, emu_bx);
19:49:51 <SmatZ> emu_addw(&emu_di, emu_bx);
19:49:55 <SmatZ> adds the rest to 320
19:50:22 <SmatZ> so it moves a rectangle
19:50:30 <Alberth> ie at the start but one line lower :)
19:50:48 <glx> kind of double buffuring
20:01:13 <SmatZ> if (emu_cx > 0xC8) {
20:01:14 <SmatZ> emu_subw(&emu_cx, 0xC7);
20:01:17 <SmatZ> still confuses me
20:04:09 <SmatZ> ok, it says that "if (dest_line+nr_lines > 200) nr_lines -=dest_line+nr_lines-199"
20:05:53 <SmatZ> hm
20:06:43 <Alberth> doesn't help much :)
20:08:28 <SmatZ> well, it caps nr_lines to 199-dest_line
20:08:51 <SmatZ> which looks like off by one
20:09:44 <SmatZ> nr_lines -=dest_line+nr_lines-199 ==> nr_lines = nr_lines - (dest_line+nr_lines-199) ==> nr_lines = 199-dest_line
20:12:45 <SmatZ> (even worse, if dest_line == 199, it will copy 65536 lines :P
20:18:33 <DorpsGek> Bugs: http://bugs.opendune.org/view.php?id=60 :: Bug Created :: Text in radar/refinery/windtrap is shifted
20:19:52 <glx> yeah a bug
20:20:25 <Alberth> I reported it earlier here, but it got lost
20:26:37 <glx> it was not on the tracker ;)
20:30:14 <SmatZ> [22:18:35] <DorpsGek> Bugs: http://bugs.opendune.org/view.php?id=60 :: Bug Created :: Text in radar/refinery/windtrap is shifted <== do you know what revision caused that?
20:31:32 <Alberth> would you expect me to know and not tell you?
20:31:55 <SmatZ> maybe you forgot
20:32:12 <glx> I can guess when it started
20:32:15 <Alberth> I didn't :)
20:32:20 * glx checks the log
20:32:32 * SmatZ bisects...
20:34:53 <glx> around 1308 I'd say
20:35:30 <glx> -Add: C-ified GUI_Widget_ActionPanel_Draw(). Finally, the long function is done ;)
20:35:44 <glx> but it may be one of the previous steps
20:40:41 <SmatZ> http://pastie.org/1820400 huh :)
20:40:58 <SmatZ> I was pressing the uparrow while the dune started and its window opened
20:41:41 <SmatZ> I can't really see what's the problem, so I can't bisect,sorry :x
20:41:45 <glx> hmm 70:78 from 0:0 is weird
20:42:05 <SmatZ> should I open a task?
20:42:26 <glx> I saw that once
20:43:16 <glx> IIRC it's a timing issue
20:51:45 <TrueBrain> is it me, or am I blind? I don't see an issue with image in #60?
20:52:27 <glx> I think things should be centered
20:52:37 <TrueBrain> were they?
20:53:03 <glx> I'm basing on the white line
20:53:22 <TrueBrain> wasn't that alwasy the case?
20:53:40 *** planetmaker has left #openDune
20:53:46 *** planetmaker has joined #openDune
20:53:46 *** ChanServ sets mode: +v planetmaker
20:54:07 <SmatZ> r1200 behaves the same
20:54:36 <TrueBrain> looks identical to original Dune2
20:55:43 * glx starts dosbox
20:55:47 <glx> will be easier
20:55:51 <TrueBrain> I did exactly that :)
20:56:02 <TrueBrain> I don't see the difference .. but that is just me :)
20:56:26 <TrueBrain> owh, Alberth reported it :) Lol :)
20:57:06 <TrueBrain> Alberth: tell me what the bug is, I don't see it :(
20:58:49 * glx likes the music in dosbox
20:59:11 <glx> looks like I decompiled the wrong driver ;)
20:59:13 <TrueBrain> get it to work in OpenDUNE too :D
20:59:23 <SmatZ> :D
20:59:24 <TrueBrain> make them both available! :D
21:02:13 <glx> sound blaster pro it seems
21:02:41 <Alberth> http://devs.openttd.org/~alberth/shifted_text2.png this looks fine to you?
21:03:07 <TrueBrain> it is a total mess, I agree. But it is what dune2 is :)
21:03:43 <DorpsGek> Bugs: http://bugs.opendune.org/view.php?id=60 :: New Status: acknowledged (open)
21:05:20 <Alberth> added the 2nd .png file as well
21:05:30 <TrueBrain> tnx
21:05:34 <TrueBrain> changed it to feature request
21:05:35 <glx> haha setup disallow the config we use
21:05:38 <TrueBrain> can't fix it atm :(
21:05:55 <glx> if MT-32 no digitalized voices
21:05:59 <TrueBrain> tnx Alberth :) Wish I could do more for you now, but I can't :(
21:06:19 <TrueBrain> Alberth: about your patches, please put it in a single location I can find .. I dislike reading my backlogs finding them :D
21:06:43 <Alberth> could you make a 'patches' catregory in the tracker?
21:06:55 <TrueBrain> Xaroth|Work: can we?
21:07:10 <Alberth> I distinctly remember someone saying 'posting here is fine' :p
21:07:23 <TrueBrain> yeah, back when I assumed you would do 1 patch and leave, like most others :p
21:07:28 <TrueBrain> boy, was I wrong :p
21:07:43 <Alberth> but I agree, it doesn't work in this way :)
21:08:11 <TrueBrain> category added
21:08:12 <TrueBrain> I think
21:08:35 <Alberth> indeed, thanks
21:08:47 <Alberth> will try to find my patches tomorrow :)
21:09:10 <TrueBrain> thank you :D
21:09:18 <TrueBrain> they are all over your userspace, I had the idea .. got lost :(
21:10:09 <Alberth> luckily not here, in my 500000+ files :p
21:10:26 <TrueBrain> I am trying to clean that up here :p
21:10:31 <TrueBrain> going nicely .. but aint easy :(
21:10:51 <Alberth> not looking what you delete helps :)
21:11:00 <TrueBrain> :D
21:12:29 <Alberth> for several patches, I actually have patch queues, do you want those as well?
21:12:49 <TrueBrain> hmm ... dunno :p
21:12:58 <Alberth> (not really nicely organized, just my random commits)
21:13:03 <TrueBrain> guess the end result is fine enough
21:13:11 <TrueBrain> most likely the cleanest, or at least I hope :D
21:13:21 <TrueBrain> we could use a code-review system tbh ..
21:13:32 <Alberth> rietveld :)
21:14:22 <TrueBrain> for example
21:14:37 <TrueBrain> all I remember I once installed it ... big fuzz after that
21:15:05 <Xaroth|Work> :o
21:15:17 <TrueBrain> lets forward it to the person who does that best
21:15:20 <Alberth> at work we do such things in branches
21:15:25 <TrueBrain> Xaroth|Work: can you see if rietveld would work for OpenDUNE? :)
21:15:30 <Xaroth|Work> euh, sure
21:15:35 <TrueBrain> Alberth: how do you mean?
21:16:10 <TrueBrain> Xaroth|Work: atm Alberth is giving us too many patches; some kind of tool to directly comment on a patch would be nice :)
21:16:25 <TrueBrain> I always hated it that OpenTTD didn't have that ...
21:16:31 <Xaroth|Work> I'd say bugtraker for a start
21:16:35 <Xaroth|Work> then see what we really need
21:16:35 <TrueBrain> (they don't want it, in my last 3 attempts to deploy it :p)
21:16:37 <Xaroth|Work> and what provides that
21:16:43 <TrueBrain> well, a code review system :D
21:16:55 <TrueBrain> I want to comment on a line: this is wrong, should be ...
21:16:59 <TrueBrain> why did you do this
21:17:01 <TrueBrain> etc
21:17:26 <Alberth> hmm, divmod.org died :(
21:17:50 <TrueBrain> Xaroth|Work: rietveld for example also shows the diff of the patches
21:17:57 <TrueBrain> allowing me to see what the user fixed
21:17:58 <TrueBrain> etc :)
21:18:16 <TrueBrain> it might look ambigious at this stage, but will give us much easyness (and openness) later on :)
21:18:31 <Alberth> anyways, work sequence: make a ticket, make a branch from trunk, fix the problem in trunk, ask for review through the ticket system, if approved, merge with trunk
21:18:53 <Alberth> eg with Trac
21:19:18 <TrueBrain> yeah; I am more looking for something on the other end: quality control
21:19:24 <Alberth> s/fix the problem in trunk/fix the problem in branch/ of course :)
21:20:29 <Alberth> like pull requests with bitbucket & friends
21:20:58 <Alberth> although that is not really review oriented
21:21:01 <TrueBrain> but yeah, Xaroth|Work, if you are bored and want something different to do, please check it out :D
21:27:51 <Alberth> http://twistedmatrix.com/trac/wiki/UltimateQualityDevelopmentSystem but Twisted rescued the page :)
21:29:11 <Alberth> good night :)
21:29:29 <TrueBrain> night Alberth
21:29:43 <SmatZ> good night Alberth
21:29:49 *** Alberth has left #openDune
23:55:29 *** Xaroth has joined #openDune
23:55:29 *** ChanServ sets mode: +o Xaroth