[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: SDL backend
From: |
Fred Kiefer |
Subject: |
Re: SDL backend |
Date: |
Sat, 02 Jul 2005 14:51:03 +0200 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.7) Gecko/20050414 |
Christopher Armstrong wrote:
> Secondly, I have been wondering whether or not an SDL backend for
> gnustep has been considered. Is this considered feasible. I have been
> looking into this myself, but the interaction between GSGState and
> GSContext classes is something I've still to get my head around. I've
> been looking at it as a more proof of concept thing, but SDL is quite
> portable, and it may help the AppKit move to other platforms if
> desired.
>
Writing a GNUstep backend isn't that hard. The GSContext and GSGState
classes just make it easier, but if you don't like them, you don't have
to use them. The context class is the interface used by the GUI layer to
access drawing operations and the Gstate class provides the
functionality for one drawing entity.
The probably best place to start of to understand what is needed is the
windows backend. I wrote it with the specific intention to have very
simple sample backend for GNUstep. As you can see there, the context
class does almost nothing, as most operations get handled by the super
class GSContext. In Win32GState you find all the operations you need to
implement yourself and even some of them are already handled by the
super class. I put them there as a speed up, when there was a direct
windows equivalent for the operation. Even more methods could be pushed
up to the superclass. Maybe I should spend some time to rework this and
better integrate the ART backend into the rest of the backends. ART
could be another nice example but the current code structure does isn't
easy to understand.
If you have any more specific questions feel free to ask them on the
mailing list or directly.
Cheers
Fred
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: SDL backend,
Fred Kiefer <=