Convert float[] to byte[] to float[] again

前端 未结 8 1671
伪装坚强ぢ
伪装坚强ぢ 2020-12-31 15:17

So what I\'m trying to do here is get a float[], convert it to byte[], send it through the network as a datagram packet and then convert it back to

8条回答
  •  清酒与你
    2020-12-31 16:03

    I think you want to make use of the ByteBuffer class, which has putFloat and getFloat methods.

提交回复
热议问题