def METHOD_NAME(self):
    if self.Image == None:
        self.PrintError('Error: No input image.')
    if self.Cast:
        cast = vtk.vtkImageCast()
        cast.SetInputData(self.Image)
        cast.SetOutputScalarTypeToFloat()
        cast.Update()
        self.Image = cast.GetOutput()
    resliceFilter = vtk.vtkImageReslice()
    resliceFilter.SetInputData(self.Image)
    if self.ReferenceImage:
        resliceFilter.SetInformationInput(self.ReferenceImage)
    else:
        if self.OutputSpacing:
            resliceFilter.SetOutputSpacing(self.OutputSpacing)
        if self.OutputOrigin:
            resliceFilter.SetOutputOrigin(self.OutputOrigin)
        if self.OutputExtent:
            resliceFilter.SetOutputExtent(self.OutputExtent)
    if self.Interpolation == 'nearestneighbor':
        resliceFilter.SetInterpolationModeToNearestNeighbor()
    elif self.Interpolation == 'linear':
        resliceFilter.SetInterpolationModeToLinear()
    elif self.Interpolation == 'cubic':
        resliceFilter.SetInterpolationModeToCubic()
    else:
        self.PrintError('Error: unsupported interpolation mode')
    resliceFilter.SetBackgroundLevel(self.BackgroundLevel)
    if self.TransformInputSampling:
        resliceFilter.TransformInputSamplingOn()
    else:
        resliceFilter.TransformInputSamplingOff()
    if not self.Matrix4x4:
        if self.MatrixCoefficients != []:
            self.PrintLog('Setting up transform matrix using specified coefficients')
            self.Matrix4x4 = vtk.vtkMatrix4x4()
            self.Matrix4x4.DeepCopy(self.MatrixCoefficients)
        elif self.Translation != [0.0,0.0,0.0] or self.Rotation != [0.0,0.0,0.0] or self.Scaling != [1.0,1.0,1.0]:
            self.PrintLog('Setting up transform matrix using specified translation, rotation and/or scaling')
            transform = vtk.vtkTransform()
            transform.RotateX(self.Rotation[0])
            transform.RotateY(self.Rotation[1])
            transform.RotateZ(self.Rotation[2])
            transform.Translate(self.Translation[0], self.Translation[1], self.Translation[2])
            transform.Scale(self.Scaling[0], self.Scaling[1], self.Scaling[2])
            self.Matrix4x4 = vtk.vtkMatrix4x4()
            self.Matrix4x4.DeepCopy(transform.GetMatrix())
    if self.InvertMatrix and self.Matrix4x4:
        self.Matrix4x4.Invert()
    if self.Matrix4x4:
        transform = vtk.vtkMatrixToLinearTransform()
        transform.SetInput(self.Matrix4x4)
        resliceFilter.SetResliceTransform(transform)
    resliceFilter.Update()
    self.Image = resliceFilter.GetOutput()