test/jdk/java/awt/image/BandedSampleModel/BandedSampleModelSizeTest.java
author pnarayanan
Tue, 16 Jan 2018 10:49:49 +0530
changeset 48644 f611f49a46c9
permissions -rw-r--r--
8194489: Incorrect size computation at BandedSampleModel.createDataBuffer() Reviewed-by: bpb, jdv Contributed-by: prahalad.kumar.narayanan@oracle.com
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
48644
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     1
/*
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     2
 * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     4
 *
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     7
 * published by the Free Software Foundation.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     8
 *
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    13
 * accompanied this code).
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    14
 *
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    18
 *
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    21
 * questions.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    22
 */
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    23
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    24
/*
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    25
 * @test
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    26
 * @bug 8194489
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    27
 * @summary The test checks whether BandedSampleModel computes appropriate
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    28
 *          size for allocating memory in DataBuffer.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    29
 * @run main BandedSampleModelSizeTest
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    30
 */
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    31
import java.awt.image.BandedSampleModel;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    32
import java.awt.image.DataBuffer;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    33
import java.util.Arrays;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    34
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    35
public class BandedSampleModelSizeTest {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    36
    // Constants
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    37
    private static final int TEST_NUM_BANDS = 3;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    38
    private static final int TEST_SRC_IMG_DIM = 10;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    39
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    40
    // Required sample models
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    41
    private static BandedSampleModel singleBankModel = null;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    42
    private static BandedSampleModel multiBankModel = null;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    43
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    44
    private static void initTest() {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    45
        int[] bandOffsets = new int[TEST_NUM_BANDS];
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    46
        int[] bankIndices = new int[TEST_NUM_BANDS];
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    47
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    48
        /*
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    49
         * Create a BandedSampleModel to store samples of all bands in one
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    50
         * bank of DataBuffer.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    51
         */
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    52
        bandOffsets[0] = 0;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    53
        bandOffsets[1] = 120;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    54
        bandOffsets[2] = 240;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    55
        bankIndices[0] = 0;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    56
        bankIndices[1] = 0;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    57
        bankIndices[2] = 0;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    58
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    59
        singleBankModel = new BandedSampleModel(DataBuffer.TYPE_BYTE,
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    60
                TEST_SRC_IMG_DIM, TEST_SRC_IMG_DIM, TEST_SRC_IMG_DIM,
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    61
                bankIndices, bandOffsets);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    62
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    63
        /*
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    64
         * Create a BandedSampleModel to store samples of all bands in
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    65
         * different banks of DataBuffer.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    66
         */
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    67
        bandOffsets[0] = 0;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    68
        bandOffsets[1] = 20;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    69
        bandOffsets[2] = 40;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    70
        bankIndices[0] = 0;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    71
        bankIndices[1] = 1;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    72
        bankIndices[2] = 2;
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    73
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    74
        multiBankModel = new BandedSampleModel(DataBuffer.TYPE_BYTE,
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    75
                TEST_SRC_IMG_DIM, TEST_SRC_IMG_DIM, TEST_SRC_IMG_DIM,
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    76
                bankIndices, bandOffsets);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    77
    }
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    78
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    79
    private static void testSingleBankModel() {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    80
        int[] srcSamples = new int[TEST_NUM_BANDS];
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    81
        int[] resSamples = new int[TEST_NUM_BANDS];
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    82
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    83
        // Create image buffer for the requried sample model
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    84
        DataBuffer imgBuffer = singleBankModel.createDataBuffer();
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    85
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    86
        // Test the sample model by setting a pixel value & inspecting the same.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    87
        Arrays.fill(srcSamples, 125);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    88
        singleBankModel.setPixel(0, 0, srcSamples, imgBuffer);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    89
        singleBankModel.getPixel(0, 0, resSamples, imgBuffer);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    90
        if (!Arrays.equals(srcSamples, resSamples)) {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    91
            throw new RuntimeException("Test Failed. Incorrect samples found"
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    92
                    + " in the image");
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    93
        }
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    94
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    95
        Arrays.fill(srcSamples, 250);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    96
        singleBankModel.setPixel(9, 9, srcSamples, imgBuffer);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    97
        singleBankModel.getPixel(9, 9, resSamples, imgBuffer);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    98
        if (!Arrays.equals(srcSamples, resSamples)) {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
    99
            throw new RuntimeException("Test Failed. Incorrect samples found"
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   100
                    + " in the image");
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   101
        }
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   102
    }
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   103
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   104
    private static void testMultiBankModel() {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   105
        int[] srcSamples = new int[TEST_NUM_BANDS];
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   106
        int[] resSamples = new int[TEST_NUM_BANDS];
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   107
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   108
        // Create image buffer for the required sample model
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   109
        DataBuffer imgBuffer = multiBankModel.createDataBuffer();
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   110
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   111
        // Test the sample model by setting a pixel value & inspecting the same.
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   112
        Arrays.fill(srcSamples, 125);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   113
        multiBankModel.setPixel(0, 0, srcSamples, imgBuffer);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   114
        multiBankModel.getPixel(0, 0, resSamples, imgBuffer);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   115
        if (!Arrays.equals(srcSamples, resSamples)) {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   116
            throw new RuntimeException("Test Failed. Incorrect samples found"
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   117
                    + " in the image");
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   118
        }
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   119
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   120
        Arrays.fill(srcSamples, 250);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   121
        multiBankModel.setPixel(9, 9, srcSamples, imgBuffer);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   122
        multiBankModel.getPixel(9, 9, resSamples, imgBuffer);
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   123
        if (!Arrays.equals(srcSamples, resSamples)) {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   124
            throw new RuntimeException("Test Failed. Incorrect samples found"
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   125
                    + " in the image");
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   126
        }
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   127
    }
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   128
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   129
    public static void main(String args[]) {
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   130
        // Initialize the test
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   131
        initTest();
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   132
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   133
        // Test banded sample model with single bank of data buffer
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   134
        testSingleBankModel();
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   135
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   136
        // Test banded sample model with multiple banks of data buffer
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   137
        testMultiBankModel();
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   138
    }
f611f49a46c9 8194489: Incorrect size computation at BandedSampleModel.createDataBuffer()
pnarayanan
parents:
diff changeset
   139
}