[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Ann: Pygame 1.8 SVN snapshot as Win32 installers



I'd be in favor of leaving SDL's current behavior (windib over
directX) unless we have a real compelling reason to do otherwise -
it's had 3 point releases since the change, and windib has continued
to improve while directX has not been used or developed. Also, I'm far
more interested in using a library that ensures compatibility and
correct functioning across a variety of computers than the most
performant one unless we are talking a really significant difference.

So is there a case where performance is significantly different? like
6 fps instead of 30?

On Jan 26, 2008 11:50 PM, René Dudfield <renesd@xxxxxxxxx> wrote:
> oh really?  Well, that's not good then.
>
> Maybe a patch to SDL is in order then.  It would do basically the same
> thing as my python code - except it would change the order of the
> drivers to try.
>
> Or maybe we can change that VideoBootStrap *bootstrap[] from python
> land... which would require no patch to SDL, and would be easier.
>
> It depends on the computer, but generally directx is faster.  I think
> mostly on older computers... but on new computers sometimes windib is
> faster.
>
>
>
>
>
> On Jan 27, 2008 10:03 AM, Brian Fisher <brian@xxxxxxxxxxxxxxxxxxx> wrote:
> > One bad thing about forcing it to directX is it would make it so that
> > if it couldn't initilize directx it wouldn't even try windib.
> >
> > So how big is the performance difference? does it affect performance
> > even  if you don't use HWSURFACE?
> >
> >
> > On Jan 26, 2008 10:49 PM, René Dudfield <renesd@xxxxxxxxx> wrote:
> > > I'm not sure how accurate the reasons are:
> > > "The "windib" video driver is the default now, to prevent problems
> > > with certain laptops, 64-bit Windows, and Windows Vista. The DirectX
> > > driver is still available, and can be selected by setting the
> > > environment variable SDL_VIDEODRIVER to "directx"."
> > >
> > > I know people running pygame with directx games on vista does not
> > > work.  eg solar wolf
> > > http://www.pygame.org/shredwheat/solarwolf/ uses an old pygame which
> > > used directx by default - and does not work on my brothers vista
> > > laptop.  So changing the default is a good idea... for newer versions
> > > of windows.
> > >
> > >
> > > Maybe we could do some trickery and select directx on win9x, win2k and
> > > on XP, and otherwise default to windib.
> > >
> > > As losing so much performance, and changing the input semantics
> > > slightly on older machines is just silly imho.
> > >
> > >
> > > # if the driver is not set on old windows then we set it.
> > > import os, platform
> > > if not os.environ.has_key("SDL_VIDEODRIVER"):
> > >     # check if win9x or win2k, or XP use directx by default, otherwise windib.
> > >     uname_details = platform.uname()
> > >
> > >     old_windows = (uname_details[0] == 'Windows' and (uname_details[2] in ["XP"]
> > >
> > >     or "98" in uname_details[2]or "Me" in uname_details[2]  or "95" in
> > > uname_details[2] or "2000" in uname_details[2]))
> > >     if old_windows:
> > >         os.environ["SDL_VIDEODRIVER"] = "directx"
> > >
> > >
> > >
> > >
> > >
> > > On Jan 27, 2008 9:17 AM, Brian Fisher <brian@xxxxxxxxxxxxxxxxxxx> wrote:
> > > > DirectX support is always compiled in on windows - however support
> > > > being enabled is different than it being the default backend. look at
> > > > SDL_video.c - SDL_VideoInit() implements the backend selection. It
> > > > works by using the first in the list if no specific one is specified.
> > > > You can see from the "static VideoBootStrap *bootstrap[] " list that
> > > > windib is just before directx in that list, which makes it the
> > > > default.
> > > >
> > > > To change the default you'd have to change the order of the list in
> > > > SDL, or set the environment variable to directX (if not set already)
> > > > before calling SDL_VideoInit.
> > > >
> > > >
> > > > On Jan 26, 2008 9:45 PM, Lenard Lindstrom <len-l@xxxxxxxxx> wrote:
> > > > > Funny. The first item in the SDL FAC* says, "SDL takes advantage of
> > > > > DirectX hardware acceleration when it is available, but falls back to
> > > > > the standard Win32 services if DirectX is not installed". And the SDL
> > > > > 1.2.12 configure script shows DirectX enabled by default. So it appears
> > > > > to have been re-activated (or their documentation is outdated). But I
> > > > > can always add a build flag to force DirectX support. SDL 1.2.13 is out
> > > > > so I should try building it anyway.
> > > > >
> > > > > Lenard
> > > > >
> > > > > * http://www.libsdl.org/faq.php?action=listentries&category=4#38
> > > > >
> > > > >
> > > > >
> > > > > Brian Fisher wrote:
> > > > > > The default was changed in SDL 1.2.10, and has been windib since.
> > > > > > http://libsdl.org/release/changes-1.2.html
> > > > > > ---------------------------------------------------------
> > > > > > "The "windib" video driver is the default now, to prevent problems
> > > > > > with certain laptops, 64-bit Windows, and Windows Vista. The DirectX
> > > > > > driver is still available, and can be selected by setting the
> > > > > > environment variable SDL_VIDEODRIVER to "directx"."
> > > > > >
> > > > > > On Jan 26, 2008 9:06 PM, Lenard Lindstrom <len-l@xxxxxxxxx> wrote:
> > > > > >
> > > > > >> Hi René,
> > > > > >>
> > > > > >> The SDL documentation says directx is the default. I don't know why
> > > > > >> windib was chosen instead for Pygame. I've been using the directx
> > > > > >> default since I started building SDL 1.2.12 myself. So I see no problem
> > > > > >> leaving it that way.
> > > > > >>
> > > > > >> Lenard
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >> René Dudfield wrote:
> > > > > >>
> > > > > >>> wonderful :)
> > > > > >>>
> > > > > >>> I gave it a bit of a test run on an old XP machine and it seems to go fine :)
> > > > > >>>
> > > > > >>> I ran a bunch of the example programs, and also a few pygame games
> > > > > >>> like solar wolf, and zanthor etc.
> > > > > >>>
> > > > > >>> What do you think about making the directx driver the default again?
> > > > > >>> Rather than windb?  I noticed both solar wolf and zanthor ran faster
> > > > > >>> on my machine with directx.
> > > > > >>>
> > > > > >>>
> > > > > >>>
> > > > > >>>
> > > > > >>
> > > > >
> > > > >
> > > > > --
> > > > >
> > > > > Lenard Lindstrom
> > > > > <len-l@xxxxxxxxx>
> > > > >
> > > > >
> > > >
> > >
> >
>