[vtkusers] Why does the vtkRenderLargeImage open an other window?

John Biddiscombe biddisco at cscs.ch
Fri Jan 26 07:40:38 EST 2007


Glauco
> John,
> I do a cvs update , but the problem yet occur.
> What can i do to resolve this ?
> Thanks !!
I do this - and no extra windows appear...

  vtkRenderLargeImage *large = vtkRenderLargeImage::New();
    large->SetInput(ren);
    large->SetMagnification(mag);
  vtkPNGWriter *pngWriter = vtkPNGWriter::New();
    pngWriter->SetInput(large->GetOutput());

  char filetemplate[512], filepattern[512];
  sprintf(filetemplate, "%s/%s", path.c_str(), name.c_str());
  sprintf(filepattern, filetemplate, 0);
  pngWriter->SetFileName(filepattern);
  pngWriter->Write();
  large->Delete();
  pngWriter->Delete();

any use?

JB



> Glauco
>
> ----- Original Message ----- From: "Glauco Silva" 
> <glauco.silva at cenpra.gov.br>
> To: "John Biddiscombe" <biddisco at cscs.ch>
> Cc: <vtkusers at vtk.org>
> Sent: Friday, January 12, 2007 4:16 PM
> Subject: Re: [vtkusers] Why does the vtkRenderLargeImage open an other 
> window?
>
>
>> Thanks John
>> I will see and if the problem occur i will write again.
>>
>> Glauco
>>
>> ----- Original Message ----- From: "John Biddiscombe" <biddisco at cscs.ch>
>> To: "Glauco Silva" <glauco.silva at cenpra.gov.br>
>> Cc: <vtkusers at vtk.org>
>> Sent: Friday, January 12, 2007 2:45 PM
>> Subject: Re: [vtkusers] Why does the vtkRenderLargeImage open an 
>> other window?
>>
>>
>>> Glauco
>>>
>>> I seem to recall that RenderLargeImage switches to offscreen 
>>> rendering - which on some platforms causes a new (supposed to be 
>>> invisible, but sometimes not) window to be created - but this was 
>>> fixed recently in CVS. I may be wrong, but try doing a cvs update 
>>> and see if the problem goes away.
>>>
>>> JB
>>>
>>> Glauco Silva wrote:
>>>> I'm trying to capture an image that is in a vtkRenderWindow using 
>>>> vtkRenderLargeImage like the example above.
>>>> When I use renderLage.Update() in example above, an other window 
>>>> appear .
>>>> Why this occur ? I don't want this window opened.
>>>> Are There an error in vtkRenderLargeImage ?
>>>> I'm using :
>>>> vtk5... The last one in cvs.
>>>> python25
>>>> windows XP
>>>>  ------------------------------------------------Example (part of 
>>>> code) --------------------------------
>>>>  previewRenderer = vtkRenderer
>>>> previewRenderer.AddActor2D(previewActor2D)
>>>> previewRenderer.AddActor2D(previewActorText)
>>>>  previewRenderWindow = vtkRenderWindow()
>>>> previewRenderWindow.AddRenderer(previewRenderer)
>>>> previewRenderWindow.Render()
>>>> renderLarge = vtkRenderLargeImage()
>>>> renderLarge.SetInput(previewRenderer)
>>>> renderLarge.SetMagnification(1)
>>>> renderLarge.Update()
>>>> ------------------------------------------------------------------------ 
>>>>
>>>>
>>>> _______________________________________________
>>>> This is the private VTK discussion list. Please keep messages 
>>>> on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>>>> Follow this link to subscribe/unsubscribe:
>>>> http://www.vtk.org/mailman/listinfo/vtkusers
>>>>
>>>
>>>
>>> -- 
>>> John Biddiscombe,                            email:biddisco @ cscs.ch
>>> http://www.cscs.ch/about/BJohn.php
>>> CSCS, Swiss National Supercomputing Centre  | Tel:  +41 (91) 610.82.07
>>> Via Cantonale, 6928 Manno, Switzerland      | Fax:  +41 (91) 610.82.82
>>>
>>>
>>>
>>
>


-- 
John Biddiscombe,                            email:biddisco @ cscs.ch
http://www.cscs.ch/about/BJohn.php
CSCS, Swiss National Supercomputing Centre  | Tel:  +41 (91) 610.82.07
Via Cantonale, 6928 Manno, Switzerland      | Fax:  +41 (91) 610.82.82





More information about the vtkusers mailing list