www.mooseframework.org
ImageFunction.h
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #pragma once
11 
12 // MOOSE includes
13 #include "Function.h"
14 #include "ImageSampler.h"
15 
19 class ImageFunction : public ImageSampler, public Function
20 {
21 public:
27 
29 
33  virtual ~ImageFunction();
34 
38  virtual void initialSetup() override;
39 
40  using Function::value;
46  virtual Real value(Real t, const Point & p) const override;
47 };
virtual void initialSetup() override
Initialize the ImageSampler.
Definition: ImageFunction.C:33
Base class for function objects.
Definition: Function.h:37
A function for extracting data from an image or stack of images.
Definition: ImageFunction.h:19
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
virtual Real value(Real t, const Point &p) const override
Return the pixel value for the given point.
Definition: ImageFunction.C:41
ImageFunction(const InputParameters &parameters)
Definition: ImageFunction.C:25
A helper class for reading and sampling images using VTK.
Definition: ImageSampler.h:47
static InputParameters validParams()
Class constructor.
Definition: ImageFunction.C:16
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const InputParameters & parameters() const
Get the parameters of the object.
virtual ~ImageFunction()
Class destructor.
Definition: ImageFunction.C:30
virtual Real value(Real t, const Point &p) const
Override this to evaluate the scalar function at point (t,x,y,z), by default this returns zero...
Definition: Function.C:41