Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Ezbez

Pages: [1]
1
Window / ConvertCoords not working as expected
« on: August 04, 2009, 11:40:20 pm »
Oh man. The instant I post I realize what the problem is. Just gotta change the call to sf.Circle to sf.Circle(0,0, 8, sf.Color.White). Not a problem with ConvertCoords at all!

2
Window / ConvertCoords not working as expected
« on: August 04, 2009, 11:37:43 pm »
I'm trying to place a circle at the mouse coordinates. I read in the mouse coordinates and pass them through RenderWindow::ConvertCoords(), and yet my results aren't what I expect. The circle is drawn a constant 1/2 width and 1/2 height down and to the right of the mouse. It does the same if I don't use the ConvertCoords. Here's the code (in PySFML):

Code: [Select]
from PySFML import sf

window = sf.RenderWindow( sf.VideoMode(800,600), "SFML Program" )
input = window.GetInput()

playerGfx = sf.Shape.Circle(400,300, 8, sf.Color.White)

running = True
while running:
event = sf.Event()
while( window.GetEvent(event) ):
if ( event.Type == sf.Event.Closed ):
running = False

mPos = window.ConvertCoords( input.GetMouseX(), input.GetMouseY() )

window.Clear()

playerGfx.SetPosition(mPos[0], mPos[1])
window.Draw( playerGfx )

window.Display()

window.Close()


Am I misunderstanding ConvertCoords or is it misbehaving?

3
Python / Having trouble getting PySFML to work
« on: July 05, 2009, 12:39:22 pm »
As an alternative, I wrote an installation guide for PySFML on the wiki. It says how to compile the SDK. I wrote it for 1.4, but it works analogously for 1.5! I'm not sure if it works for Python 3.0 or 2.5 - I've only tested on 2.6. (Feel free to confirm it for other Python versions and edit the wiki accordingly!)

4
Python / Installing PySFML on Python26
« on: May 25, 2009, 12:54:36 pm »
Alright, I posted the instructions!

5
Python / Installing PySFML on Python26
« on: May 24, 2009, 03:56:28 pm »
Thanks a bunch! It works now.

If you and Laurent would like, I can write up all the steps I had to go through as a complete VC++ 2008 installation guide. Seems like the least I could do after you two helped me so much.

6
Python / Installing PySFML on Python26
« on: May 24, 2009, 03:13:26 pm »
Arg - so close! I added SFML_DYNAMIC to setup.py and now it looks like it builds fine. I install it after that, but then I get this error:

Code: [Select]
>>> import PySFML
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "PySFML\__init__.py", line 1, in <module>
    import sf
ImportError: DLL load failed: The specified module could not be found.


I get exactly the same error when I use remi's already compiled distribution.

Here's the log from building it
Code: [Select]
C:\Documents and Settings\Owner\Desktop\SFML-1.4\python>python26 setup.py build
running build
running build_py
running build_ext
building 'PySFML.sf' extension
creating build\temp.win32-2.6
creating build\temp.win32-2.6\Release
creating build\temp.win32-2.6\Release\src
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Clock.cpp /Fobuild\temp.win32-
2.6\Release\src/Clock.obj
Clock.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Color.cpp /Fobuild\temp.win32-
2.6\Release\src/Color.obj
Color.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Drawable.cpp /Fobuild\temp.win
32-2.6\Release\src/Drawable.obj
Drawable.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/Drawable.cpp(73) : warning C4244: 'argument' : conversion from 'double' to 'float', possible los
s of data
src/Drawable.cpp(79) : warning C4244: 'argument' : conversion from 'double' to 'float', possible los
s of data
src/Drawable.cpp(94) : warning C4244: 'argument' : conversion from 'double' to 'float', possible los
s of data
src/Drawable.cpp(100) : warning C4244: 'argument' : conversion from 'double' to 'float', possible lo
ss of data
src/Drawable.cpp(107) : warning C4244: 'argument' : conversion from 'double' to 'float', possible lo
ss of data
src/Drawable.cpp(183) : warning C4244: 'argument' : conversion from 'double' to 'float', possible lo
ss of data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Event.cpp /Fobuild\temp.win32-
2.6\Release\src/Event.obj
Event.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Image.cpp /Fobuild\temp.win32-
2.6\Release\src/Image.obj
Image.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Input.cpp /Fobuild\temp.win32-
2.6\Release\src/Input.obj
Input.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Key.cpp /Fobuild\temp.win32-2.
6\Release\src/Key.obj
Key.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/main.cpp /Fobuild\temp.win32-2
.6\Release\src/main.obj
main.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Music.cpp /Fobuild\temp.win32-
2.6\Release\src/Music.obj
Music.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/PostFX.cpp /Fobuild\temp.win32
-2.6\Release\src/PostFX.obj
PostFX.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Rect.cpp /Fobuild\temp.win32-2
.6\Release\src/Rect.obj
Rect.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/RenderWindow.cpp /Fobuild\temp
.win32-2.6\Release\src/RenderWindow.obj
RenderWindow.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Sleep.cpp /Fobuild\temp.win32-
2.6\Release\src/Sleep.obj
Sleep.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/Sleep.cpp(30) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss o
f data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Sprite.cpp /Fobuild\temp.win32
-2.6\Release\src/Sprite.obj
Sprite.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/String.cpp /Fobuild\temp.win32
-2.6\Release\src/String.obj
String.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/String.cpp(132) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss
 of data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/VideoMode.cpp /Fobuild\temp.wi
