Java Array array_int2float(int ai[])

Here you can find the source of array_int2float(int ai[])

Description

arraintfloat

License

Open Source License

Declaration

public static final float[] array_int2float(int ai[]) 

Method Source Code

//package com.java2s;
/**// w  ww .  j av a  2  s. c o m
 * 
 *   author: (c)thomas diewald, http://thomasdiewald.com/
 *   date: 23.04.2012
 *   
 *
 * This source is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 * 
 * This code is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * General Public License for more details.
 * 
 * A copy of the GNU General Public License is available on the World
 * Wide Web at <http://www.gnu.org/copyleft/gpl.html>. You can also
 * obtain it by writing to the Free Software Foundation,
 * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 */

public class Main {
    public static final float[] array_int2float(int ai[]) {
        float af[] = new float[ai.length];
        for (int i = 0; i < af.length; i++)
            af[i] = (float) ai[i];
        return af;
    }
}

Related

  1. array_equals(byte[] foo, byte bar[])
  2. array_intAddLimit(int[] in, int value, int limit)
  3. arrayed(int arrays, String inner)
  4. arrayEndsWith(final byte[] array, final byte[] str)
  5. arrayExclude(double[] src, int excludeIndex)