Hey Nathan,
This is the output when i run said commands:
Python 2.7.3 (v2.7.3:70274d53c1dd, Apr 9 2012, 20:52:43)
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "help", "copyright", "credits" or "license" for more information.2012-12-07 14:52:34.051 Python[414:f07] ApplePersistenceIgnoreState: Existing state will not be touched. New state will be written to /var/folders/b6/wjplmbk94bd501nx2n40vzbr0000gn/T/org.python.python.savedState
>>> import pyglet
>>> print(pyglet.version)
1.2alpha1
>>> print(pyglet.media.have_avbin)
Unexpected error loading library /usr/local/lib/libavbin.dylib: dlopen(/usr/local/lib/libavbin.dylib, 6): no suitable image found. Did find:
/usr/local/lib/libavbin.dylib: no matching architecture in universal wrapper
Traceback (most recent call last):File "<stdin>", line 1, in <module>
File "pyglet/__init__.py", line 338, in __getattr__
__import__(import_name)
File "pyglet/media/__init__.py", line 1469, in <module>
import avbin
File "pyglet/media/avbin.py", line 64, in <module>
darwin='/usr/local/lib/libavbin.dylib')
File "pyglet/lib.py", line 111, in load_library
lib = ctypes.cdll.LoadLibrary(name)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ctypes/__init__.py", line 443, in LoadLibrary
return self._dlltype(name)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ctypes/__init__.py", line 365, in __init__
self._handle = _dlopen(self._name, mode)
OSError: dlopen(/usr/local/lib/libavbin.dylib, 6): no suitable image found. Did find:
/usr/local/lib/libavbin.dylib: no matching architecture in universal wrapper
>>> print(pyglet.media.avbin.get_version())
Unexpected error loading library /usr/local/lib/libavbin.dylib: dlopen(/usr/local/lib/libavbin.dylib, 6): no suitable image found. Did find:
/usr/local/lib/libavbin.dylib: no matching architecture in universal wrapper
Traceback (most recent call last):File "<stdin>", line 1, in <module>
File "pyglet/__init__.py", line 338, in __getattr__
__import__(import_name)
File "pyglet/media/__init__.py", line 1469, in <module>
import avbin
File "pyglet/media/avbin.py", line 64, in <module>
darwin='/usr/local/lib/libavbin.dylib')
File "pyglet/lib.py", line 111, in load_library
lib = ctypes.cdll.LoadLibrary(name)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ctypes/__init__.py", line 443, in LoadLibrary
return self._dlltype(name)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ctypes/__init__.py", line 365, in __init__
self._handle = _dlopen(self._name, mode)
OSError: dlopen(/usr/local/lib/libavbin.dylib, 6): no suitable image found. Did find:
/usr/local/lib/libavbin.dylib: no matching architecture in universal wrapper
>>>
Any idea what's happening?
Thanks
Pepijn
________________________________________
From: pyglet...@googlegroups.com [pyglet...@googlegroups.com] On Behalf Of Nathan [nathan...@gmail.com]
Sent: Friday, December 07, 2012 9:58 AM
On Thu, Dec 6, 2012 at 4:39 PM, pepijn <pep...@boltcreative.com<mailto:pep...@boltcreative.com>> wrote:
Hey Nathan/all,
Thanks for outlining these steps. Unfortunately i'm still getting the same quick time errors as Steve Willis above. I had previously installed Pyglet 1.1.4 through pyglet.org... Maybe i should've uninstalled that one before i followed your steps. Not sure how to uninstall though. I looked through their documentation but they only tell you how to install. Anyone any ideas?
Lets check to see if everything got upgraded like you expected. Try running python, and then running the following commands:
import pyglet
print(pyglet.version)
print(pyglet.media.have_avbin)
print(pyglet.media.avbin.get_version())
For example, on one of my machines it looks like this:
$ python
Python 2.7.2 (default, Jun 20 2012, 16:23:33)
[GCC 4.2.1 Compatible Apple Clang 4.0 (tags/Apple/clang-418.0.60)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import pyglet
>>> print(pyglet.version)
1.2alpha1
>>> print(pyglet.media.have_avbin)
True
>>> print(pyglet.media.avbin.get_version())
11
Also, can i use the stock python that comes with os x 10.8?
You can if you install the development version of pyglet from the mercurial repository.
Thanks for all the help here in any case!
I hope this helps. :-)
~ Nathan
--
You received this message because you are subscribed to the Google Groups "pyglet-users" group.
To post to this group, send email to pyglet...@googlegroups.com.
To unsubscribe from this group, send email to pyglet-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/pyglet-users?hl=en.
--
You received this message because you are subscribed to the Google Groups "pyglet-users" group.
To post to this group, send email to pyglet...@googlegroups.com.
To unsubscribe from this group, send email to pyglet-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/pyglet-users?hl=en.
Group: http://groups.google.com/group/pyglet-users/topics
- Pepijn's Problem [1 Update]
- pyglet on Mac OS Mountain Lion? [7 Updates]
- Proposed Patch: Drag and Drop support for Windows [2 Updates]
- Can I open a pyglet window without the window taking focus? [1 Update]
- (0,0) at top left mode for 2D graphics [2 Updates]
Nathan <nathan...@gmail.com> Dec 07 11:31PM -0700
Pepijn,
I started a new email thread to help you debug this problem (so it won't
sort together with the other thread).
It looks like you need to install a newer version of AVbin. Either try the
last release (version 10):
https://github.com/downloads/AVbin/AVbin/AVbin10.pkg
...or the latest prerelease (which may work better):
https://github.com/downloads/AVbin/AVbin/AVbin11alpha4.pkg
Try installing one of those and then run the commands again.
~ Nathan
Nathan <nathan...@gmail.com> Dec 07 10:58AM -0700
Steve Willis <steve....@gmail.com> Dec 07 10:28AM -0800
I am using the latest development Pyglet from the mercurial repository on
OSX 10.8 without issue, aside from the need to suppress the Application
State file as described previously. I haven't run any tests outside of my
own project, but it seems to be very stable thus far.
Steve
On Friday, December 7, 2012 10:58:41 AM UTC-7, Nathan wrote:Nathan <nathan...@gmail.com> Dec 07 11:49AM -0700
> State file as described previously. I haven't run any tests outside of my
> own project, but it seems to be very stable thus far.
> Steve
That is so weird that you have to suppress the creation of the "~/Library/Saved
Application State/org.python.python.savedState" directory. That directory
exists on all my 10.8 installations, but has never caused a problem.
Does the problem occur even if you do a basic "hello world" pyglet app?
~ NathanSteve Willis <steve....@gmail.com> Dec 07 11:20AM -0800
Yes. In fact, I am very new to Pyglet, and initially encountered this issue
when trying the first "Hello, World" example in the Pyglet documentation.
The development version runs without error and the Python process is
running, but no window appears. After suppressing the creation of the
org.python.python.savedState file, everything has gone smoothly.
A little research tells me that this file, and the many others like it, are
part of the feature which can be configured with the "Close windows when
quitting an application" checkbox found in System Preferences | General. In
my case, checking this box did not solve the problem by itself, but the
file is related to this feature allowing for OSX to restore the window
state and open documents within for compliant applications.
I have also observed that this file is not created immediately in all
cases. Before suppressing the creation of the file by locking permissions
on the Application State folder (disabling this feature for all other
applications as well), I tried manually deleting it while developing a
simple test application. In some cases, it was several minutes before the
file was created. In some cases I could even launch my application again
after its creation, but not consistently. The only method that has proved
reliable is to avoid creating the file in the first place.
One final tidbit: I also tried simply checking for the existence of this
file and deleting it when found as the first task in my Python script. This
did not work. As a result, I suspect that the file is created at the time
Pyglet is initialized on import, and not necessarily at the time a window
is actually displayed.
Steve
On Friday, December 7, 2012 11:49:39 AM UTC-7, Nathan wrote:Phillip Nguyen <evil.p...@gmail.com> Dec 07 02:50PM -0600
Wow, thanks! With this information I found the ApplePersistenceIgnoreState key, and I've committed a fix that should prevent the org.python.python.savedState file from ever being created or used. This fixes the problem of new windows not being displayed after finishLaunching got called. It also explains why the problem was only showing up with certain builds of python and not pypy. There is an Xcode build setting that can be checked to prevent automatic state restoration for the application and I'm guessing the python from python.org doesn't have this set.
When you run a pyglet program from the terminal, there is a warning message saying that it won't be saving or restoring state. But I think I can live with that.
--phillip
Pepijn Gooiker <pep...@boltcreative.com> Dec 07 04:54PM -0600
Nathan <nathan...@gmail.com> Dec 07 11:26PM -0700
Awesome! Thanks for fixing that, Phillip.
~ Nathan
Nathan <nathan...@gmail.com> Dec 07 11:11AM -0700
I'd welcome the feature. I don't yet know enough Cocoa to figure out how
to implement it myself, though.
~ Nathan
Richard Jones <r1char...@gmail.com> Dec 08 09:33AM +1100
I recall implementing it for Carbon but I don't have the experience with
Cocoa at this point.
Sent from my portable device, please excuse the brevity.Nathan <nathan...@gmail.com> Dec 07 11:09AM -0700
I would guess it should be possible assuming Windows 7 allows opening a
window in the background. That's OS-specific behavior, obviously. I
personally know very little about programming on MS Windows windowing
systems.
~ Nathan
anatoly techtonik <tech...@gmail.com> Dec 07 06:03AM -0800
I've noticed that pyglet uses bottom left corner as (0,0) origin. This
creates problems with code ported from pygame, processing and other
applications from 2D graphics world where things are traditionally drawn
from top to bottom.
Is it possible to define a pyglet mode, where Y axes starts from the top?Anonymouse <anonymo...@gmail.com> Dec 07 05:09PM +0100
It is possible to make your own on_resize function that uses the top-right
corner as the origin - it's simply a matter of OpenGL projection matrix.
You'll want something like this...
@window.event
def on_resize(width, height):
glViewport(0, 0, width, height)
glMatrixMode(GL_PROJECTION)
glLoadIdentity()
glOrtho(0, width, height, 0, 0.1, 1000)
Not tested but I think it should be right.
You received this message because you are subscribed to the Google Group pyglet-users.
You can post via email.
To unsubscribe from this group, send an empty message.
For more options, visit this group.
--
You received this message because you are subscribed to the Google Groups "pyglet-users" group.
To post to this group, send email to pyglet...@googlegroups.com.
To unsubscribe from this group, send email to pyglet-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/pyglet-users?hl=en.
- Pepijn's Problem [2 Updates]
George Wright <geor...@bigpond.net.au> Dec 11 06:59AM +1100
On 08/12/2012, at 9:03 PM, pyglet...@googlegroups.com wrote:
> To post to this group, send email to pyglet...@googlegroups.com.
> To unsubscribe from this group, send email to pyglet-users...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/pyglet-users?hl=en.
George Wright
geor...@bigpond.net.au
Nathan <nathan...@gmail.com> Dec 10 09:53PM -0700
What's the output of "ls -l /usr/local/lib"?
~ Nathan
You received this message because you are subscribed to the Google Group pyglet-users.
You can post via email.
To unsubscribe from this group, send an empty message.
For more options, visit this group.
--
You received this message because you are subscribed to the Google Groups "pyglet-users" group.
To post to this group, send email to pyglet...@googlegroups.com.
To unsubscribe from this group, send email to pyglet-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/pyglet-users?hl=en.