Re: GLU Tesselator

New Message Reply Date view Thread view Subject view Author view

From: Dirk Scheffter (scheff++at++appss.de)
Date: 03/27/2002 05:29:50


Hi Sakis,

I'm sure GLUtesselator is not allocated in shared memory.
Thus, the DRAW process receives the correct pointer in PassData
but the DRAW process cannot "see" something senseful at this address
because GLUtesselator is allocated in unshared memory of APP process!

It should be difficult to allocate GLUtesselator in shared memory.
May be, somebody knows how to do this. I guess it's rather
impossible without re-implementing GLU. ;-)

OK, how to solve this problem:

1st try: Create the GLUtesselator before pfConfig (where the forks of
CULL, DRAW etc. happen). When pfConfig is called each process gets an
identical copy at the same address. Now, the DRAW callback will see the
correct contents at the given address.

But this is not so clever as it seems because you cannot set any
GLUtessalator property in APP process. (Remember, DRAW process has its own
copy which will not note any changing in APP process, due to fork.)

2nd try: Create the GLUtesselator directly in your DRAW callback when
it's entered first time. Pass changings of the properties by your own
"protocol" from APP to DRAW using PassData.

This solution I would prefer. So, there is left only one problem: How to
request properties of GLUtesselator in APP process.

(If this is not necessary you can skip the rest of this mail.)

To do this, you need an extension of your "protocol":
APP process sends a property request through PassData/shared memory and
continues its other work. (Shoot and forget.)
A few frames later DRAW will receive the request, will read the property
out of its GLUtesselator instance, and and will store the answer in
something like an event queue.
APP will receive the earlier requested data when it checks the
event queue next time.
The only problem of this solution: This may have a certain impact on your
application concept and cause a greater amount of re-implementation.

Any comments?

Hope, this helped a little bit...

Greetings,
Dirk.

====================================================================
Dirk Scheffter

applied software solutions (appss) GmbH
Sandtorstr. 23
D-39106 Magdeburg

Phone: +49-(0)391-54486-19387
Fax: +49-(0)391-54486-19222
E-mail: scheffter++at++appss.de
URL: http://www.appss.de

This e-mail may contain confidential and/or privileged information.
If you are not the intended recipient (or have received this e-mail
in error) please notify the sender immediately and destroy this
e-mail. Any unauthorised copying, disclosure or distribution of the
material in this e-mail is strictly forbidden.
===================================================================


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Wed Mar 27 2002 - 04:29:57 PST

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.