Add accessor functions and functionality needed by CMS event display.#99
Add accessor functions and functionality needed by CMS event display.#99osschar wants to merge 2 commits into
Conversation
Parts of this were accessed through redefining private/protected as public which, besides of being a nasty hack, does not work with gcc-5.
There was a problem hiding this comment.
It is not obvious what is the use case for re-initializing the TColor. Could you add a comment giving some context?
|
This is for full-framework use-case where we start root in batch mode. When the request to start up TApplication & GUI arrives we have to set up things again. TStryle objects get deleted and even if we recreate them, the colors do not because the init_done is set to true ... so we had this workaround to enforce this reinitialization. |
|
Oh, I remember now ... there is ~TApplication called somewhere from cmssw, let me try to find it. |
|
Why is deleting the TStyle also deleting the TColor (such that they need recreating)? |
|
I guess because it's in gROOT->GetListOfColors() ... and ~TApplication calls gROOT->EndOfProcessCleanups(); |
|
Looking at it some more ... we create a new instance of TRint that replaces the default TApplication: Should we try figuring this one out? |
|
I don't see a commit between 5.34.17 and 5.34.18 that would explain the change of behaviors. |
|
CMS probably skipped some versions before 5.34.18 ... and we only noticed it at 18. I'd guess this is the guy: |
|
|
OK, I'll remove the TColor changes from the PR then. Let me know when you have the fix, I'll try it in fireworks. |
|
ping^1 |
|
The changes have been pushed onto the master. We still need to come up with a solution for TColor (I.e. we need to update the "deletes the default TApplication" to be softer (i.e. not call EndOfProcessCleanups() ) |
|
Just for reference, commit: https://root.cern.ch/gitweb?p=root.git;a=commit;h=e1503ba36e99dab94f281f75cc504025689493c5 That's a good progress, we might have GCC 5.2.0 and GCC 6.0.0 builds after all ;) Any ideas on ETA for TColor? |
|
TColor: I recommend using osschar's fix locally to move forward. |
|
We are not that burning, I prefer upstream solution instead out of tree patches. GCC 5.2+ is scheduled for CMSSW_8_0_X. |
|
I'm away this week, it's near impossible to run full-framework event display remotely. I'll try this next Monday. |
|
ping, reminder ;) |
|
Yup, i R back ... on to it now :) |
|
@osschar do we have a verdict? Are we fine between ROOT + CMS Fireworks? No more any |
|
@pcanal would it be possible to get these changes at least in 6.04 for now? |
|
@pcanal do you want me to make separate PRs for 6.02 and 6.04 branches? |
|
Actually, yes would be nice to have in 6.02 also, because 6.04 are taking time and not fully working yet for CMSSW. |
|
@osschar: yes, it would nice to have two new PR. |
|
OK, deal, will try to do it later today. Thanks for your help! |
Parts of this were accessed through redefining private/protected as public
which, besides of being a nasty hack, does not work with gcc-5.
TColor had a static bool member fgInitDone that is now a local static in InitializeColors(). I just added a bool argument force=kFALSE as this was a minimal change. If desired, I can do the following:
. Split InitializeColors() into initial part that does the check is-init-done and the actual initialization code that is private.
. Introduce new static function InitializeColorsForce() that skips the check.
This way the interface to InitializeColors() will not change.