Path: utzoo!attcan!uunet!husc6!think!ames!oliveb!cygnet!daisy!klee From: klee@daisy.UUCP (Ken Lee) Newsgroups: comp.windows.x Subject: Re: X Toolkit and continuous graphic output Message-ID: <1429@daisy.UUCP> Date: 25 Jul 88 17:31:43 GMT References: <8807240059.AA13157@violet.berkeley.edu> Reply-To: klee@daisy.UUCP (Ken Lee) Organization: Daisy Systems Corp., Mountain View, Ca. Lines: 26 In article <8807240059.AA13157@violet.berkeley.edu> rusty@VIOLET.BERKELEY.EDU writes: >Suppose I have a program that continuously computes and generates >graphic output; how can I wrap the toolkit around this program? It >seems to me that once I call XtMainLoop() I've given up control and >there's no way for me to get to the main routine of my program that >generates the output. Here are 2 simple ideas. There are probably more complex ones for Xt hackers. 1. Explicit dispatching: have your graphics output module control the program, but, every once in a while, call XtDispatchEvent() to handle input. 2. 2 processes: put your output module in a process separate from your Xt widget/input handler. Communicate with sockets or pipes. Let UNIX scheduling worry about the who's running when. Ken -- uucp: {ames!atari, ucbvax!imagen, nsc, pyramid, uunet}!daisy!klee arpanet: atari!daisy!klee@ames.arc.nasa.gov Don't applaud, just throw money.