On Mon, 12 Mar 2001, Jos Hulzink wrote:
> I have not been able to look at the Galloc code yet (unable to reach
> site). But, my two dollarcents:
I can send you a tarball in private, if you want.
> On Sun, 11 Mar 2001, Christoph Egger wrote:
>
> > 1. Does X support hardware-buffers like z-, alpha-, stencil- or
> > texture-buffer? Or does X just support raw-buffers, which are either
> > emulated by the X-server or directly in VRAM?
>
> According to OpenGL specs, it must be possible to get individual buffers
> out of XFree 4.X. (OpenGL must be able to get them, why not GGI) Never
> actually tried anything like it, will try to find this out.
>
> IIRC, Xfree 3 is harder to do
I won't use anything special from XFree. Everything, that is special
to XFree belongs in the xf86-target.
X is a standard. So I want to use the standard-methods for the
X/Xlib-target.
> > 2. How can I check reliable, _if_ there is one more cursor available?
> > Or can I always assume, that there is one more available?
>
> AFAIK it is only available at allocation time: a BadAlloc RETVAL means
> unable to allocate cursor space. There is no HowMuchFreeSpaceLeft() call
> or something.
Wonderful! X breaks the app, when an error like this occurs! In other
words: It is impossible to write tolerant applications, when no more
cursor is available. One person can run it, while another can't!
Really wonderful!
> > 3. Should I use XCreateGlyphCursor() or XCreateFontCursor() to create
> > a cursor, that response to the keyboard instead to the mouse?
>
> Good point. In my first opinion, I'd say none of them. Use
> XCreatePixmapCursor() instead.
I already use XCreatePixmapCursor() for creating a cursor, which
response to the mouse. But it should be also possible to allocate
one, which responses to the keyboard or whatever else?
BTW: Does X support a Joysticks? If yes, how can I create a cursor
that responses to them?
> Why ? I can imagine games want their complete own implementation
> of a keyboard-cursor,
Yes, sure. But it must be allocated before you can give it a special
form. And the (de)allocation part is the job of libGAlloc.
> and with GlyphCursor they would be too limited in options.
>
> But the question was: Glyph or Font. I'd say Glyph then, eventually with a
> shape to char conversion system. Reason: greater flexability in font and
> colours. IMHO forcing the user to use the X Cursor font could never be the
> goal of a flexible lib like this.
OK.
> > 4. When a buffer is stored on disk, should I emulate MMIO -access by
> > using mmap() or should I use filedescriptors?
>
> Question not understood. I think a disk-buffer should be implemented like
>
> fd=fopen ('mydir/mybuf.fer');
> buf=mmap (...fd...);
>
> using a filedescriptor AND mmap
That is what I want to say with "emulation MMIO-access by using
mmap()". With "using _only_ filedescriptors" I mean something like
this:
fd = open("mydir/mybuf.fer", O_CREATE | O_TRUNC | O_RDWR,0600);
size = read(fd, buf, count);
...
size = write(fd, buf, count);
...
close(fd);
You see, what I mean?
CU,
Christoph Egger
E-Mail: [EMAIL PROTECTED]