hal/shader/slug-truetype.lisp
in-package#:luv.slug
defunslug-point-from-zpb
point
make-slug-point:x
zpb-ttf:xpoint
:yzpb-ttf:ypoint
defunslug-outline-from-zpb-glyph
glyph
Convert ZPB-TTF's resolved line/quadratic segments to a Slug outline.
let
contours
zpb-ttf:do-contours
contourglyph
let
curves
zpb-ttf:do-contour-segments
startcontrolend
contourlet
slug-start
slug-point-from-zpbstart
slug-end
push
ifcontrol
curvespush
nreversecurves
contoursmake-slug-outline:contours
nreversecontours
defunmake-slug-glyph-from-zpb-glyph
glyphfont-loader&keycharacter
Capture one ZPB-TTF glyph's outline and placement metrics for Slug.
make-slug-glyph:charactercharacter:outline:advance-width
zpb-ttf:advance-widthglyph
:left-side-bearingzpb-ttf:left-side-bearingglyph
:units-per-emzpb-ttf:units/emfont-loader
defunload-slug-glyph
characterfont-loader
Find character in font-loader and capture its Slug outline and metrics.
defunload-slug-glyph-index
glyph-indexfont-loader
Capture HarfBuzz glyph-index from font-loader as a Slug glyph.
defunmap-slug-outline-points
functionoutline
Return an outline whose points are the result of calling function on x/y.
labels
map-point
point
multiple-value-bind
xy
make-slug-point:xx:yy
map-curve
curve
make-slug-quadratic:start
map-point
:controlslug-quadratic-startcurve
map-point
:endslug-quadratic-controlcurve
map-point
slug-quadratic-endcurve
make-slug-outline:contours
loopforcontourin
slug-outline-contoursoutline
collectmapcar#'map-curvecontour
defunnormalize-slug-glyph-outline
glyph
Return glyph's outline in em units, preserving its TrueType origin.
let
units-per-em
slug-glyph-units-per-emglyph
unless
pluspunits-per-em
defun slug-point-from-zpb
(point)defun make-slug-line
(start end)defun make-slug-glyph-from-zpb-glyph
(glyph font-loader &key character)defun load-slug-glyph
(character font-loader)defun load-slug-glyph-index
(glyph-index font-loader)defun map-slug-outline-points
(function outline)define-arithmetic-operator /
Division of two represented quantities.
TrueType outlines enter Slug before McCLIM's software rasterizer.