Hi Michael, Try,
ByteOrder order = ByteOrder.nativeOrder(); FloatBuffer coord = ByteBuffer.allocateDirect(size).order(order).asFloatBuffer(); You can found the examples under programs/examples/GeometryByReference>GeometryByReferenceNIOBuffer and programs/examples/GeometryByReference>InterleavedNIOBuffer - Kelvin ------------- Java 3D Team Sun Microsystems Inc. >Delivered-To: [EMAIL PROTECTED] >MIME-Version: 1.0 >Content-Transfer-Encoding: 8BIT >X-Sender: [EMAIL PROTECTED] >Date: Fri, 23 Nov 2001 23:05:18 +0100 >From: atarifly_zero <[EMAIL PROTECTED]> >Subject: [JAVA3D] J3DBuffers - how to use them correctly ? >To: [EMAIL PROTECTED] > >At first I used the static method wrap from the FloatBuffer class, then I >noticed J3DBuffers need a direct one, so I decided to use >ByteBuffer.allocateDirect(size).asFloatBuffer(); >and put my array in.. >and I got following error: >NIO Buffer must match native byte order of underlying plattform > >I'm sure I don't have to do something plattform specific in my code, do I ? > >are there any online example available already ? > >thx for answers > >greetings > -Michael Nischt > >=========================================================================== >To unsubscribe, send email to [EMAIL PROTECTED] and include in the body >of the message "signoff JAVA3D-INTEREST". For general help, send email to >[EMAIL PROTECTED] and include in the body of the message "help". =========================================================================== To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff JAVA3D-INTEREST". For general help, send email to [EMAIL PROTECTED] and include in the body of the message "help".
