[opendemo-devel] plan for OpenDemo editor
Status: Beta
Brought to you by:
girlich
From: Dr. U. G. <Uwe...@ph...> - 2003-11-26 21:18:35
|
Hello! I intend to increase OpenDemo usage a bit more. For this I'll write a very simple demo editor over the xmas holiday. The most important thing for such an editor is a preview window, where Q3A directly plays back, what I just edited (or where I moved the timeline slider). Thus we need to feed into the OpenDemo playback mode a continous stream of data calculated by another program. The idea is to use a named pipe instead of a plain file. But now the problems start: we can't rewind a named pipe and we don't know the amount of data at the start at all. I have no idea, if Q3A can even read from a named pipe, as it has no size to begin with. To check this out I committed today and yesterday a small change to switch off the ZLIB code (at compile time and at runtime). The runtime switch off already works. The compile time switch off is not tested yet. The next step is to remove optionally (with a new console variable) all tests on the file end (comparisons with stream->len). Thus odfread() may block but the external program will feed in always new data anyway. When these comparisons are gone, I'll try 'cat odfile.xml > pipe.odq3a' and let Q3A replay 'pipe.odq3a'. If it works, we can continue with the actual work of the editor. If it does not work, we can always fall back to native shared libraries and let the C library read from the named pipe. What is the state of named pipe support in Windows? Is there finally an equivalent of the standard >20 years old 'mkfifo' command? For reference, the whole idea is a direct replica of the interactive mode of the demcut program (part of the LMPC project). Quake1 had no problem reading from a named pipe (and I even wrote a PerlTk front-end for demcut back then). Let's hope the best. Bye, Uwe |