n32-2.6\Release\src/VideoMode.obj
VideoMode.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/View.cpp /Fobuild\temp.win32-2
.6\Release\src/View.obj
View.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/View.cpp(130) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss o
f data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Window.cpp /Fobuild\temp.win32
-2.6\Release\src/Window.obj
Window.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/Window.cpp(327) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss
 of data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Joy.cpp /Fobuild\temp.win32-2.
6\Release\src/Joy.obj
Joy.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Mouse.cpp /Fobuild\temp.win32-
2.6\Release\src/Mouse.obj
Mouse.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/WindowStyle.cpp /Fobuild\temp.
win32-2.6\Release\src/WindowStyle.obj
WindowStyle.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Blend.cpp /Fobuild\temp.win32-
2.6\Release\src/Blend.obj
Blend.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Sound.cpp /Fobuild\temp.win32-
2.6\Release\src/Sound.obj
Sound.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/Sound.cpp(85) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss o
f data
src/Sound.cpp(92) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss o
f data
src/Sound.cpp(99) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss o
f data
src/Sound.cpp(106) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss
of data
src/Sound.cpp(207) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss
of data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/SoundBuffer.cpp /Fobuild\temp.
win32-2.6\Release\src/SoundBuffer.obj
SoundBuffer.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Listener.cpp /Fobuild\temp.win
32-2.6\Release\src/Listener.obj
Listener.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/Listener.cpp(64) : warning C4244: 'argument' : conversion from 'double' to 'float', possible los
s of data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/SoundRecorder.cpp /Fobuild\tem
p.win32-2.6\Release\src/SoundRecorder.obj
SoundRecorder.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/SoundBufferRecorder.cpp /Fobui
ld\temp.win32-2.6\Release\src/SoundBufferRecorder.obj
SoundBufferRecorder.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/SoundStream.cpp /Fobuild\temp.
win32-2.6\Release\src/SoundStream.obj
SoundStream.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/SoundStream.cpp(127) : warning C4244: 'argument' : conversion from 'double' to 'float', possible
 loss of data
src/SoundStream.cpp(134) : warning C4244: 'argument' : conversion from 'double' to 'float', possible
 loss of data
src/SoundStream.cpp(141) : warning C4244: 'argument' : conversion from 'double' to 'float', possible
 loss of data
src/SoundStream.cpp(148) : warning C4244: 'argument' : conversion from 'double' to 'float', possible
 loss of data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Font.cpp /Fobuild\temp.win32-2
