IRC Log Viewer » #firebreath » 2012-11-28

IRC Nick Time (GMT-7) Message
jshanab 08:11 I am having a problem with when onWindowAttached is being called. It is too early. I can attempt to draw on it and crash before it is ready. This shows up on windows as a silent failure to draw and a crash on mac A Sleep helps avoid the problem but is there another event I can connect to?
taxilian 09:11 jshanab: on mac which drawing model are you using?
jshanab 09:11 CoreGraphics +Cocoa
taxilian 09:11 well, there is your problem
you can't ever draw in OnWindowAttached; you don't even get a CGContextRef
you have to wait for a CoreGraphicsDraw event (extends RefreshEvent)
jshanab 09:11 Thanks. Is there an equivilent on windows?
My error is during window creation in response to onWindowAttached. For example calling get window size will fail (i know size is passed) but get window title or any call to getWindowProp fails becasue it must call the winproc and that is not yet unlocked
taxilian 09:11 there is a RefreshEvent on windows that is called for WM_PAINT
jshanab 09:11 Since that question, I have discovered a more pressing issue. As i scroll the webpage, any plugin whose display area is clipped flickers like crazy. I am looking into an on clip event handler, but the other libraries did not flicker.
taxilian 09:11 hmm; that's interesting. If I were you I'd probably do your opengl stuff on a different thread anyway
hmm. yeah, I seem to remember someone finding a solution to that, but I don't remember what it was
maybe was a background clear event or something similar
jshanab 09:11 It has it's own thread and it is being drawn at 6-30 fps, but somehow a white square keeps getting drawn.
Yeah something like return 1 and that prevents the OS from whiting it out
onClipChange does not seem to get called
taxilian 09:11 don't think it ever does on windows
jshanab 09:11 Oh. well that may be what I need, i need to pass the clip rectangle coordinates to the opengl sizzor funcs
jshanab 10:11 taxilian. i discovered a cmake/build snafu. If you prep to a directory like so prepvs2010 {myprojectdir} build/{myprojectdir} It works correctly if {myprojectdir} matches what is in the project file. If it is different, it puts it the firebreath.sln in the build directory and the other solution in the {myproject} directory. If you have meore than one project and this happens it overwrites...
...the top level Firebrath.sln (having two solutions is causing us headaches)
taxilian 10:11 umm… does build/ have anything in it to start with?
jshanab 10:11 I just redid this caus i was getting confused. I wiped out build and built our plugin with prep2010 {ourPlugin} build/{ourPlugin} and the toplevel solutionis in the build/{ourPlugin} directory. then I did the prep2010 {ourOtherPlugin} build/{OurOtherPlugin} and it ends up with a sln at the top level
taxilian 10:11 did the build/ directory exist when you started?
that's probably a prep script thing, not cmake
jshanab 10:11 not at first, i removed it. of course it existed when i built the second one.
taxilian 10:11 prep script probably can't handle that
delete build/ , then mkdir build before you run those preps
jshanab 10:11 I want to put the output of prep into a directory for each plugin and not overwrite the toplevel solution (actually I'd like for there to be only one sln per project and have it named accordingly :-)
I go back and for between plugins a lot. delete and reprep every time?
taxilian 10:11 delete build/ , then mkdir build before you run those preps
prep script only creates one directory
I think
so it won't create build/plugin
it only creates build/
jshanab 10:11 The directory name is build/projectname, each prep has a unique directory
taxilian 10:11 yeah; create build/ before you run the first prep
jshanab 10:11 Works on linux and works first time on windows :-)
maybe the path is being cut in half, we know how bad windows is at path handling ;-)
taxilian 10:11 I don't even know why it works the first time on windows
jshanab 10:11 I will check again next time i redo the build directory. It looked to me to be when the directory name did not match the projectname in the projectDef.cmake file. I copied a project and changed only tthe dir name
I wasn't sure what it takes to clone a FB project
taxilian 10:11 there is no reason I know of why the project name and directory name would be related
in fact, it seems highly unlikely to me
jshanab 10:11 ok, good.
Looks like it is my week for embarrassing myself. It works fine with the two level directory. as long as you use the correct direction slash. Jumping between Operating systems has side effects
I just need to rename that top level solution before I do it again
taxilian 10:11 hehe. yeah, that would do it
I prefer to look at it as your week for learnign
jshanab 11:11 The more I bang my head against the wall the more i learn it hurts?
taxilian 11:11 well, that and you learn which walls are soft
jshanab 11:11 Funny I should think back to a ComputerScience dept party where a slightly intoxicated student (not me) banged his head against the wall as a joke, only to find a 1/4 stub of a painted over finishing nail. The party ended in a trip to ER once we found someone fit to drive
taxilian 11:11 lol
*sigh* all the "fun" things I miss out on living in a place that most people dont' drink
jshanab 11:11 I almost got bounced from a club once because they thought I had too much to drink and I had only drank water. That is scary, no excuse!
taxilian 11:11 lol
glock45 13:11 hi
taxilian: i fixed my issue with Chrome 22+ on Mac OS.
taxilian 13:11 excellent
I don't remember what your issue was =] but I'm glad you fixed it
glock45 13:11 Well, I send you a email.
taxilian 13:11 okay
I'm off to lunch; be back in a bit
glock45 13:11 But let me copy this here. So
jshanab 14:11 If I change or rebuild a bunch of secondary dlls, Do I have to clean and rebuild to create an msi and make sure they end up in it. or can I build a smaller project like the {plugin_WixInstaller} only
taxilian 14:11 you should be able to just build the wixinstaller project
jshanab 14:11 Good. I will try that next time. (this thing takes a bit to build!)
Do you remember your sugestion of a child window of the window handed to me to solve event issues? I am trying that inside the GLFW library to stop the horrific flickering
taxilian 14:11 hmm. not sure if that'll make a difference or not
jshanab 14:11 It allows me to specify that it is a child window with the WM_CLIPSIBLINGS Seetings. windows does not let you change a windows flags after creation
taxilian 14:11 ahh
jshanab 14:11 The thought is that then opengl will be notified and handle the clipping events
But boy does it mess with the eventing! deadlocks
taxilian 14:11 heh
jshanab 15:11 Can't even resize or touch the scroll on the browser. The White Screen of death. We are now aquiring a collection Blue,Black, and White Screen of death
taxilian 15:11 awesome. you can never have too many Screens of Death
jshanab 15:11 I am drawing video on the half white screen, it is still running, well everything except the UI
taxilian 15:11 heh
RenJuan 16:11 amirite that the project source dir, the thing you move out of projects after fbgen doesn't have a cmake variable?
taxilian 16:11 no, there is one
RenJuan 16:11 ie. PROJDIR
taxilian 16:11 in fact probably ${CMAKE_CURRENT_SOURCE_DIR} when your'e in that project
RenJuan 16:11 got it
i think
unclear why "probably"
taxilian 16:11 because I'm on the phone
and not thinking about it
RenJuan 16:11 ah, yes and I see you're thinking of something else too
jshanab 16:11 taxilian. BTW building the wix project does not repackage. so I change the dll in a seperate solution and the only way to generate a new msi is to clean and build (Darn, I didn't try cleaning just the wix installer project LOL)
taxilian 16:11 RenJuan: if you are in that project's cmake files then that variable should work
jshanab 17:11 I have a problem. My plugin works until i touch the browser frame. Move. resize, scroll. This is obviously event handling issue, but it locks the UI's of firefox,visual studio if attached and the desktop. I can still move the mouse but clicks are ignored window moves are ignored. I can bring up a task manager with a 3-finger salute and kill firefox and everthing comes back
taxilian 18:11 that sounds very annoying
jshanab 18:11 yeah. It makes no sense. when it was working a little more, I could hit the pause in visual studio and see parallel stacks but there was no obvious mutexes blocking or anything.
As soon as I created a child window before I also had the problem. Events come directly to the child window and not thru plugin anymore. For some reason that freezes the browser since it is a child window. A torn off window handles the events fine. It accepts about 6 events per plugin instance, (i have printing breakpoints) then it freezes. almost like a queu is full and blocks
taxilian 18:11 hmm
no idea :-/
RenJuan 18:11 u slay me taxilian
taxilian 18:11 ?
RenJuan 18:11 never heard that expression?
jshanab 18:11 I don't get it either
taxilian 18:11 do you mean "you kill me"?
RenJuan 18:11 I think "slay" was the original.
jshanab 18:11 Like when you say somethin funny
RenJuan 18:11 anywho, I'm doing more cmake than I thought I would
taxilian 18:11 could be
heh. that's unfortunately normal for plugin dev with firebreath
cmake is really a horrible thing to have to use; it's almost as bad as the other options we could have chosen
jshanab 18:11 I have learned to love cmake
taxilian 18:11 I have a love/hate relationship with it
I hate it almost as much as I'd hate not having it
jshanab 18:11 Anything with the word "crossplatform" in front of it is at risk
RenJuan 18:11 well I was at the point of putting the bld trees under source control and I puked that up
taxilian 18:11 bad bad idea
never put the build dir in source control
RenJuan 18:11 to deliver this app I have 3 trees, fb, and the 32 and 64 bit source projects
well ida done it if I wanted to
taxilian 18:11 you would have regretted it
but I guess that's your decision =]
RenJuan 18:11 no I wouldn't have had I made the decision
taxilian 18:11 I figure everyone has the right to have their own learning experiences =]
if you say so
RenJuan 18:11 and I still have to have a postprep command. FB sort of trails off on some stuff.
taxilian 18:11 okay, first let's point fingers in the right direction; that'd be cmake that is trailing off
but what is is trailing off on?
RenJuan 18:11 cmake, my bad
resources mostly
taxilian 18:11 you can probably do it with cmake
jshanab 18:11 You can add all kinds of stuf into the process. I run protocol buffrers compiler, copy files and trigger documentation. What is falling off?
Wait until you discover cpack :-)
taxilian 18:11 heh. now if only cpack would do what I want
jshanab 18:11 I used it on my scheduleserver and it made a linux,apple, and windows installer. Yeh but all the plugin stuff would make it "interesting"
I am going to have to throw in the towel. Nothing I do gets past this problem and the debugging is not hitting any of the breakpoints in my mind. Time for dinner. C-ya guys tomorrow
taxilian 18:11 gotta run
good luck