View this PageEdit this PageUploads to this PageHistory of this PageTop of the SwikiRecent ChangesSearch the SwikiHelp Guide

Glass

Glass.sc
Glass is like a GUIWindow without visible layout that can be dragged
by clicking on the side of the bounds. It should be visible with mouse over, but this doesn't work yet.
the PixFX are said to be experimental, so they might go.
also included in Parallax

(
p = Pen(foreColor:Color.black, action:\fill);
x = GUIScreen("2", Rect.newBy(100, 100, 200, 200), View(p, [
			Rect.newBy(30, 30, 30, 30),
			View.new(Pen(foreColor: Color.red), [ Oval.newBy(25,75,40,60) ]),
			View.new(Pen(foreColor: Color.green, offset: 45@65), ["quick fox, lazy dog"]),
			g = Glass(nil, Rect.newBy(40,40,80,80), [
						VMirrorPix(Rect.newBy(0,0,60,60)),
						HMirrorPix(Rect.newBy(30,30,50,50)),
						MosaicPix(Rect.newBy(0,0,60,60), 8,2);
						])
					])
			);
x.refresh;
x.sched(0, inf, {  x.refresh; });
)

(
var pict;
pict =  Pic.read(":Pics:P7140010.JPG");
p = Pen(foreColor:Color.black, action:\fill);
x = GUIScreen("2", Rect.newBy(100, 100, 400, 200), View(p, [
			ScaledPic(nil, pict, Rect.newBy(0, 0, 400, 200)),
			Rect.newBy(30, 30, 30, 30),
			View.new(Pen(foreColor: Color.red), [ Oval.newBy(25,75,40,60) ]),
			View.new(Pen(foreColor: Color.green, offset: 45@65), ["quick fox, lazy dog"]),
			
			WindowLayer(nil, [
				Glass(nil, Rect.newBy(30,40,80,80), [
						VMirrorPix(Rect.newBy(0,0,60,60)),
						HMirrorPix(Rect.newBy(30,30,50,50))
						]),
				Glass(nil, Rect.newBy(50,50,80,80), [
						MosaicPix(Rect.newBy(0,0,80,80), 4,4);
						]),
				Glass(nil, Rect.newBy(150,40,80,80), [
						MosaicBlurPix(Rect.newBy(0,0,80,80), 10,14);
						]),
					])
				])
			);
x.refresh;
x.sched(0, inf, { x.refresh; 0.02; });

)





Links to this Page