VTK: Infovis/Layout/vtkSquarifyLayoutStrategy.h Source File

| VTK 9.3.1

vtkSquarifyLayoutStrategy.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright 2008 Sandia Corporation
3 // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Sandia-USGov
24 #ifndef vtkSquarifyLayoutStrategy_h
25 #define vtkSquarifyLayoutStrategy_h
26
27 #include "vtkInfovisLayoutModule.h" // For export macro
28 #include "vtkTreeMapLayoutStrategy.h"
29
30 VTK_ABI_NAMESPACE_BEGIN
31 class vtkIdList;
32
33 class VTKINFOVISLAYOUT_EXPORT vtkSquarifyLayoutStrategy : public vtkTreeMapLayoutStrategy
34 {
35 public:
36 static vtkSquarifyLayoutStrategy* New();
37 vtkTypeMacro(vtkSquarifyLayoutStrategy, vtkTreeMapLayoutStrategy);
38 void PrintSelf(ostream& os, vtkIndent indent) override;
39
44 void Layout(vtkTree* inputTree, vtkDataArray* coordsArray, vtkDataArray* sizeArray) override;
45
46 protected:
47 vtkSquarifyLayoutStrategy();
48 ~vtkSquarifyLayoutStrategy() override;
49
50 private:
51 void LayoutChildren(vtkTree* tree, vtkDataArray* coordsArray, vtkDataArray* sizeArray,
52 vtkIdType nchildren, vtkIdType parent, vtkIdType begin, float minX, float maxX, float minY,
53 float maxY);
54
55 vtkSquarifyLayoutStrategy(const vtkSquarifyLayoutStrategy&) = delete;
56 void operator=(const vtkSquarifyLayoutStrategy&) = delete;
57 };
58
59 VTK_ABI_NAMESPACE_END
60 #endif
vtkDataArray
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:54
vtkIdList
list of point or cell ids
Definition: vtkIdList.h:32
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:38
vtkSquarifyLayoutStrategy
uses the squarify tree map layout algorithm
Definition: vtkSquarifyLayoutStrategy.h:34
vtkSquarifyLayoutStrategy::New
static vtkSquarifyLayoutStrategy * New()
vtkSquarifyLayoutStrategy::Layout
void Layout(vtkTree *inputTree, vtkDataArray *coordsArray, vtkDataArray *sizeArray) override
Perform the layout of a tree and place the results as 4-tuples in coordsArray (Xmin,...
vtkSquarifyLayoutStrategy::~vtkSquarifyLayoutStrategy
~vtkSquarifyLayoutStrategy() override
vtkSquarifyLayoutStrategy::vtkSquarifyLayoutStrategy
vtkSquarifyLayoutStrategy()
vtkSquarifyLayoutStrategy::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkTreeMapLayoutStrategy
abstract superclass for all tree map layout strategies
Definition: vtkTreeMapLayoutStrategy.h:36
vtkTree
A rooted tree data structure.
Definition: vtkTree.h:55
vtkTreeMapLayoutStrategy.h
vtkIdType
int vtkIdType
Definition: vtkType.h:315