diff options
author | Joerg Mueller <nexyon@gmail.com> | 2010-07-31 14:03:08 +0400 |
---|---|---|
committer | Joerg Mueller <nexyon@gmail.com> | 2010-07-31 14:03:08 +0400 |
commit | 5c9cf81cf98c99e52064b0cd45be3b2eaba9e40c (patch) | |
tree | 463240a84d34a3debf5bba9c326827fb436db703 /intern/audaspace/Python/AUD_PyAPI.cpp | |
parent | 61c9e46aad2cf679331341c7d38f10bec19203a9 (diff) |
Audaspace:
* Fixed some compiler warnings
* Implemented device looping
* Note: Scrubbing in the sequencer is broken atm
Diffstat (limited to 'intern/audaspace/Python/AUD_PyAPI.cpp')
-rw-r--r-- | intern/audaspace/Python/AUD_PyAPI.cpp | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/intern/audaspace/Python/AUD_PyAPI.cpp b/intern/audaspace/Python/AUD_PyAPI.cpp index 13617283a1e..dff7334e577 100644 --- a/intern/audaspace/Python/AUD_PyAPI.cpp +++ b/intern/audaspace/Python/AUD_PyAPI.cpp @@ -1228,8 +1228,7 @@ Handle_get_loop_count(Handle *self, void* nothing) try { - // AUD_XXX will come soon; return Py_BuildValue("f", device->device->getPitch(self->handle)); - AUD_THROW(AUD_ERROR_FACTORY); + return Py_BuildValue("i", device->device->getLoopCount(self->handle)); } catch(AUD_Exception&) { @@ -1250,14 +1249,8 @@ Handle_set_loop_count(Handle *self, PyObject* args, void* nothing) try { - /* AUD_XXX Doesn't work atm, will come back - AUD_Message message; - message.loopcount = loops; - message.type = AUD_MSG_LOOP; - if(device->device->sendMessage(self->handle, message)) - { + if(device->device->setLoopCount(self->handle, loops)) return 0; - }*/ } catch(AUD_Exception&) { @@ -1302,7 +1295,7 @@ Handle_set_location(Handle *self, PyObject* args, void* nothing) float x, y, z; if(!PyArg_Parse(args, "(fff)", &x, &y, &z)) - return NULL; + return -1; Device* dev = (Device*)self->device; @@ -1361,7 +1354,7 @@ Handle_set_velocity(Handle *self, PyObject* args, void* nothing) float x, y, z; if(!PyArg_Parse(args, "(fff)", &x, &y, &z)) - return NULL; + return -1; Device* dev = (Device*)self->device; @@ -1420,7 +1413,7 @@ Handle_set_orientation(Handle *self, PyObject* args, void* nothing) float w, x, y, z; if(!PyArg_Parse(args, "(ffff)", &w, &x, &y, &z)) - return NULL; + return -1; Device* dev = (Device*)self->device; @@ -2368,7 +2361,7 @@ Device_set_listener_location(Device *self, PyObject* args, void* nothing) float x, y, z; if(!PyArg_Parse(args, "(fff)", &x, &y, &z)) - return NULL; + return -1; try { @@ -2423,7 +2416,7 @@ Device_set_listener_velocity(Device *self, PyObject* args, void* nothing) float x, y, z; if(!PyArg_Parse(args, "(fff)", &x, &y, &z)) - return NULL; + return -1; try { @@ -2478,7 +2471,7 @@ Device_set_listener_orientation(Device *self, PyObject* args, void* nothing) float w, x, y, z; if(!PyArg_Parse(args, "(ffff)", &w, &x, &y, &z)) - return NULL; + return -1; try { |