| 1 |
// Copyright(C) 1999-2022, 2024 National Technology & Engineering Solutions |
| 2 |
// of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with |
| 3 |
// NTESS, the U.S. Government retains certain rights in this software. |
| 4 |
// |
| 5 |
// See packages/seacas/LICENSE for details |
| 6 |
|
| 7 |
#pragma once |
| 8 |
|
| 9 |
#include "Ioss_Transform.h" // for Transform, Factory |
| 10 |
#include "Ioss_TransformFactory.h" |
| 11 |
#include "Ioss_VariableType.h" // for VariableType |
| 12 |
#include <stddef.h> |
| 13 |
#include <string> // for string |
| 14 |
#include <vector> // for vector |
| 15 |
|
| 16 |
#include "iotr_export.h" |
| 17 |
|
| 18 |
namespace Ioss { |
| 19 |
class Field; |
| 20 |
} // namespace Ioss |
| 21 |
|
| 22 |
namespace Iotr { |
| 23 |
|
| 24 |
class IOTR_EXPORT Offset3D_Factory : public Ioss::TransformFactory |
| 25 |
{ |
| 26 |
public: |
| 27 |
static const Offset3D_Factory *factory(); |
| 28 |
|
| 29 |
private: |
| 30 |
Offset3D_Factory(); |
| 31 |
IOSS_NODISCARD Ioss::Transform *make(const std::string & /*unused*/) const override; |
| 32 |
}; |
| 33 |
|
| 34 |
class IOTR_EXPORT Offset3D : public Ioss::Transform |
| 35 |
{ |
| 36 |
friend class Offset3D_Factory; |
| 37 |
|
| 38 |
public: |
| 39 |
IOSS_NODISCARD const Ioss::VariableType * |
| 40 |
output_storage(const Ioss::VariableType *in) const override; |
| 41 |
IOSS_NODISCARD size_t output_count(size_t in) const override; |
| 42 |
|
| 43 |
void set_properties(const std::string &name, const std::vector<int> &values) override; |
| 44 |
void set_properties(const std::string &name, const std::vector<double> &values) override; |
| 45 |
|
| 46 |
protected: |
| 47 |
Offset3D(); |
| 48 |
|
| 49 |
bool internal_execute(const Ioss::Field &field, void *data) override; |
| 50 |
|
| 51 |
private: |
| 52 |
int intOffset[3]{}; |
| 53 |
double realOffset[3]{}; |
| 54 |
}; |
| 55 |
} // namespace Iotr |