ImagerForkContextDoc.tioga
Lamming.pa, July 31, 1986
Last edited by: Mik Lamming - August 5, 1986 1:12:26 pm PDT
ImagerForkContext
CEDAR 6.1 — FOR INTERNAL XEROX USE ONLY
ImagerForkContext
ImagerForkContext
Mik Lamming
© Copyright 1986 Xerox Corporation. All rights reserved.
Abstract: An imager context that drives two others.
Created by: Lamming.pa
Maintained by: Mik Lamming <Lamming.pa>
Keywords: Imager
XEROX Xerox Corporation
Palo Alto Research Center
3333 Coyote Hill Road
Palo Alto, California 94304
For Internal Xerox Use Only
1. ImagerForkContext
This is a context that permits two other contexts to be driven in parallel using the same single calls sequence. For example you could use this package to output the same information to two viewers at the same time.
Here is a bit of interpreter script that shows how the RandomImager can be made to output to two viewers at the same time.
← &ca ← ImagerViewer.Create[[name: "Random Imager A", iconic: FALSE], pixels]
← &cb ← ImagerViewer.Create[[name: "Random Imager B", iconic: FALSE], pixels]
← &c ← ImagerForkContext.Create[&ca, &cb];
← RandomImagerImpl.Run[&c]
Now everyting output to &c will appear both in Viewer A and Viewer B.
Either or both child contexts can be disabled temporarily using the Activate call. e.g.
← Activate[contextAB: &c, a: TRUE, b: FALSE] -- turns of output to context B