[PATCH] Fix tools/al_info.py

34 views
Skip to first unread message

anatoly techtonik

unread,
Nov 3, 2011, 9:53:03 PM11/3/11
to pyglet...@googlegroups.com
I couldn't find any instructions how to send fixes, so I attach the patch here.

anatoly techtonik

unread,
Nov 3, 2011, 9:54:30 PM11/3/11
to pyglet...@googlegroups.com
# HG changeset patch
# User anatoly techtonik <tech...@gmail.com>
# Date 1320371114 -7200
# Node ID 625e1e19138909c406c7b26c6239dd70469b9cfd
# Parent  8de0d773df2fa19111fcb4282e27fb69468fbacb
Fix tools/al_info.py broken by 9fa43242c4a3

diff --git a/tools/al_info.py b/tools/al_info.py
--- a/tools/al_info.py
+++ b/tools/al_info.py
@@ -14,8 +14,8 @@
 import sys
 
 from pyglet.media.drivers import openal
-from pyglet.media.drivers.openal import lib_openal as al
-from pyglet.media.drivers.openal import lib_alc as alc
+from pyglet.media.drivers.openal import al
+from pyglet.media.drivers.openal import alc
 
 def split_nul_strings(s):
     # NUL-separated list of strings, double-NUL-terminated.
@@ -64,10 +64,10 @@
 
     if options.device:
         print 'Using device "%s"...' % options.device
-        openal.driver_init(options.device)
+        driver = openal.create_audio_driver(options.device)
     else:
         print 'Using default device...'
-        openal.driver_init()
+        driver = openal.create_audio_driver()
 
-    print 'OpenAL version %d.%d' % openal.get_version()
-    print 'Extensions:              %s' % ', '.join(openal.get_extensions())
+    print 'OpenAL version %d.%d' % driver.get_version()
+    print 'Extensions:              %s' % ', '.join(driver.get_extensions())

anatoly techtonik

unread,
Nov 3, 2011, 9:57:14 PM11/3/11
to pyglet...@googlegroups.com
Looks like Google Groups experience issues with attached files (An error (#339) occurred while communicating with the server.), so I've just posted it inline.

anatoly techtonik

unread,
Nov 4, 2011, 11:01:45 AM11/4/11
to pyglet...@googlegroups.com
Pushed to http://code.google.com/r/techtonik-fixes412/, so you call pull from there.

Andreas Schiefer

unread,
Nov 5, 2011, 3:33:13 AM11/5/11
to pyglet...@googlegroups.com
Another way to send patches (aside from this list) is to open an issue at http://code.google.com/p/pyglet/issues/list and attach your patch there.

I've testet your patch and it seems to work fine, so I've pushed it. Thanks for the patch!

anatoly techtonik

unread,
Nov 5, 2011, 7:13:13 AM11/5/11
to pyglet...@googlegroups.com
It will help to create a `Contributing` wiki page so that people know the preferred way.

Richard Jones

unread,
Nov 5, 2011, 5:14:07 PM11/5/11
to pyglet...@googlegroups.com
On 5 November 2011 22:13, anatoly techtonik <tech...@gmail.com> wrote:
> It will help to create a `Contributing` wiki page so that people know the
> preferred way.

I can add content to the website pretty easily. I know it's not ideal
having it only editable by me (well, and Alex if he wanted to ;-).


Richard

anatoly techtonik

unread,
Nov 7, 2011, 12:58:14 AM11/7/11
to pyglet...@googlegroups.com
I prefer wiki, but if site is version controlled - that will be good as well. =)
 
Reply all
Reply to author
Forward
0 new messages