.6\Release\src/Font.obj
Font.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Glyph.cpp /Fobuild\temp.win32-
2.6\Release\src/Glyph.obj
Glyph.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/Shape.cpp /Fobuild\temp.win32-
2.6\Release\src/Shape.obj
Shape.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
src/Shape.cpp(103) : warning C4244: 'argument' : conversion from 'double' to 'float', possible loss
of data
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DSF
ML_DYNAMIC -I../include -IC:\Python26\include -IC:\Python26\PC /Tpsrc/WindowSettings.cpp /Fobuild\te
mp.win32-2.6\Release\src/WindowSettings.obj
WindowSettings.cpp
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\xlocale(342) : warning C4530: C++ exception
handler used, but unwind semantics are not enabled. Specify /EHsc
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\link.exe /DLL /nologo /INCREMENTAL:NO /LIBPATH:.
./lib/vc2008 /LIBPATH:C:\Python26\libs /LIBPATH:C:\Python26\PCbuild sfml-graphics.lib sfml-window.li
b sfml-audio.lib sfml-system.lib /EXPORT:initsf build\temp.win32-2.6\Release\src/Clock.obj build\tem
p.win32-2.6\Release\src/Color.obj build\temp.win32-2.6\Release\src/Drawable.obj build\temp.win32-2.6
\Release\src/Event.obj build\temp.win32-2.6\Release\src/Image.obj build\temp.win32-2.6\Release\src/I
nput.obj build\temp.win32-2.6\Release\src/Key.obj build\temp.win32-2.6\Release\src/main.obj build\te
mp.win32-2.6\Release\src/Music.obj build\temp.win32-2.6\Release\src/PostFX.obj build\temp.win32-2.6\
Release\src/Rect.obj build\temp.win32-2.6\Release\src/RenderWindow.obj build\temp.win32-2.6\Release\
src/Sleep.obj build\temp.win32-2.6\Release\src/Sprite.obj build\temp.win32-2.6\Release\src/String.ob
j build\temp.win32-2.6\Release\src/VideoMode.obj build\temp.win32-2.6\Release\src/View.obj build\tem
p.win32-2.6\Release\src/Window.obj build\temp.win32-2.6\Release\src/Joy.obj build\temp.win32-2.6\Rel
ease\src/Mouse.obj build\temp.win32-2.6\Release\src/WindowStyle.obj build\temp.win32-2.6\Release\src
/Blend.obj build\temp.win32-2.6\Release\src/Sound.obj build\temp.win32-2.6\Release\src/SoundBuffer.o
bj build\temp.win32-2.6\Release\src/Listener.obj build\temp.win32-2.6\Release\src/SoundRecorder.obj
build\temp.win32-2.6\Release\src/SoundBufferRecorder.obj build\temp.win32-2.6\Release\src/SoundStrea
m.obj build\temp.win32-2.6\Release\src/Font.obj build\temp.win32-2.6\Release\src/Glyph.obj build\tem
p.win32-2.6\Release\src/Shape.obj build\temp.win32-2.6\Release\src/WindowSettings.obj /OUT:build\lib
.win32-2.6\PySFML\sf.pyd /IMPLIB:build\temp.win32-2.6\Release\src\sf.lib /MANIFESTFILE:build\temp.wi
n32-2.6\Release\src\sf.pyd.manifest
   Creating library build\temp.win32-2.6\Release\src\sf.lib and object build\temp.win32-2.6\Release\
src\sf.exp
C:\Program Files\Microsoft SDKs\Windows\v6.0A\bin\mt.exe -nologo -manifest build\temp.win32-2.6\Rele
ase\src\sf.pyd.manifest -outputresource:build\lib.win32-2.6\PySFML\sf.pyd;2

C:\Documents and Settings\Owner\Desktop\SFML-1.4\python>


Here's the log from installing it:
Code: [Select]
C:\Documents and Settings\Owner\Desktop\SFML-1.4\python>python26 setup.py install
running install
running build
running build_py
running build_ext
running install_lib
creating C:\Python26\Lib\site-packages\PySFML
copying build\lib.win32-2.6\PySFML\sf.pyd -> C:\Python26\Lib\site-packages\PySFML
copying build\lib.win32-2.6\PySFML\__init__.py -> C:\Python26\Lib\site-packages\PySFML
copying build\lib.win32-2.6\PySFML\__init__.pyc -> C:\Python26\Lib\site-packages\PySFML
running install_egg_info
Writing C:\Python26\Lib\site-packages\PySFML-1.4-py2.6.egg-info


And here's setup.py:

Code: [Select]
#!/usr/bin/env python
# coding=UTF-8

from distutils.core import setup, Extension

