Re: Semi-Transparent polygone

From: Stanislav Nesterov <Stanislav.Nesterov_at_cern.ch>
Date: Sat, 09 Jul 2005 10:31:03 +0200


Hi Rene,

Thank you for the hint. It is not what I am exactly wanted but it may work in my application.

I hope ROOT will incorporate someday real fill-with-colour transparancy. But I understand that it would require some rework in TVirtualX implementations.

Thank you again and

--
       Best regards,
             Stanislav.

Rene Brun wrote:


> Hi Stanislav,
>
> See this example using fill styles with patterns.
>
> Rene Brun
>
> void trans() {
> TH1F *h1 = new TH1F("h1","test1",100,-2,2);
> TF1 f1("f1","gaus",-2,2);
> f1.SetParameters(1,-0.5,1);
> h1->FillRandom("f1",10000);
> TH1F *h2 = new TH1F("h2","test2",100,-2,2);
> f1.SetParameters(1,0.5,0.3);
> h2->FillRandom("f1",3200);
> h1->SetFillStyle(3001);
> h1->SetFillColor(kRed);
> h1->Draw();
> h2->SetFillStyle(3010); //try styles between 3001 and 3025
> h2->SetFillColor(kBlue);
> h2->Draw("same");
> }
>
>
> On Fri, 8 Jul 2005, Stanislav Nesterov wrote:
>
>> Hello,
>> I would like to know is there any way to draw semi-transparent filled
>> area in ROOT? At least in version 4.x?
>>
>> AFAIK, the only one object (TPad) in ROOT can be blended with
>> underlaying layers. All other graphical objects ignore transparency
>> fill style in sense of blending colours. Maybe today this is not the
>> case?
>>
>> --
>> Best regards,
>> Stanislav.
>>
>
Received on Sat Jul 09 2005 - 10:31:09 MEST

This archive was generated by hypermail 2.2.0 : Tue Jan 02 2007 - 14:45:10 MET