Realtime graphic display

Ned Konz ned at bike-nomad.com
Sat May 19 16:49:45 UTC 2001


On Friday 18 May 2001 22:36, Ted Shab wrote:
> Hi,
>
> I'm new to Squeak, but have worked with Swing/Java,
> etc.
>
> Looking for pointers on designing a real time graphic
> display of waveforms, based on medical data (i.e.
> ECG), although this last bit is probably irrelevant.
> Data will be updated via sockets.

One tip for a scrolling display with multiple graphs might be to use the 
bitblt to scroll existing waveforms, and just write the new parts. But I'd 
certainly try to prototype this using the LineMorph (a/k/a PolygonMorph). You 
can change the vertices on one of these using:
	
	myLine setVertices: anArray

which, given your newly set up array with data, will redraw the line.

I have a CircularBuffer class that's fast and doesn't generate garbage, if 
you're interested. It would be just the right thing for a stripchart display 
where you have a fixed width and fast incoming data.

-- 
Ned Konz
currently: Stanwood, WA
email:     ned at bike-nomad.com
homepage:  http://bike-nomad.com





More information about the Squeak-dev mailing list