setup(name='PySFML',
version='1.4',
description='Python binding for SFML (Simple and Fast Multimedia Library)',
author='Rémi Koenig',
author_email='remi.k2620@gmail.com',
url='http://www.sfml-dev.org/',
license='zlib/png',
ext_modules=[ Extension('PySFML.sf', \
['src/Clock.cpp', 'src/Color.cpp', 'src/Drawable.cpp', \
'src/Event.cpp', 'src/Image.cpp', 'src/Input.cpp', 'src/Key.cpp', 'src/main.cpp', \
'src/Music.cpp', 'src/PostFX.cpp', 'src/Rect.cpp', 'src/RenderWindow.cpp', 'src/Sleep.cpp', \
'src/Sprite.cpp', 'src/String.cpp', 'src/VideoMode.cpp', 'src/View.cpp', 'src/Window.cpp', \
'src/Joy.cpp', 'src/Mouse.cpp', 'src/WindowStyle.cpp', 'src/Blend.cpp', 'src/Sound.cpp', \
'src/SoundBuffer.cpp', 'src/Listener.cpp', 'src/SoundRecorder.cpp', 'src/SoundBufferRecorder.cpp', \
'src/SoundStream.cpp', 'src/Font.cpp', 'src/Glyph.cpp', 'src/Shape.cpp', 'src/WindowSettings.cpp' ], \
libraries=['sfml-graphics', 'sfml-window', 'sfml-audio', 'sfml-system'], \
library_dirs=['../lib/vc2008'], \
include_dirs=['../include'],
define_macros=[('SFML_DYNAMIC',None)]
)],
package_dir = {'PySFML':'PySFML'},
packages=['PySFML'],
)

