Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Interrupting pondering/thinking in Win32 console apps

Author: Robert Hyatt

Date: 19:07:13 08/02/99

Go up one level in this thread


On August 02, 1999 at 21:39:37, David L. Wyatt wrote:

>When implementing a chess engine, what's the most efficient way to go about
>checking for input while searching?
>
>Another related question is, how might I go about checking on what is in stdin's
>buffer without actually waiting for input, assuming it's empty or the user
>hasn't entered a newline yet.
>
>Thanks,
>Dave Wyatt
>davew@chess.net


For windows, PeekNamedPipe(). For unix, select().

But by all means, read the xboard engine-intf.txt document, as it explains
the C library buffering issue that gets everyone...



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.