#gemrb@irc.freenode.net logs for 27 Jun 2010 (GMT)

Archive Today Yesterday Tomorrow
GemRB homepage

[00:56:25] <-- raevol has left IRC (Quit: Leaving.)
[00:58:23] --> raevol has joined #GemRb
[01:12:35] <-- raevol has left IRC (Quit: Leaving.)
[01:14:11] --> raevol has joined #GemRb
[05:44:02] --> Gekz has joined #GemRb
[06:38:00] --> lynxlynxlynx has joined #GemRb
[06:38:00] --- ChanServ gives channel operator status to lynxlynxlynx
[07:35:36] --> cubathy has joined #GemRb
[07:43:48] <-- Gekz has left IRC (Read error: Connection reset by peer)
[07:50:25] --> Gekz has joined #GemRb
[08:02:10] <-- Gekz has left IRC (Ping timeout: 260 seconds)
[08:06:57] --> Gekz has joined #GemRb
[08:11:14] <-- cubathy has left IRC (Ping timeout: 265 seconds)
[08:24:31] --> cubathy has joined #GemRb
[08:28:17] --> Avenger has joined #GemRb
[08:28:20] --- ChanServ gives channel operator status to Avenger
[08:28:23] <Avenger> hi
[08:28:47] <lynxlynxlynx> oj
[08:38:05] <Avenger> haha, i think i found out what a chunk of code does in bg2. It always boggled me what it is doing. Now i think it handles locking objects for multi player. No wonder i couldn't figure it out :)
[08:38:13] <fuzzie> cool
[08:38:32] <fuzzie> are you still working without IDA Pro? :)
[08:38:33] <Avenger> at least it is good to know which parts are protected for critical section stuff
[08:38:36] <Avenger> yes
[08:39:04] <Avenger> i'm not even in a debugger now, just reading the disassembly under linux :P
[08:39:27] <Avenger> i got heaps of listings, just doing grep on them
[08:39:36] <fuzzie> even IDA's listings are easier to read ;p
[08:39:59] <Avenger> i'm talking about this call: 00676570
[08:40:50] <Avenger> as far as i see, it is for locking the player object for multiplayer
[08:42:57] <Avenger> hmm, maybe not the player object, but the whole game object
[08:43:42] <fuzzie> do you know why they would do that?
[08:44:10] <Avenger> it is just weird it is inside a loop of i=0;i<PartySize... in incrementchapter, that still puzzles me
[08:44:56] <fuzzie> making sure nothing happens in between that and TextScreen?
[08:45:24] <fuzzie> since maybe some of the other players are on other computers
[08:45:45] <Avenger> well, it protects a call to 0057A055, i still didn't find that out
[08:46:14] <fuzzie> sure is used in a lot of places
[08:47:04] <Avenger> i just see, it checks status of 00676570, if it is not returning success, then it keeps trying with the same actor, then finally it calls that protected function
[08:47:33] <fuzzie> oh, wow, it's used everywhere
[08:47:44] <Avenger> yes, it is used everywhere, that's what boggled me :)
[08:48:11] <Avenger> i was wondering wtf is common with all that stuff
[08:48:25] <fuzzie> lookup_gameobj would have been my guess too
[08:49:14] <Avenger> lookup is not entirely correct, i think the object exists but could be in a locked state
[08:49:59] <Avenger> it wouldn't be inside a loop of PartySize otherwise :)
[08:50:54] <Avenger> also, it can return a lot of values, but not pointer, its common return values are 0,4,5 as far as i see
[09:08:17] <-- raevol has left IRC (Quit: Leaving.)
[10:23:01] <-- Gekz has left IRC (Read error: Connection reset by peer)
[10:24:39] --> Gekz has joined #GemRb
[10:32:44] <lynxlynxlynx> figured out anything new by now?
[12:06:49] <Avenger> nah, i dozed away after lunch :)
[12:09:21] <-- Avenger has left IRC (Quit: bye!)
[12:26:20] <-- Gekz has left IRC (Read error: Connection reset by peer)
[12:26:39] --> Gekz has joined #GemRb
[12:52:48] <-- Gekz has left IRC (Changing host)
[12:52:48] --> Gekz has joined #GemRb
[13:32:35] <-- Gekz has left IRC (Read error: Connection reset by peer)
[13:32:35] --> Gekz_ has joined #GemRb
[15:10:53] <-- cubathy has left IRC (Ping timeout: 240 seconds)
[16:04:54] --> cubathy has joined #GemRb
[16:14:07] --> Avenger has joined #GemRb
[16:14:11] --- ChanServ gives channel operator status to Avenger
[16:15:26] <Avenger> hey, anyone got the tools, knowledge and time to convert png to bmp? Someone made an animation for gemrb
[16:15:50] <Avenger> --> http://forums.gibberlings3.net/index.php?showtopic=20190
[16:18:57] <wjp> any particular requirements for the bmp?
[16:19:23] <wjp> this is the one-liner that uses bash and imagemagick's convert without any special options: for i in *.png */*.png; do convert $i ${i/png/bmp}; done
[16:21:26] <lynxlynxlynx> cool, /visits
[16:22:00] <Gekz_> Avenger: I made a tool just for this once!
[16:22:05] <Gekz_> ... and now I dont have it any further
[16:22:22] <Gekz_> it literally redrew images xD
[16:23:41] <Gekz_> and Avenger, you don't use linux very often do you >_>
[16:25:48] <lynxlynxlynx> something between prince of persia and an ogre
[16:26:06] <Gekz_> lol
[16:27:53] <Avenger> i wrote what to do with the bmp's then :)
[16:28:23] <Avenger> --> http://forums.gibberlings3.net/index.php?showtopic=20189
[16:28:54] <Avenger> basically the bmp sequences should be easily importable into a bam via dltcep
[17:04:23] <Avenger> now i see how the ignore walls flag is passed to the IE equivalent of GetActorsInRadius...
[17:41:57] <-- cubathy has left IRC (Ping timeout: 265 seconds)
[17:42:47] --> cubathy has joined #GemRb
[17:45:04] <-- Avenger has left IRC (Quit: ChatZilla 0.9.86 [Firefox 3.6.3/20100401080539])
[17:48:36] <-- cubathy has left IRC (Ping timeout: 248 seconds)
[17:54:45] --> cubathy has joined #GemRb
[17:59:02] --> Avenger has joined #GemRb
[17:59:05] --- ChanServ gives channel operator status to Avenger
[17:59:16] <lynxlynxlynx> wb
[17:59:44] <Avenger> fuzzie or wjp, can you fix the movie player to clear the subtitle area?
[18:00:04] <lynxlynxlynx> heh, this was talked about just a few days ago
[18:00:12] <Avenger> oh, and what was said
[18:00:16] <fuzzie> you can just copy the lock/memset/unlock from init, if you want
[18:00:48] <lynxlynxlynx> don't give more tasks to fuzzie, she'll explode
[18:00:52] <fuzzie> it's a bit slow, but that can be fixed later
[18:01:11] <Avenger> yes, i didn't want to clear the whole area
[18:02:18] <lynxlynxlynx> even so, wouldn't it be needed only when the subtitle changes?
[18:03:07] <Avenger> yes
[18:03:11] <Avenger> actually, you are right
[18:03:24] <Avenger> that shouldn't be too expensive
[18:06:44] <fuzzie> someone should probably remove the SDL_DOUBLEBUF comment from the flags line in SDLVideo::Init
[18:06:59] <fuzzie> since balrog seems to have commented it out in r1533 and everything would break if it were added back
[18:10:18] <Avenger> ok, since i'm waist deep into the sdl driver, i can do it now
[18:11:15] <Avenger> fyi: the mve player leaks
[18:11:35] <Avenger> ==16761== by 0x770A4E7: MVEPlayer::segment_video_init(unsigned char) (mve_player.cpp:306)
[18:12:19] <Avenger> maybe it is harmless, i didn't check if it grows if i play a movie repeatedly
[18:12:20] <fuzzie> odd
[18:12:31] <fuzzie> some specific mve file?
[18:13:06] <Avenger> some of the intro movies of bg2
[18:13:20] <Avenger> including the long movie with the subtitles
[18:14:14] <fuzzie> i didn't think to check if there were multiple video init blocks in any of the files, which i guess would be how that happened
[18:15:13] <Avenger> it is not a big chunk: ==5330== 2,440 (40 direct, 2,400 indirect) bytes in 1 blocks are definitely lost in loss record
[18:15:47] <Avenger> so this happens with multiple init blocks?
[18:17:18] <Avenger> ok, actually if i play the movie till the end, i get 6 blocks, 240 direct, and much more indirect
[18:17:33] <Avenger> so it got several inits inside?
[18:18:17] <fuzzie> well, i added a printf, but then cmake wants to rebuild everything again
[18:18:40] <fuzzie> so maybe if you add a printf you can get there faster :)
[18:19:17] <Avenger> i want to fix the subtitlearea first, this is just a sidetrack ;)
[18:20:09] <Avenger> whee! it works
[18:21:09] <fuzzie> ok, yes, there are multiple inits
[18:21:10] <fuzzie> sigh
[18:22:00] <Avenger> as usual i cannot commit a change in a single piece ...
[18:22:33] <fuzzie> you're doing 'git pull --rebase'?
[18:22:59] <fuzzie> oh, you were surely the last to commit anyway, so i guess i misunderstand
[18:23:00] <Avenger> no i don't even know what is --rebase
[18:23:01] <CIA-23> GemRB: 03avenger_teambg * r149b6e454377 10gemrb/gemrb/plugins/PROImporter/PROImporter.cpp: small cleanup in the projectile reader
[18:23:25] <Avenger> i missed to commit the header
[18:23:43] <Avenger> hmm, this commit is a previous one...
[18:24:18] <Avenger> cia seems to be lagging behind
[18:24:57] <Avenger> i guess you can trivially fix the backbuf leak?
[18:25:00] <fuzzie> yes
[18:26:30] <Avenger> same is with segment_audio_init
[18:26:49] <fuzzie> yes, got that one too
[18:26:55] <fuzzie> just waiting for valgrind
[18:26:59] <CIA-23> GemRB: 03avenger_teambg * r95f97b077448 10gemrb/gemrb/plugins/SDLVideo/SDLVideo.cpp: clear the subtitle area before use so text is not crowded
[18:27:13] <CIA-23> GemRB: 03avenger_teambg * r75cefabc0f50 10gemrb/gemrb/plugins/SDLVideo/SDLVideo.h: meh...
[18:28:14] <Avenger> i'll be a bit afk
[18:29:02] <lynxlynxlynx> nice
[18:31:27] <CIA-23> GemRB: 03fuzzie * r0ac991599ee8 10gemrb/gemrb/plugins/MVEPlayer/mve_player.cpp: try fixing memory leaks in MVEPlayer
[18:33:40] <lynxlynxlynx> looks like too much of the video gets chopped off for the subtitle reset
[18:33:56] <lynxlynxlynx> ~100px here
[18:35:00] <fuzzie> yes, that is not quite the right place to do it
[18:35:25] <lynxlynxlynx> h/4 huh
[18:35:54] <fuzzie> you can't fix it by fiddling with the rect, because then it'll just break at some different resolution
[18:36:00] <fuzzie> i mean, if i'm understanding the problem right
[18:36:25] <lynxlynxlynx> yeah, it should use the actual size plus some minimal border
[18:39:19] <fuzzie> i guess i don't understand the problem right, because it's ok here for the most obvious case (subtitles displayed over video)
[18:44:38] <Avenger> huh, your video is chopped?
[18:44:50] <Avenger> it was perfect for me...
[18:46:16] <Avenger> maybe a different tactic should be used then, like getting the needed size from Font
[18:47:57] <Avenger> it draws stuff on the bottom of the rectangle, so it is probably possible to ask for the count of rows or the height of the text
[18:48:18] <lynxlynxlynx> bg2 intro: first scene is ok, since it is mostly black anyway
[18:48:31] <lynxlynxlynx> later i can see it getting chopped
[18:48:33] <fuzzie> Avenger: you're drawing the black rect after the video, it seems
[18:48:46] <fuzzie> so from the code, it seems like it shouldn't work, but it's actually fine for me
[18:48:51] <lynxlynxlynx> it is restored only before the subtitle change and for a minute amount of time
[18:49:14] <lynxlynxlynx> 800x600
[18:49:39] <fuzzie> and it seems also that the rectangle is always going to be drawn because the code isn't checking for subtitle change..
[18:49:41] <Avenger> ok, i think this should be a parameter in Print
[18:50:17] <fuzzie> Print is called every frame, because sometimes the subtitles have to be on top of the video, but you don't need to clear the rect every frame
[18:51:37] <Avenger> you will pass the clear command only then
[18:51:39] <fuzzie> and i guess it won't ever work properly if you do
[18:52:30] <Avenger> the text needs a different surface?
[18:53:11] <fuzzie> you've got to clear the rectangle first (if needed), then draw the video, then draw the subtitle, i think?
[18:53:34] <Avenger> hmm
[18:54:33] <-- cubathy has left IRC (Ping timeout: 260 seconds)
[18:55:08] <Avenger> ok, i will try to do that
[18:58:10] <Avenger> works
[18:59:50] <CIA-23> GemRB: 03avenger_teambg * ref779dc75f06 10gemrb/gemrb/plugins/SDLVideo/SDLVideo.cpp: fixed clearing of subtitles (clear the region before rendering movie)
[18:59:55] <CIA-23> GemRB: 03avenger_teambg * ra916bcb0e5c2 10gemrb/gemrb/plugins/MVEPlayer/mve_player.cpp: Merge branch 'master' of ssh://avenger_teambg@gemrb.git.sourceforge.net/gitroot/gemrb/gemrb
[19:04:31] <lynxlynxlynx> perfect
[19:04:38] <Avenger> :)
[19:05:52] <lynxlynxlynx> question
[19:06:04] <lynxlynxlynx> cone of cold doesn't work in how
[19:06:30] <lynxlynxlynx> the first thing i tried was copying the bg2 projectile over, but it didn't help
[19:07:07] <Avenger> what about the bg1 cone of cold
[19:07:11] <Avenger> does it work in bg1?
[19:07:49] <Avenger> the bg2 version uses different resources for sure
[19:08:31] <lynxlynxlynx> it's in our override, so i thought it didn't matter
[19:08:43] <Avenger> another leak is in SaveGameIterator
[19:08:46] <lynxlynxlynx> haven't tried bg1
[19:08:52] <Avenger> ==4321== by 0x513A4A9: SaveGameIterator::RescanSaveGames() (SaveGameIterator.cpp:279)
[19:09:44] <Avenger> meh, i wont touch this, ugly std:list
[19:09:53] <Avenger> or set
[19:11:30] <Avenger> hmm, how can you free those strings inside the set
[19:14:51] <Avenger> i don't quite see why he did strdup there
[19:15:57] --> pupnik has joined #GemRb
[19:16:35] <pupnik> TRÖÖÖÖT! :)
[19:18:56] <Avenger> hmm, happy for Germany vs. England?
[19:19:26] <fuzzie> the transform there is pretty ugly
[19:20:08] <fuzzie> but that's not the place to free the strings
[19:20:28] <fuzzie> oh, maybe it is, i hadn't seen the strncpy
[19:21:25] <Avenger> i simply removed the strdup
[19:21:35] <CIA-23> GemRB: 03avenger_teambg * r1fd85b61ae4a 10gemrb/gemrb/core/SaveGameIterator.cpp: fixed a leak (strdup is not needed there ?)
[19:21:38] <fuzzie> that will crash, no?
[19:22:29] <Avenger> didn't harm valgrind
[19:22:35] <Avenger> and the text was fine
[19:22:59] <Avenger> even after scrolling and getting the list more times
[19:23:25] <fuzzie> that is just luck, no?
[19:23:34] <Avenger> it was an empirical fix i admit :D
[19:23:41] <fuzzie> yeah
[19:23:47] <fuzzie> well
[19:23:54] <fuzzie> it's annoying because now i can't commit my fix :)
[19:24:00] <fuzzie> and it crashes for me, now
[19:24:05] <Avenger> huh
[19:24:24] <Avenger> so i was just 'lucky' ?
[19:28:14] <Avenger> well, something is fishy here, i admit
[19:28:15] --> fuzzie_ has joined #GemRb
[19:28:17] <fuzzie_> try http://fuzzie.org/nfs/gemrb/save_game_iterator.txt
[19:28:58] <Avenger> i get this: ==15851== 3,408,976 bytes in 166 blocks are still reachable in loss record 94 of 94==15851== by 0x5139162: SaveGameIterator::GetSaveGame(char const*) (SaveGameIterator.cpp:325 for
[19:29:06] <fuzzie_> the char* there seems to be come from readdir(), so i guess it is the luck of the draw if it worked for you
[19:29:15] <Avenger> :(
[19:29:18] <fuzzie_> you get that with my patch?
[19:29:21] <Avenger> no
[19:29:24] <Avenger> my code
[19:30:43] <fuzzie_> hm
[19:31:22] <Avenger> *i is the string that was dupped?
[19:32:02] <fuzzie_> yes
[19:32:21] <Avenger> the still reachable stuff is because save_slots isn't cleared on ~, i guess
[19:32:37] <fuzzie_> it should get automatically cleared
[19:35:33] <fuzzie> hm
[19:36:27] <Avenger> i get 11M of still reachable stuff :D
[19:36:32] <Avenger> all in the savegames
[19:36:41] <Avenger> this is horrible O_o
[19:38:23] <fuzzie> i assume we're leaking a python reference
[19:38:52] <Avenger> hmm
[19:39:06] <CIA-23> GemRB: 03avenger_teambg * r351fe432cc4f 10gemrb/gemrb/core/SaveGameIterator.cpp: fuzzie fixed my patch (strdup was needed for the time of copy)
[19:39:12] <Avenger> all those bitmaps and stuff are in python now???
[19:39:40] <Avenger> the majority of the leaks are the bitmaps for the savegames
[19:40:48] <fuzzie> well, they're still in C++, but they're not released until the python isdone
[19:40:55] <fuzzie> that should surely be instantly, though
[19:42:04] <Avenger> each list request grows that list, it seems
[19:43:03] <Avenger> actually i see python involved with some of those leaks, but not all
[19:43:52] <fuzzie> i think it will be responsible for all
[19:44:10] <Avenger> ahh, that's because the call chain length
[19:46:08] <fuzzie> i don't understand what this is meant to do, hm
[19:46:39] <Avenger> why was this total rewrite needed? performance reasons or the savegame list bug? Or there was some extra level of rewrite gemrb to c+++++ ?
[19:46:47] <fuzzie> well, it was very buggy
[19:46:52] <fuzzie> and no-one else wanted to fix it
[19:48:28] <fuzzie> some of this is just broken, though
[19:50:59] <Avenger> ok, i have to go, but i will be around more frequently now
[19:51:00] <fuzzie> ok, so, the savegame previews leak?
[19:51:11] <Avenger> yes, i think mostly the bitmaps leak
[19:51:18] <fuzzie> ok. i'll try working it out.
[19:51:41] <Avenger> got a valgrind dump or do you want mine?
[19:52:08] <fuzzie> i can make one if i need :)
[19:53:17] <Avenger> ok, see you then, and thanks !
[19:53:19] <-- Avenger has left IRC (Quit: bye!)
[19:58:18] --> raevol has joined #GemRb
[20:00:18] <fuzzie> the python reference count indeed never goes to zero
[20:01:43] <fuzzie> and that's because tomprince's code is keeping a reference..
[20:06:53] <fuzzie> git sure is impossible to understand sometimes
[20:07:07] <fuzzie> stop trying to do a 5-way merge and just commit this!
[20:09:16] <CIA-23> GemRB: 03fuzzie * r62218ffc49e2 10gemrb/gemrb/plugins/GUIScript/PythonHelpers.h: (hopefully) fix a python reference leak
[20:10:05] <fuzzie> i won't ask why caller is responsible for that
[20:10:28] <fuzzie> but it does seem to actually delete things now
[21:05:59] <-- pupnik has left IRC (Ping timeout: 245 seconds)
[21:11:52] --> pupnik has joined #GemRb
[21:13:34] <-- budlust has left IRC (Remote host closed the connection)
[21:14:02] --> budlust_ has joined #GemRb
[21:14:13] --- budlust_ is now known as budlust
[21:16:40] <-- pupnik has left IRC (Ping timeout: 260 seconds)
[21:17:09] --> pupnik has joined #GemRb
[21:30:19] <-- pupnik has left IRC (Quit: Reconnecting)
[21:30:22] --> pupnik has joined #GemRb
[21:45:29] <-- budlust has left IRC (Ping timeout: 260 seconds)
[21:49:38] --> budlust has joined #GemRb
[22:08:01] <-- lynxlynxlynx has left IRC (Remote host closed the connection)
[22:12:40] <-- budlust has left IRC (Quit: budlust)
[23:28:53] --> roobie|_| has joined #GemRb
[23:55:54] --> budlust has joined #GemRb