[vtk-developers] PLY reader issues

Thompson, David C dcthomp at sandia.gov
Sat Nov 17 15:55:49 EST 2007


That brings up an interesting point... vtkErrorMacro doesn't
use 'this' directly but rather calls vtkErrorWithObjectMacro.
Does Kitware advise/support the use of vtkErrorWithObjectMacro
directly? I ask because there are times when I'm writing a
static function where 'this' isn't defined but there is a
pointer to *some* vtkObject-derived class. Should I be calling
vtkGenericWarningMacro or vtkErrorWithObjectMacro in those
instances (pun intended)?

    Thanks,
    David

-----Original Message-----
From: Will Schroeder [mailto:will.schroeder at kitware.com]
Sent: Sat 11/17/2007 3:24 AM
To: Sean McBride
Cc: Thompson, David C; Vtk Developers
Subject: Re: [vtk-developers] PLY reader issues
 
vtkGenericWarningMacro can be used, it's found in Common/vtkSetGet.h

On 11/16/07, Sean McBride <sean at rogue-research.com> wrote:
>
> On 11/16/07 9:31 PM, David C Thompson said:
>
> >> vtkErrorMacro seems to require 'this' but everything in vtkPLY is
> static
> >> methods.  Is there a variant error macro I can use?  I didn't see
> one...
> >
> >vtkGenericWarningMacro doesn't require 'this' . It can't invoke an
> >ErrorEvent, so no one can use observers to watch for generic warnings,
> >but a message will be printed.
>
> Works great, thanks!  Next week I'll check in some changes so that
> vtkPLY's error handling is, um, less bad. :)
>
> --
> ____________________________________________________________
> Sean McBride, B. Eng                 sean at rogue-research.com
> Rogue Research                        www.rogue-research.com
> Mac Software Developer              Montréal, Québec, Canada
>
> _______________________________________________
> vtk-developers mailing list
> vtk-developers at vtk.org
> http://www.vtk.org/mailman/listinfo/vtk-developers
>



-- 
William J. Schroeder, PhD
Kitware, Inc.
28 Corporate Drive
Clifton Park, NY 12065
will.schroeder at kitware.com
http://www.kitware.com
518-371-3971 (phone and fax)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtk-developers/attachments/20071117/70be7a1e/attachment.html>


More information about the vtk-developers mailing list