|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T x
Length: 2382 (0x94e)
Types: TextFile
Names: »x_pixmap.clu«
└─⟦a0efdde77⟧ Bits:30001252 EUUGD11 Tape, 1987 Spring Conference Helsinki
└─⟦526ad3590⟧ »EUUGD11/gnu-31mar87/X.V10.R4.tar.Z«
└─⟦2109abc41⟧
└─⟦this⟧ »./X.V10R4/CLUlib/vax/x_pixmap.clu«
% Copyright Barbara Liskov 1985
x_pixmap = cluster is none, create, create_xy, create_z, tile, destroy, shape,
get_id, equal, similar, copy
rep = int
none = proc () returns (cvt)
return(0)
end none
create = proc (mask: x_bitmap, fore, back: int) returns (cvt)
signals (error(string))
or: oreq, er: ereq := x_buf$get()
er.code := x_makepixmap
lr(er).l0 := b2i(mask)
er.s2 := fore
or.s3 := back
x_buf$receive()
resignal error
return(x_buf$get_lp0())
end create
create_xy = proc (width, height: int, bits: _wordvec) returns (cvt)
signals (error(string))
or: oreq, er: ereq := x_buf$get()
er.code := x_storepixmap + (XYFormat * 2**8)
er.s0 := height
or.s1 := width
x_buf$send_data(w2b(bits), 1,
((width + 15) / 16) * height * 2 * x_display$planes())
x_buf$receive()
resignal error
return(x_buf$get_lp0())
end create_xy
create_z = proc (width, height: int, bits: _wordvec) returns (cvt)
signals (error(string))
or: oreq, er: ereq := x_buf$get()
er.code := x_storepixmap + (ZFormat * 2**8)
er.s0 := height
or.s1 := width
z: int := width * height
if x_display$planes() > 8
then z := z + z end
x_buf$send_data(w2b(bits), 1, z)
x_buf$receive()
resignal error
return(x_buf$get_lp0())
end create_z
tile = proc (pixel: int) returns (cvt) signals (error(string))
or: oreq, er: ereq := x_buf$get()
er.code := x_makepixmap
lr(er).l0 := 0
er.s2 := pixel
x_buf$receive()
resignal error
return(x_buf$get_lp0())
end tile
destroy = proc (pix: cvt)
or: oreq, er: ereq := x_buf$get()
er.code := x_freepixmap
lr(er).l0 := pix
end destroy
shape = proc (width, height: int) returns (int, int) signals (error(string))
or: oreq, er: ereq := x_buf$get()
er.code := x_queryshape + (TileShape * 2**8)
er.s0 := height
or.s1 := width
x_buf$receive()
resignal error
return(x_buf$get_sp1(), x_buf$get_sp0())
end shape
get_id = proc (pix: cvt) returns (int)
return(pix)
end get_id
equal = proc (pix1, pix2: cvt) returns (bool)
return(pix1 = pix2)
end equal
similar = proc (pix1, pix2: cvt) returns (bool)
return(pix1 = pix2)
end similar
copy = proc (pix: cvt) returns (cvt)
return(pix)
end copy
end x_pixmap