7
Python / Installing PySFML on Python26
« on: May 24, 2009, 02:20:24 am »
A shame. :( I'll do my best to poke around and try to find out a work-around or solution, but if you can't tell from my previous posts, I'm not so hot at all this. Still, maybe I'll find something.

For the record, I'm using Windows XP SP2 and VC++ 2008 Express Edition.

8
Python / Installing PySFML on Python26
« on: May 22, 2009, 11:28:57 pm »
Thanks! that let it progress a little further. Now I'm getting this:

Code: [Select]
build\temp.win32-2.6\Release\src\sf.exp
Color.obj : error LNK2019: unresolved external symbol "public: static class sf::Color const sf::Color::Cyan" (?Cyan@Color@sf@@2V12@B) referenced in function "void __cdecl PySfColor_InitConst(void)" (?PySfColor_InitConst@@YAXXZ)
Color.obj : error LNK2019: unresolved external symbol "public: static class sf::Color const sf::Color::Magenta" (?Magenta@Color@sf@@2V12@B) referenced in function "void __cdecl PySfColor_InitConst(void)" (?PySfColor_InitConst@@YAXXZ)
Color.obj : error LNK2019: unresolved external symbol "public: static class sf::Color const sf::Color::Yellow" (?Yellow@Color@sf@@2V12@B) referenced in function "void __cdecl PySfColor_InitConst(void)" (?PySfColor_InitConst@@YAXXZ)
Color.obj : error LNK2019: unresolved external symbol "public: static class sf::Color const sf::Color::Blue" (?Blue@Color@sf@@2V12@B) referenced in function "void __cdecl PySfColor_InitConst(void)" (?PySfColor_InitConst@@YAXXZ)
Color.obj : error LNK2019: unresolved external symbol "public: static class sf::Color const sf::Color::Green" (?Green@Color@sf@@2V12@B) referenced in function "void __cdecl PySfColor_InitConst(void)" (?PySfColor_InitConst@@YAXXZ)
Color.obj : error LNK2019: unresolved external symbol "public: static class sf::Color const sf::Color::Red" (?Red@Color@sf@@2V12@B) referenced in function "void __cdecl PySfColor_InitConst(void)" (?PySfColor_InitConst@@YAXXZ)
Color.obj : error LNK2019: unresolved external symbol "public: static class sf::Color const sf::Color::White" (?White@Color@sf@@2V12@B) referenced in function "void __cdecl PySfColor_InitConst(void)" (?PySfColor_InitConst@@YAXXZ)
Color.obj : error LNK2019: unresolved external symbol "public: static class sf::Color const sf::Color::Black" (?Black@Color@sf@@2V12@B) referenced in function "void __cdecl PySfColor_InitConst(void)" (?PySfColor_InitConst@@YAXXZ)
Shape.obj : error LNK2001: unresolved external symbol "public: static class sf::Color const sf::Color::Black" (?Black@Color@sf@@2V12@B)
Font.obj : error LNK2019: unresolved external symbol "private: static unsigned int * sf::Font::ourDefaultCharset" (?ourDefaultCharset@Font@sf@@0PAIA) referenced in function "struct _object * __cdecl PySfFont_LoadFromFile(struct PySfFont *,struct _object *,struct _object *)" (?PySfFont_LoadFromFile@@YAPAU_object@@PAUPySfFont@@PAU1@1@Z)
build\lib.win32-2.6\PySFML\sf.pyd : fatal error LNK1120: 9 unresolved externals


I think it's safe to say that the tutorial instructions need some elaborating on. :)

9
Python / Installing PySFML on Python26
« on: May 22, 2009, 11:47:27 am »
Thanks for that! I now can successfully compile the libs, but there's an error in the linking stage. The full output is below:

Code: [Select]
running build
running build_py
running build_ext
building 'PySFML.sf' extension
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\link.exe /DLL /nologo /INCREMENTAL:NO /LIBPATH:../lib/mingw /LIBPATH:C:\Python26\libs /LIBPATH:C:\Python26\PCbuild sfml-graphics.lib sfml-window.lib sfml-audio.lib sfml-system.lib /EXPORT:initsf build\temp.win32-2.6\Release\src/Clock.obj build\temp.win32-2.6\Release\src/Color.obj build\temp.win32-2.6\Release\src/Drawable.obj build\temp.win32-2.6\Release\src/Event.obj build\temp.win32-2.6\Release\src/Image.obj build\temp.win32-2.6\Release\src/Input.obj build\temp.win32-2.6\Release\src/Key.obj build\temp.win32-2.6\Release\src/main.obj build\temp.win32-2.6\Release\src/Music.obj build\temp.win32-2.6\Release\src/PostFX.obj build\temp.win32-2.6\Release\src/Rect.obj build\temp.win32-2.6\Release\src/RenderWindow.obj build\temp.win32-2.6\Release\src/Sleep.obj build\temp.win32-2.6\Release\src/Sprite.obj build\temp.win32-2.6\Release\src/String.obj build\temp.win32-2.6\Release\src/VideoMode.obj build\temp.win32-2.6\Release\src/View.obj build\temp.win32-2.6\Release\src/Window.obj build\temp.win32-2.6\Release\src/Joy.obj build\temp.win32-2.6\Release\src/Mouse.obj build\temp.win32-2.6\Release\src/WindowStyle.obj build\temp.win32-2.6\Release\src/Blend.obj build\temp.win32-2.6\Release\src/Sound.obj build\temp.win32-2.6\Release\src/SoundBuffer.obj build\temp.win32-2.6\Release\src/Listener.obj build\temp.win32-2.6\Release\src/SoundRecorder.obj build\temp.win32-2.6\Release\src/SoundBufferRecorder.obj build\temp.win32-2.6\Release\src/SoundStream.obj build\temp.win32-2.6\Release\src/Font.obj build\temp.win32-2.6\Release\src/Glyph.obj build\temp.win32-2.6\Release\src/Shape.obj build\temp.win32-2.6\Release\src/WindowSettings.obj /OUT:build\lib.win32-2.6\PySFML\sf.pyd /IMPLIB:build\temp.win32-2.6\Release\src\sf.lib /MANIFESTFILE:build\temp.win32-2.6\Release\src\sf.pyd.manifest
LINK : fatal error LNK1181: cannot open input file 'sfml-graphics.lib'


I do see sfml-graphics.lib in SFML/Lib/vc2008/, so I'm not sure why it's complaining.

10
Python / Installing PySFML on Python26
« on: May 21, 2009, 10:54:33 pm »
A while back, I managed to install PySFML 1.3 onto Python25 and I'm very happy with it. Now I want to migrate onto SFML 1.4 and Python26, but I can't manage to install it.

I've followed the instructions given in the tutorial. Doing the development files install instructions seems to have no effect (that is, if I import PySFML, I am told there is no such module).

Following the SDK instructions, I don't understand this sentence:
Quote
If you want to build PySFML from the source code, you must have the SFML C++ headers and libraries in the SFML-x.x directory (as well as the "python" folder), and type the following command :


I take it this means I should download the "SFML full SDK" download. But now where exactly do I put it? I've tried extracting it and putting the contents into C:\python26\ (I'm using Windows XP). I've tried putting it in C:\python26\Lib\ and C:\python26\include\. I've put it in the PySFML-1.4 folder which I extracted and also within the PySFML-1.4/python/ directory.

All of these give me the same error:
": fatal error C1083: Cannot open include file: 'SFML/system/Clock.hpp': No such file or directory
error: command '"C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe"' failed with exit status 2"

Any help would be appreciated.

Edit: Oops, I should clarify something. When I say "putting the contents", "contents" is referring to the contents within an enclosing SFML/ folder.

Pages: [1]