Fixed mp3 playing, refactored to avoid duplicating code.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@153 ed5b42cb-e716-0410-a449-f6a68f950b19
This commit is contained in:
@@ -24,6 +24,7 @@ package com.threerings.openal;
|
||||
import java.io.IOException;
|
||||
|
||||
import java.nio.ByteBuffer;
|
||||
import java.nio.ByteOrder;
|
||||
import java.nio.IntBuffer;
|
||||
|
||||
import org.lwjgl.BufferUtils;
|
||||
@@ -263,7 +264,7 @@ public abstract class Stream
|
||||
protected boolean populateBuffer (int bufferId)
|
||||
{
|
||||
if (_abuf == null) {
|
||||
_abuf = ByteBuffer.allocateDirect(BUFFER_SIZE);
|
||||
_abuf = ByteBuffer.allocateDirect(BUFFER_SIZE).order(ByteOrder.nativeOrder());
|
||||
}
|
||||
_abuf.clear();
|
||||
int read = 0;
|
||||
|
||||
Reference in New Issue
Block a user