Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Windows ! (n/t)

Author: Omid David Tabibi

Date: 09:43:03 02/08/04

Go up one level in this thread


On February 08, 2004 at 10:27:34, Jean Bouchat wrote:

>It seems to work! Thanks to Omid David Tabibi.
>
>We make the test with the following lines:
>
>PeekNamedPipe(stdin, stream, 256, &lpBytesRead, &lpTotalBytesAvail,
>&lpBytesLeftThisMessage);
>            if(lpTotalBytesAvail!=0)
>            {
>            	scanf("%s",stream);
>            	if (!strcmp(stream, "?"))
>               {
>               	quitter=1;
>               }
>            }
>
>dropped in the search loop that exits when "quitter"== 1.
>This seems very similar to your function ReadStdIn.
>However, PeekNamedPipe seems realy slow. We are thinking about calling the
>PeekNamedPipe function only every 100000(?) nodes. It will delay the answer of
>our program but we hope it is not a problem for winboard.

I call it once every 8192 nodes:

    if ((nodes & 8191) == 0)
        check_input();

>
>Jean



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.