From 8b5631ae77aefed0ecaa872702d29e1686645a5b Mon Sep 17 00:00:00 2001 From: Joshua Granick Date: Tue, 4 Oct 2016 13:00:19 -0700 Subject: [PATCH] Compile fix --- project/src/audio/openal/OpenALBindings.cpp | 86 ++++++++++----------- 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/project/src/audio/openal/OpenALBindings.cpp b/project/src/audio/openal/OpenALBindings.cpp index ebcbb4625..071ac18fd 100644 --- a/project/src/audio/openal/OpenALBindings.cpp +++ b/project/src/audio/openal/OpenALBindings.cpp @@ -42,7 +42,7 @@ namespace lime { void lime_al_buffer_data (value buffer, int format, value data, int size, int freq) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); ArrayBufferView bufferView (data); alBufferData (id, format, bufferView.Data (), size, freq); @@ -51,7 +51,7 @@ namespace lime { void lime_al_buffer3f (value buffer, int param, float value1, float value2, float value3) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); alBuffer3f (id, param, value1, value2, value3); } @@ -59,7 +59,7 @@ namespace lime { void lime_al_buffer3i (value buffer, int param, int value1, int value2, int value3) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); alBuffer3i (id, param, value1, value2, value3); } @@ -67,7 +67,7 @@ namespace lime { void lime_al_bufferf (value buffer, int param, float value) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); alBufferf (id, param, value); } @@ -75,7 +75,7 @@ namespace lime { void lime_al_bufferfv (value buffer, int param, value values) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); if (val_is_null (values) == false) { @@ -98,7 +98,7 @@ namespace lime { void lime_al_bufferi (value buffer, int param, int value) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); alBufferi (id, param, value); } @@ -106,7 +106,7 @@ namespace lime { void lime_al_bufferiv (value buffer, int param, value values) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); if (val_is_null (values) == false) { @@ -153,7 +153,7 @@ namespace lime { if (!val_is_null (buffer)) { - ALuint data = (ALuint)val_data (buffer); + ALuint data = reinterpret_cast (val_data (buffer)); val_gc (buffer, 0); alDeleteBuffers ((ALuint)1, &data); gc_al_pointers.erase (data); @@ -174,7 +174,7 @@ namespace lime { for (int i = 0; i < size; ++i) { buffer = val_array_i (buffers, i); - data[i] = (ALuint)val_data (buffer); + data[i] = reinterpret_cast (val_data (buffer)); val_gc (buffer, 0); gc_al_pointers.erase (data[i]); @@ -190,7 +190,7 @@ namespace lime { void lime_al_delete_source (value source) { - ALuint data = (ALuint)val_data (source); + ALuint data = reinterpret_cast (val_data (source)); alDeleteSources(1, &data); } @@ -207,7 +207,7 @@ namespace lime { for (int i = 0; i < size; ++i) { source = val_array_i (sources, i); - data[i] = (ALuint)val_data (source); + data[i] = reinterpret_cast (val_data (source)); val_gc (source, 0); } @@ -348,7 +348,7 @@ namespace lime { value lime_al_get_buffer3f (value buffer, int param) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); ALfloat val1, val2, val3; alGetBuffer3f (id, param, &val1, &val2, &val3); @@ -364,7 +364,7 @@ namespace lime { value lime_al_get_buffer3i (value buffer, int param) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); ALint val1, val2, val3; alGetBuffer3i (id, param, &val1, &val2, &val3); @@ -380,7 +380,7 @@ namespace lime { float lime_al_get_bufferf (value buffer, int param) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); ALfloat data; alGetBufferf (id, param, &data); return data; @@ -390,7 +390,7 @@ namespace lime { value lime_al_get_bufferfv (value buffer, int param, int count) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); ALfloat* values = new ALfloat[count]; alGetBufferfv (id, param, values); @@ -410,7 +410,7 @@ namespace lime { int lime_al_get_bufferi (value buffer, int param) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); ALint data; alGetBufferi (id, param, &data); return data; @@ -420,7 +420,7 @@ namespace lime { value lime_al_get_bufferiv (value buffer, int param, int count) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); ALint* values = new ALint[count]; alGetBufferiv (id, param, values); @@ -625,7 +625,7 @@ namespace lime { value lime_al_get_source3f (value source, int param) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); ALfloat val1, val2, val3; alGetSource3f (id, param, &val1, &val2, &val3); @@ -641,7 +641,7 @@ namespace lime { value lime_al_get_source3i (value source, int param) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); ALint val1, val2, val3; alGetSource3i (id, param, &val1, &val2, &val3); @@ -657,7 +657,7 @@ namespace lime { float lime_al_get_sourcef (value source, int param) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); ALfloat data; alGetSourcef (id, param, &data); return data; @@ -667,7 +667,7 @@ namespace lime { value lime_al_get_sourcefv (value source, int param, int count) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); ALfloat* values = new ALfloat[count]; alGetSourcefv (id, param, values); @@ -687,7 +687,7 @@ namespace lime { value lime_al_get_sourcei (value source, int param) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); ALint data; alGetSourcei (id, param, &data); @@ -716,7 +716,7 @@ namespace lime { value lime_al_get_sourceiv (value source, int param, int count) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); ALint* values = new ALint[count]; alGetSourceiv (id, param, values); @@ -744,7 +744,7 @@ namespace lime { bool lime_al_is_buffer (value buffer) { - ALuint id = (ALuint)val_data (buffer); + ALuint id = reinterpret_cast (val_data (buffer)); return alIsBuffer (id); } @@ -766,7 +766,7 @@ namespace lime { bool lime_al_is_source (value source) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); return alIsSource (id); } @@ -844,7 +844,7 @@ namespace lime { void lime_al_source_pause (value source) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); alSourcePause (id); } @@ -859,7 +859,7 @@ namespace lime { for (int i = 0; i < size; ++i) { - data[i] = (ALuint)val_data (val_array_i (sources, i)); + data[i] = reinterpret_cast (val_data (val_array_i (sources, i))); } @@ -872,7 +872,7 @@ namespace lime { void lime_al_source_play (value source) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); alSourcePlay (id); } @@ -887,7 +887,7 @@ namespace lime { for (int i = 0; i < size; ++i) { - data[i] = (ALuint)val_data (val_array_i (sources, i)); + data[i] = reinterpret_cast (val_data (val_array_i (sources, i))); } @@ -901,7 +901,7 @@ namespace lime { void lime_al_source_queue_buffers (value source, int nb, value buffers) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); if (val_is_null (buffers) == false) { @@ -910,7 +910,7 @@ namespace lime { for (int i = 0; i < size; ++i) { - data[i] = (ALuint)val_data (val_array_i (buffers, i)); + data[i] = reinterpret_cast (val_data (val_array_i (buffers, i))); } @@ -924,7 +924,7 @@ namespace lime { void lime_al_source_rewind (value source) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); alSourceRewind (id); } @@ -939,7 +939,7 @@ namespace lime { for (int i = 0; i < size; ++i) { - data[i] = (ALuint)val_data (val_array_i (sources, i)); + data[i] = reinterpret_cast (val_data (val_array_i (sources, i))); } @@ -953,7 +953,7 @@ namespace lime { void lime_al_source_stop (value source) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); alSourceStop (id); } @@ -968,7 +968,7 @@ namespace lime { for (int i = 0; i < size; ++i) { - data[i] = (ALuint)val_data (val_array_i (sources, i)); + data[i] = reinterpret_cast (val_data (val_array_i (sources, i))); } @@ -982,7 +982,7 @@ namespace lime { value lime_al_source_unqueue_buffers (value source, int nb) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); ALuint* buffers = new ALuint[nb]; alSourceUnqueueBuffers (id, nb, buffers); @@ -1017,7 +1017,7 @@ namespace lime { void lime_al_source3f (value source, int param, float value1, float value2, float value3) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); alSource3f (id, param, value1, value2, value3); } @@ -1025,7 +1025,7 @@ namespace lime { void lime_al_source3i (value source, int param, int value1, int value2, int value3) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); alSource3i (id, param, value1, value2, value3); } @@ -1033,7 +1033,7 @@ namespace lime { void lime_al_sourcef (value source, int param, float value) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); alSourcef (id, param, value); } @@ -1041,7 +1041,7 @@ namespace lime { void lime_al_sourcefv (value source, int param, value values) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); if (val_is_null (values) == false) { @@ -1064,12 +1064,12 @@ namespace lime { void lime_al_sourcei (value source, int param, value val) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); ALuint data; if (param == AL_BUFFER) { - data = (ALuint)val_data (val); + data = reinterpret_cast (val_data (val)); } else { @@ -1084,7 +1084,7 @@ namespace lime { void lime_al_sourceiv (value source, int param, value values) { - ALuint id = (ALuint)val_data (source); + ALuint id = reinterpret_cast (val_data (source)); if (val_is_null (values) == false) {