Project

General

Profile

Download (3.89 KB) Statistics
| Branch: | Revision:

distorted-objectlib / src / main / java / org / distorted / objectlib / helpers / ObjectFaceShape.java @ 3bf19410

1
///////////////////////////////////////////////////////////////////////////////////////////////////
2
// Copyright 2021 Leszek Koltunski                                                               //
3
//                                                                                               //
4
// This file is part of Magic Cube.                                                              //
5
//                                                                                               //
6
// Magic Cube is free software: you can redistribute it and/or modify                            //
7
// it under the terms of the GNU General Public License as published by                          //
8
// the Free Software Foundation, either version 2 of the License, or                             //
9
// (at your option) any later version.                                                           //
10
//                                                                                               //
11
// Magic Cube is distributed in the hope that it will be useful,                                 //
12
// but WITHOUT ANY WARRANTY; without even the implied warranty of                                //
13
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the                                 //
14
// GNU General Public License for more details.                                                  //
15
//                                                                                               //
16
// You should have received a copy of the GNU General Public License                             //
17
// along with Magic Cube.  If not, see <http://www.gnu.org/licenses/>.                           //
18
///////////////////////////////////////////////////////////////////////////////////////////////////
19

    
20
package org.distorted.objectlib.helpers;
21

    
22
///////////////////////////////////////////////////////////////////////////////////////////////////
23

    
24
public class ObjectFaceShape
25
  {
26
  private final int[] mBandIndices;
27
  private final float[][] mCorners;
28
  private final int[] mCornerIndices;
29
  private final float[][] mCenters;
30
  private final int[] mCenterIndices;
31
  private final float[] mConvexityCenter;
32
  private final float[][] mBands;
33

    
34
///////////////////////////////////////////////////////////////////////////////////////////////////
35

    
36
  public ObjectFaceShape(float[][] bands, int[] bandIndices, float[][] corners, int[] cornIndices,
37
                         float[][] centers, int[] centIndices, float[] convexityCenter)
38
    {
39
    mBands           = bands;
40
    mBandIndices     = bandIndices;
41
    mCorners         = corners;
42
    mCornerIndices   = cornIndices;
43
    mCenters         = centers;
44
    mCenterIndices   = centIndices;
45
    mConvexityCenter = convexityCenter;
46
    }
47

    
48
///////////////////////////////////////////////////////////////////////////////////////////////////
49

    
50
  public float[][] getBands()
51
    {
52
    return mBands;
53
    }
54

    
55
///////////////////////////////////////////////////////////////////////////////////////////////////
56

    
57
  public int[] getBandIndices()
58
    {
59
    return mBandIndices;
60
    }
61

    
62
///////////////////////////////////////////////////////////////////////////////////////////////////
63

    
64
  public float[][] getCorners()
65
    {
66
    return mCorners;
67
    }
68

    
69
///////////////////////////////////////////////////////////////////////////////////////////////////
70

    
71
  public int[] getCornerIndices()
72
    {
73
    return mCornerIndices;
74
    }
75

    
76
///////////////////////////////////////////////////////////////////////////////////////////////////
77

    
78
  public float[][] getCenters()
79
    {
80
    return mCenters;
81
    }
82

    
83
///////////////////////////////////////////////////////////////////////////////////////////////////
84

    
85
  public int[] getCenterIndices()
86
    {
87
    return mCenterIndices;
88
    }
89

    
90
///////////////////////////////////////////////////////////////////////////////////////////////////
91

    
92
  public float[] getConvexityCenter()
93
    {
94
    return mConvexityCenter;
95
    }
96
  }
(6-6/10)