Claude paints with code: a Claude Code skill for procedural illustration in 83 styles, from ink wash (水墨), watercolour and ukiyo-e to stained glass, Roman mosaic, Art Deco, shadow puppets, pastel UI, sketchbook doodles, spot illustrations, grainy picture books, dreamy hills, sunlit greenery. No image model: numpy + Pillow on a CPU, draw-on GIFs.
Python agent-skillsanimechinese-paintingclaudeclaude-codeclaude-skillscolored-pencilcreative-codingcross-stitcheditorial-illustrationgenerative-artink-wash-paintingoil-paintingpaper-collagepixel-artprocedural-generationrisographshanshuiukiyo-ewatercolor
Add flat spot illustration style (80 total): a rainy Saturday
cloveric381eb34e46a2
diff --git a/README.md b/README.mdindex fa6ab7f..04fe4a9 100644--- a/README.md+++ b/README.md@@ -1,7 +1,7 @@# Claude Drawing · Claude 绘图-**Claude paints with code — no image model.** Seventy-nine styles, from ink wash and impasto oil to clay, cyanotype, stained glass, a Roman mosaic, Delft tiles, a cyberpunk street, a ray-traced ball pit, low-poly 3D, a thermal camera, an X-ray, a VHS tape, a synthwave sunset, a pastel product-film UI, an answer sheet marked in red, a lamp-lit shadow-puppet play, pen-and-wash sketch cards, retro gouache picture-book portraits, a soft-blue picture-book spread, a Jiangnan water garden in spring, a dry-brushed mid-century poster, a dusk picture-book page where the sky turns to stars, a hatched night print of lava meeting the sea, a dark note-taking app rendering its diagram, an infinite canvas of cards, a five-diagram sheet on warm Flexoki paper, a warm coloured-pencil storybook spread, a colour town of gouache houses strung with bunting, a soft-pastel vignette of a woman wearing her ginger cat as a scarf, a melancholic Halloween portrait of a porcelain-faced child carrying a glowing ghost home in a jar, an oil-pastel portrait of a woman warming her hands on a paper cup on a winter morning and a sketchbook doodle of a girl in a rainbow-striped jumper reading on a stool while her cat sleeps at her feet.-**不用生图模型,Claude 用代码一笔一笔作画。** 七十九种画风,从水墨、油画到黏土、蓝晒、彩色玻璃花窗、罗马马赛克、代尔夫特蓝瓷砖、赛博朋克、光线追踪的小球海、低多边形 3D、热成像、X 光片、VHS 录像带、Synthwave 落日、产品发布片式的粉彩界面、红笔批改的答题卡、油灯下的皮影戏、钢笔淡彩的速写小卡、复古水粉的绘本大头像、蓝调绘本的雨天跨页、江南园林的春水园景、干刷色块的 mid-century 海报、暮色微缩绘本里转入星空的黄昏、排线夜景里流进海里的熔岩、深色笔记应用里渲染出的流程图、卡片铺开的无限白板、Flexoki 暖纸上的五图图解、暖调彩铅叠出来的绘本跨页、挂满彩旗的水粉彩色小镇、把橘猫当围巾的色粉小像、捧着罐中小幽灵的诗意万圣夜、冬天早上捧着一杯热饮的油画棒肖像和穿彩虹条纹毛衣、坐在小凳上读书的手账线描。+**Claude paints with code — no image model.** Eighty styles, from ink wash and impasto oil to clay, cyanotype, stained glass, a Roman mosaic, Delft tiles, a cyberpunk street, a ray-traced ball pit, low-poly 3D, a thermal camera, an X-ray, a VHS tape, a synthwave sunset, a pastel product-film UI, an answer sheet marked in red, a lamp-lit shadow-puppet play, pen-and-wash sketch cards, retro gouache picture-book portraits, a soft-blue picture-book spread, a Jiangnan water garden in spring, a dry-brushed mid-century poster, a dusk picture-book page where the sky turns to stars, a hatched night print of lava meeting the sea, a dark note-taking app rendering its diagram, an infinite canvas of cards, a five-diagram sheet on warm Flexoki paper, a warm coloured-pencil storybook spread, a colour town of gouache houses strung with bunting, a soft-pastel vignette of a woman wearing her ginger cat as a scarf, a melancholic Halloween portrait of a porcelain-faced child carrying a glowing ghost home in a jar, an oil-pastel portrait of a woman warming her hands on a paper cup on a winter morning, a sketchbook doodle of a girl in a rainbow-striped jumper reading on a stool while her cat sleeps at her feet and a sheet of flat Japanese spot illustrations of a rainy Saturday with one red thing in every vignette.+**不用生图模型,Claude 用代码一笔一笔作画。** 八十种画风,从水墨、油画到黏土、蓝晒、彩色玻璃花窗、罗马马赛克、代尔夫特蓝瓷砖、赛博朋克、光线追踪的小球海、低多边形 3D、热成像、X 光片、VHS 录像带、Synthwave 落日、产品发布片式的粉彩界面、红笔批改的答题卡、油灯下的皮影戏、钢笔淡彩的速写小卡、复古水粉的绘本大头像、蓝调绘本的雨天跨页、江南园林的春水园景、干刷色块的 mid-century 海报、暮色微缩绘本里转入星空的黄昏、排线夜景里流进海里的熔岩、深色笔记应用里渲染出的流程图、卡片铺开的无限白板、Flexoki 暖纸上的五图图解、暖调彩铅叠出来的绘本跨页、挂满彩旗的水粉彩色小镇、把橘猫当围巾的色粉小像、捧着罐中小幽灵的诗意万圣夜、冬天早上捧着一杯热饮的油画棒肖像、穿彩虹条纹毛衣、坐在小凳上读书的手账线描和每幅一个红色点睛、讲一个雨天星期六的日系扁平小插画。[English](#english) · [中文](#中文)@@ -60,8 +60,8 @@|  |  |  || **Oil-pastel portrait · 油画棒肖像** | **Ink wash · 水墨(月印万川)** | **Colour town · 彩色小镇** ||  |  |  |-| **Sketchbook doodle · 手账线描** | **Watercolour · 水彩(底纹)** | **Sketchbook doodle · 手账线描(放风筝)** |-|  |  |  |+| **Sketchbook doodle · 手账线描** | **Sketchbook doodle · 手账线描(放风筝)** | **Flat spot illustration · 日系扁平小插画** |+|  |  |  |### Gallery · 画廊@@ -149,8 +149,10 @@| <img src="examples/poetichalloween_ghost_jar.jpg" width="100%"> | <img src="examples/oilpastel_warm_cup.jpg" width="100%"> || **读书的午后** · *The Reading Hour*<br><sub>Sketchbook doodle · 手账线描</sub> | **放风筝** · *Kite Day*<br><sub>Sketchbook doodle · 手账线描 — a 16:9 page for explainer videos · 讲解视频用的宽页</sub> || <img src="examples/sketchbook_reading_hour.jpg" width="100%"> | <img src="examples/sketchbook_kite_day.jpg" width="100%"> |+| **雨天的星期六** · *A Rainy Saturday*<br><sub>Flat spot illustration · 日系扁平小插画</sub> | **雨天的星期六(宽页)** · *A Rainy Saturday, 16:9*<br><sub>Flat spot illustration · 日系扁平小插画 — the same five vignettes laid out 16:9 for explainer videos · 同样五幅小画排成讲解视频用的宽页</sub> |+| <img src="examples/spotillo_rainy_saturday.jpg" width="100%"> | <img src="examples/spotillo_rainy_saturday_wide.jpg" width="100%"> |-Every mark above is computed: paper fibres, ink washes and mist, dry-brush strokes, pigment granulation and blooms, torn-paper edges, pencil wax on paper tooth, cel-shaded clouds, risograph grain and halftones, lit impasto relief, woodblock grain and bokashi, dithered pixels, plasticine lit like a film set, sunlight through leaves on Prussian blue, twisted thread on Aida cloth, machined knobs behind a backlit dial, die-cut vinyl with a laminate gloss, streaky thermal print, graphite catching the tooth of graph paper, highlighter pooling at the start of a swipe, chalk dust settling under half-erased lessons, rain-lit neon glass mirrored in a wet street, a blue-pencil rough under boiling brush ink, an island ray-traced under one soft sun, a single unbroken gold line, candy balls with softbox glints, one outline morphing through six shapes, halftone photos cut out with scissors, frosted glass blurring the real pixels behind it, screen-printed primaries out of register, a slit sun sinking behind a neon grid played off tape, hollow fuse beads on a pegboard melting together under an iron, pits knocked through desert varnish, a red grid showing through flaking plaster, stones laid row by row along an outline, daylight through leaded glass, burnished gold that mirrors the room, left-handed hatching in iron-gall ink, black paper cut with scissors, wood type printed a hair out of register, red and black plates slipping apart, airbrush fades inside knife-cut friskets, Ben-Day dots on yellowed newsprint, one photo key pulled across hand-painted colour, characters struck through a fading ribbon, flat-shaded triangles dithered to 15 bits, spray drifting past cut card, satin stitches catching the light by their angle, ink lines printed white on Prussian blue, wax scribbles skipping the paper's pits, phosphor glowing behind curved glass, heat leaking out of a kitchen, cobalt fired into tin glaze tile by tile, ochre blown onto rock lit by a fire, 1-bit patterns in an old paint program, slip silhouettes incised to the clay, graphite that never quite reaches black, X-rays adding up through a suitcase, grey cels shot on scratched film, gouge marks in a rolled-up block, a birthday smeared onto tape, seven flat colours lifting off each other, an acorn squashing and stretching through a world drawn as it goes, ballpoint ink blobbing at every corner of a hand-drawn game, inks multiplying through tracing paper on a light box, window cards floating on a pastel field over shadows tinted by it, a vermilion stamp running dry at one end, red ink pooling where the pen slowed down, dyed donkey hide glowing on a lamp-lit screen, gouache scumbled dry over a toned board, knit stitch by stitch, dry pastel blue under a scratchy brush line, with chalk rain on top, a spring garden built leaf by leaf, its tiled roofs and willows mirrored in a jade lake, a roller and a dry brush running out across cream paper, a dusk sky going over to stars above thousands of tiny wildflowers, a night sea laid stroke by stroke under the one warm light of lava meeting the water, a hill town of gouache houses, inked line by line and slate by slate, strung with bunting and mirrored in a wet square, a woman and her cat in soft pastel, the faces rubbed smooth, the hair and fur laid strand by strand, the coat breaking up into dry strokes on white paper, a porcelain child flushed red round the eyes, her burlap hat woven thread by thread, carrying a ghost whose glow warms the wool and the leaves, a winter coat laid in with dry oil-pastel strokes that skip the paper's tooth and run out in a comb of wax, and a girl's hair drawn strand by strand in hair-thin ink above a jumper striped in colour pencil that overruns its own outline. No diffusion model, no API, no stock art. It is just Python with **numpy + Pillow** on a CPU: from 0.1 s (pixel art) to about 45 s (the soft 3D ray tracer) per 1920×1080 image.+Every mark above is computed: paper fibres, ink washes and mist, dry-brush strokes, pigment granulation and blooms, torn-paper edges, pencil wax on paper tooth, cel-shaded clouds, risograph grain and halftones, lit impasto relief, woodblock grain and bokashi, dithered pixels, plasticine lit like a film set, sunlight through leaves on Prussian blue, twisted thread on Aida cloth, machined knobs behind a backlit dial, die-cut vinyl with a laminate gloss, streaky thermal print, graphite catching the tooth of graph paper, highlighter pooling at the start of a swipe, chalk dust settling under half-erased lessons, rain-lit neon glass mirrored in a wet street, a blue-pencil rough under boiling brush ink, an island ray-traced under one soft sun, a single unbroken gold line, candy balls with softbox glints, one outline morphing through six shapes, halftone photos cut out with scissors, frosted glass blurring the real pixels behind it, screen-printed primaries out of register, a slit sun sinking behind a neon grid played off tape, hollow fuse beads on a pegboard melting together under an iron, pits knocked through desert varnish, a red grid showing through flaking plaster, stones laid row by row along an outline, daylight through leaded glass, burnished gold that mirrors the room, left-handed hatching in iron-gall ink, black paper cut with scissors, wood type printed a hair out of register, red and black plates slipping apart, airbrush fades inside knife-cut friskets, Ben-Day dots on yellowed newsprint, one photo key pulled across hand-painted colour, characters struck through a fading ribbon, flat-shaded triangles dithered to 15 bits, spray drifting past cut card, satin stitches catching the light by their angle, ink lines printed white on Prussian blue, wax scribbles skipping the paper's pits, phosphor glowing behind curved glass, heat leaking out of a kitchen, cobalt fired into tin glaze tile by tile, ochre blown onto rock lit by a fire, 1-bit patterns in an old paint program, slip silhouettes incised to the clay, graphite that never quite reaches black, X-rays adding up through a suitcase, grey cels shot on scratched film, gouge marks in a rolled-up block, a birthday smeared onto tape, seven flat colours lifting off each other, an acorn squashing and stretching through a world drawn as it goes, ballpoint ink blobbing at every corner of a hand-drawn game, inks multiplying through tracing paper on a light box, window cards floating on a pastel field over shadows tinted by it, a vermilion stamp running dry at one end, red ink pooling where the pen slowed down, dyed donkey hide glowing on a lamp-lit screen, gouache scumbled dry over a toned board, knit stitch by stitch, dry pastel blue under a scratchy brush line, with chalk rain on top, a spring garden built leaf by leaf, its tiled roofs and willows mirrored in a jade lake, a roller and a dry brush running out across cream paper, a dusk sky going over to stars above thousands of tiny wildflowers, a night sea laid stroke by stroke under the one warm light of lava meeting the water, a hill town of gouache houses, inked line by line and slate by slate, strung with bunting and mirrored in a wet square, a woman and her cat in soft pastel, the faces rubbed smooth, the hair and fur laid strand by strand, the coat breaking up into dry strokes on white paper, a porcelain child flushed red round the eyes, her burlap hat woven thread by thread, carrying a ghost whose glow warms the wool and the leaves, a winter coat laid in with dry oil-pastel strokes that skip the paper's tooth and run out in a comb of wax, a girl's hair drawn strand by strand in hair-thin ink above a jumper striped in colour pencil that overruns its own outline, and flat shapes cut with a hand-wobbled edge, folds cut into them in white and one red thing in every vignette. No diffusion model, no API, no stock art. It is just Python with **numpy + Pillow** on a CPU: from 0.1 s (pixel art) to about 45 s (the soft 3D ray tracer) per 1920×1080 image.---@@ -158,7 +160,7 @@ Every mark above is computed: paper fibres, ink washes and mist, dry-brush strok### What it is-A [Claude Code](https://claude.com/claude-code) skill and a small painting library with seventy-nine styles:+A [Claude Code](https://claude.com/claude-code) skill and a small painting library with eighty styles:| Style | Module | What makes it read as the real medium ||---|---|---|@@ -241,6 +243,7 @@ A [Claude Code](https://claude.com/claude-code) skill and a small painting libra| **Poetic Halloween (诗意万圣夜)** | `lib/poetichalloween.py` · `PoeticHalloween` | a melancholic, slightly surreal picture-book portrait for an autumn night, in opaque gouache and fine pencil hatching on a dark toned board, then printed. Faces are pale porcelain with a strong red flush on the nose, the cheeks and the lids and round the eyes, heavy half-closed sad eyes, a small unsmiling mouth and very simplified volumes. The hair is one sculpted mass — a blunt jet-black bob with a dead-straight fringe and a soft sheen. The cloth is tactile (burlap and felt hats, chunky knits, tartan), the ground is dark (night indigo, stars, dense leaves), and there is one luminous accent: little sheet-ghosts with glowing eyes and glowing fringe tips. Strokes use the same per-segment id map as the pastel vignette (wide for dry gouache, thin and long for hatching), and `colour='canvas'` lets each stroke take the colour under its centre, which repaints a computed base (a tartan, a modelled face, the sky) by hand without changing its colour. `model()` washes a dark → light ramp over a soft dome light, which gives the simplified volumes. `sheen()` lays a soft band where that light falls in a narrow range, then streaks it along the hair with a few long faint strokes, so the bob stays one mass. `eye()` is a heavy-lidded almond: the lid covers about half the iris and droops at the outer corner, with a dark lid line, a red wet rim on the lower lid and, optionally, the warm glint of a light below. `flush()` is a smooth red glaze plus a stipple of single specks that gets denser as the flush gets stronger, and `nose()` is its own small volume with a red tip. `burlap()` is a plain weave of slubby threads, each row and column with its own thickness, wandering a little and going over and under. It is lit as a height field, with dark holes, loose fibres and a frayed edge, and it can follow a curve. `knit()`, `rib()` and `tartan()` (a mirrored sett woven 2/2 twill over the light of the folds) cover the rest of the cloth. `leaf()` is a broad, double-serrated palmate leaf, foreshortened and folded along its midribs; it casts a soft shadow on the leaves behind, and that is where a hedge's depth comes from. Warm point lights fall off steeply, and `illuminate()` lights what is already painted as 1 − (1 − C)·exp(−L·receptivity·(base + albedo·C)), so wool and porcelain warm up a lot, leaves near a ghost turn olive-orange and black hair barely changes. `ghost()` is a translucent dome-and-bell of silver strands that falls from the crown like hair, with glowing eyes and a bead of light at the end of every lock. Bloom, a fine print grain and a coarser printed tooth that shows in the darks are added in `render()` || **Oil-pastel portrait (油画棒肖像)** | `lib/oilpastel.py` · `OilPastel` | a figure drawn with oil pastels (wax crayons) on white, toothy cold-press paper and left floating as a vignette — no background, at most a smear of sky or a dry-brushed cast shadow. The palette is tight and high-chroma: saffron and marigold, a teal navy and black, one cool blue, orange blush and red-orange lips. Big masses (a coat, a scarf, a hat) are laid in with parallel dry strokes of a constant-width stick; the wax catches on the peaks of an equalised paper tooth and skips the pits, so every mass is peppered with crisp white specks pulled into streaks along the stroke (the tooth is pre-dragged along 8 directions). The stick's worn face is split into lanes, each with its own pressure, value and end, so a stroke starts blunt and full and ends in a hard comb of uneven teeth; `spill` lets strokes run out past a shape by a different distance along every stretch of its edge. Black crayon (`crayon()`: a wobbling line in overlapping pieces of different weight) is kept for the eyes, brows, a nostril and a few contour and fold marks. Faces are the paper itself with peach on the shadow side, hatched orange `blush()` patches, flat `lips()` and heavy-lidded black `eye()`s; hair is a few long tapering `hair()` strokes; knit stripes are short bold `dashes()`. Strokes use the same per-segment id map as the pastel vignette. The tooth showing through the wax and a little waxy relief at the edges of the deposit are added in `render()` || **Sketchbook doodle (手账线描)** | `lib/sketchbook.py` · `Sketchbook` | a page from an illustrator's sketchbook: warm off-white paper with a faint blush, mostly left empty, one small character and two or three sparse props floating on it — no ground, no background. The drawing is hair-thin dark ink: every line is smoothed, pushed sideways by a slow hand wobble and a tiny tremor, tapers in where the nib lands and out in a long flick, drifts in width and ink flow, and now and then lifts for a few px; `contour()` draws a closed shape as one to three strokes that leave a gap or run past each other at the joins. Lines are cut into runs of constant width and darkness, drawn by Pillow into a 4× supersampled layer and multiplied in (ink is transparent). Hair is a `hair()` lock: many separate strands interpolated between guide curves, waving in phase with their neighbours and thinning to long tips, paper showing between them. Faces are tiny: `eye_closed()` arcs with a few lashes or `eye_dot()`s, a one-stroke nose, a small red `mouth()`, two round `blush()` dots. Clothes are filled with `stripes()`: loose bands of colour pencil and marker laid along stroke coordinates (long streaks, an elongated grain, pigment catching the tooth or lying flat), each band with its own colour, width, tilt and grain, two independently wandering edges and ends that overrun the ink line or stop short of it; bands follow an angle, bow into a smile or wrap round a sleeve's centre-line, and colours multiply (red over yellow turns orange). Props are thin coloured lines: `leaf()` with herringbone vein hatching (or veins left white in the fill), `flower()`, multi-line `tree()`s, a `steam()` curl, `ticks()` for fur and grass, a tiny `squiggle()` (never fake writing) |+| **Flat spot illustration (日系扁平小插画)** | `lib/spotillo.py` · `SpotIllustration` | Japanese-style spot illustrations of everyday life: several small vignettes floating on white with generous space between them — no ground, no background, at most a puddle or a sliver of shadow. Every shape is one flat, opaque colour with no gradient or shading, only a faint print grain; its outline is pushed in and out by a periodic wobble before it is cut, so edges are slightly irregular, never vector-perfect. A restrained palette — navy, slate and powder blue, mustard, olive and forest green, greys, near-black hair, skin left as the paper — with one warm red that recurs as the accent in every vignette (an umbrella, a pot, a bowl, a mug, a pair of socks). Lines are few: `gap=` cuts a thin white gap round a shape so an arm reads against a sweater of the same colour, `fold()` cuts folds and seams in white into dark cloth (a shade darker on pale cloth), and thin dark lines draw only a profile, fingers and furniture legs. People are built from simple parts in a fixed back-to-front order by `person()` — a pose preset ('stand', 'walk', 'sit', 'crouch', 'reach'), joints overridden in head units, the whole figure turned to lie down, hooks to slip a prop between the layers — with paper-white faces (a profile line and a dot eye), lumpy hair blobs with white strands cut in and mitten hands with red finger lines. Little hand marks tell the action: steam squiggles, three dashes of surprise, z's, rain |Ask Claude to *"draw it yourself"*, *"paint this with code"*, or *"claude绘图"*, and name a style if you like. Claude then:@@ -458,6 +461,14 @@ Every style has a complete example: `python3 examples/<name>.py out.png --stages- a tube outline drawn closed puts a line across the shoulder — draw sleeves as open outlines (the two sides and the cuff);- two steam strands that both curl are springs — curl one, keep the others faint and straight;- at 0.25× the whole square page's ink fades out — crop round the drawing before making the draw-on GIF.+- **Flat spot illustration**: several small vignettes on white with plenty of space between them, no ground and no background; flat opaque shapes only, a restrained palette (navy, slate and powder blue, mustard, olive and green, greys, near-black hair) and exactly one red thing in each vignette. Let white gaps separate shapes of one colour and cut folds into dark cloth in white; keep dark lines for profiles, fingers and furniture legs. Watch for accidental reads:+ - a near arm the colour of the sweater disappears — cut a white gap round it (`gap=`) and check that the gap really shows along most of the edge;+ - a long neck under a hair blob floats the head — sit the chin almost on the collar;+ - two parallel white arcs on the crown are a pair of closed eyes — cut short, nearly straight strands in different places;+ - a sharp zigzag fold at the elbow is a lightning bolt — one soft arc inside the bend;+ - red lines at the tip of a mitten are claws — give the fingers bumps and run the red lines back between them;+ - two black dots on a grey box are a face — a stove needs a worktop, a door seam and a row of small knobs;+ - a book standing open on a sleeper's chest is a box — lay it face down as a low solid tent.### Roadmap@@ -469,7 +480,7 @@ Every style has a complete example: `python3 examples/<name>.py out.png --stages### 这是什么-一个 [Claude Code](https://claude.com/claude-code) skill,加上一个小巧的绘图库,内置七十九种画风:+一个 [Claude Code](https://claude.com/claude-code) skill,加上一个小巧的绘图库,内置八十种画风:| 画风 | 模块 | 为什么看起来像真的 ||---|---|---|@@ -552,6 +563,7 @@ Every style has a complete example: `python3 examples/<name>.py out.png --stages| **诗意万圣夜** | `lib/poetichalloween.py` · `PoeticHalloween` | 秋夜 / 万圣节的忧郁、带一点超现实的绘本肖像,暗色画板上的不透明水粉加细彩铅排线,再印出来:瓷白的脸,鼻子、脸颊、眼皮和眼睛四周泛着很重的红晕,半闭的厚眼皮,不笑的小嘴,体积极简;头发是一整块雕塑般的实体——刀切齐刘海的乌黑波波头,一道柔和的光泽;衣物是摸得着的织物(粗麻 / 毛毡帽子、粗针织、格子呢);底子是靛蓝夜空、星星和浓密的叶丛;只有一处发光的点睛:眼睛和衣摆尖发着暖光的床单小幽灵。笔触和色粉小像同一套按段编号的 id 图(宽的是水粉干笔,细长的是排线),`colour='canvas'` 让每一笔取它中心下面的颜色,把算出来的底子(格子呢、塑形过的脸、夜空)用手再画一遍、颜色不变。`model()` 按软穹顶光揉色阶,就是那种极简的体积;`sheen()` 只在受光落在一条窄带里的地方铺一层柔和的光泽,再顺着头发拉几笔又长又淡的笔触,波波头仍是一整块。`eye()` 是重眼皮的杏仁眼:上眼皮盖住约一半虹膜、往外眼角垂,深色眼线,下眼睑一道湿红,还可以映出下面那盏光的一点暖色;`flush()` 是平滑的一层红加一层单像素的细斑点,越红越密;`nose()` 自成一个小体积,红鼻尖。`burlap()` 是粗麻平纹:每行每列线各自粗细、有疙瘩、略游走、一上一下交织,当高度场打光,线间是黑孔,有松出的纤维和毛边,能顺着弧线织;`knit()`、`rib()`、`tartan()`(镜像 sett、2/2 斜纹、乘衣褶的受光)管其余的织物。`leaf()` 是宽裂片、重锯齿的掌状叶,随机压扁、沿中脉对折,往后面的叶子投一块软影子,树丛的层次就从这里来。暖色点光源衰减很陡,`illuminate()` 按 1 −(1 − C)·exp(−L·接受度·(base + albedo·C)) 照亮画好的东西:毛线和瓷白的脸变暖很多,小幽灵旁边的叶子变成橄榄橙,黑头发几乎不变。`ghost()` 是银色细丝组成的半透明圆顶钟形,像头发一样从头顶披下,发光的眼睛,每一绺末端一颗光珠。光晕、细的印刷颗粒和暗部更显的粗印刷纸纹在 `render()` 里加 || **油画棒肖像** | `lib/oilpastel.py` · `OilPastel` | 白色糙面纸上的油画棒(蜡笔)人物小像,人浮在白纸上——不画背景,至多一抹天色或一块干刷的投影。颜色收得紧而浓:藏红花黄和金盏黄、偏青的藏青和黑、一种冷蓝,加橙色腮红和橙红嘴唇。大衣、围巾、帽子这类大块颜色用宽度不变的棒一道道平行地铺满;蜡挂在直方图均衡过的纸纹凸起上、跳过纸坑,所以每块颜色里都撒着脆的白点,顺着笔拉成短道(纸纹预先沿 8 个方向拖开)。棒用秃了的那一面分成几道,每道自己的压力、明暗和终点,所以起笔钝而饱满、收笔是一把长短不一的硬梳齿;`spill` 让笔触冲出形状,每段边冲出去的距离各不相同。黑色蜡笔(`crayon()`:抖动、分段搭接、粗细不一的线)只用在眼睛、眉毛、鼻孔和几处轮廓、衣褶上。脸就是纸,背光一侧几笔桃色,排线的橙色 `blush()`,平涂的 `lips()`,压低眼皮的黑色 `eye()`;头发是几笔收尖的长 `hair()`;针织条纹是短而粗的 `dashes()`。笔触和色粉小像同一套按段编号的 id 图。蜡下面透出来的纸纹和蜡边缘的一点厚度在 `render()` 里加 || **手账线描** | `lib/sketchbook.py` · `Sketchbook` | 速写本里的一页小画:暖米白、带一点粉的纸大片空着,一个小人物加两三件稀疏的道具浮在上面,不画地面和背景。画是发丝细的深色墨线:每根线先过样条,再沿法向推一个慢的手抖和一点快的颤,起笔细、收笔挑出一个长尖,粗细和墨色慢慢变,偶尔抬笔断开几 px;`contour()` 把闭合的形状画成一到三笔,接口留缺口或搭过头。线切成粗细和深浅都不变的几段,用 Pillow 画进 4 倍超采样的图层,再正片叠底(墨是透明的)。头发是 `hair()`:在几条导线之间插出很多根分开的细线,和相邻的线一起起伏,发梢收成长尖,线之间露着纸。脸很小:`eye_closed()` 的弧线加几根睫毛或 `eye_dot()`,一笔鼻子,小红 `mouth()`,两颗圆的 `blush()`。衣服用 `stripes()` 涂成彩铅和马克笔的松散条纹:沿笔的方向铺(长道子、顺笔的细颗粒,颜料挂在纸纹上或平平铺开),每条自己的颜色、宽度、倾斜和颗粒,上下两条边各自游移,两头冲出墨线或够不到;条纹可以按角度排、弯成微笑,也可以绕着袖子的中心线转;颜色正片叠底(红压黄成橙)。道具是细的彩色线:带人字形叶脉排线(或叶脉留白)的 `leaf()`、`flower()`、几根线叠成的 `tree()`、一缕 `steam()`、猫毛和草的 `ticks()`、一个小 `squiggle()`(不写假字) |+| **日系扁平小插画** | `lib/spotillo.py` · `SpotIllustration` | 日系的生活小插画(spot illustration):几幅日常小事的小画散在白纸上,中间留足白,不画地面和背景,至多一个水洼或一道小影子。每块颜色都是平涂的不透明色块,没有渐变和明暗,只有极淡的印刷颗粒;下刀前轮廓先沿法向推一个周期的起伏,所以边略不规整,不像矢量那么光。颜色克制——藏青、灰蓝和粉蓝、芥末黄、橄榄绿和墨绿、几种灰、近黑的头发,皮肤就是白纸——每幅里只有一个反复出现的暖红(伞、锅、碗、马克杯、一双袜子)。线很少:`gap=` 在一块颜色周围刻一道白缝,同色的胳膊和毛衣才分得开;`fold()` 在深色布料上刻白色的衣褶和接缝(浅色布料上画深一号的线);深色细线只画侧脸、手指和家具腿。人由 `person()` 用简单零件按从后往前的顺序拼:姿势预设(站、走、坐、蹲、伸手),以头高为单位改关节,整个人转过来就能躺下,`hooks` 在两层之间插进道具;脸是白纸加一道侧脸线和一点眼,头发是鼓包的一整块、刻两三根白发丝,手像连指手套、指缝是红线。小动作交给手画的小记号:热气的 S 形、惊讶的三短线、z、雨点 |对 Claude 说「claude绘图」「你自己画」「用代码画」,也可以指定画风。它会:1. **先定构图**:层次、焦点、留白,而且画面要图解内容本身;@@ -661,6 +673,7 @@ python3 examples/poetichalloween_ghost_jar.py out.jpg --stages stages/ # 诗python3 examples/oilpastel_warm_cup.py out.jpg --stages stages/ # 油画棒肖像:捧着一杯热的python3 examples/sketchbook_reading_hour.py out.jpg --stages stages/ # 手账线描:读书的午后python3 examples/sketchbook_kite_day.py out.jpg --stages stages/ # 手账线描:放风筝(16:9)+python3 examples/spotillo_rainy_saturday.py out.jpg --stages stages/ # 日系扁平小插画:雨天的星期六(--layout wide 出 16:9)```### 作画要点(Claude 交图前逐条自查)@@ -827,6 +840,14 @@ python3 examples/sketchbook_kite_day.py out.jpg --stages stages/ # 手账线- 闭合描的管子轮廓会在肩上横一道线——袖子画成不闭合的轮廓(两条边加袖口);- 两缕热气都卷圈就成了弹簧——只卷一缕,其余的淡而直;- 整张正方形缩到 0.25 倍,墨线就淡没了——做动图前先裁出画周围的一块。+- **日系扁平小插画**:几幅小画散在白纸上、中间留足白,不画地面和背景;只用平涂的不透明色块,颜色克制(藏青、灰蓝和粉蓝、芥末黄、橄榄绿和墨绿、几种灰、近黑的头发),每幅里只有一个红色的东西。同色的两块用白缝分开,深色布料上的衣褶刻成白线;深色细线只留给侧脸、手指和家具腿。小心看错:+ - 和毛衣同色的近处胳膊会消失——在它周围刻白缝(`gap=`),并且确认大部分边上真的有缝;+ - 头发下面一截长脖子,头就飘起来了——下巴几乎贴着领口;+ - 头顶两道平行的白弧是一双闭着的眼睛——白发丝要短、几乎是直的、位置错开;+ - 肘弯里尖的 Z 字衣褶像闪电——弯的内侧一道软弧;+ - 手套尖上的红线是爪子——指头要有鼓包,红线从指缝往回画;+ - 灰盒子上两个黑点是一张脸——灶台要有台面、门缝和一排小旋钮;+ - 睡着的人胸口竖着一本打开的书像个盒子——书扣着放,是一个低矮的实心「人」字。### 计划diff --git a/SKILL.md b/SKILL.mdindex 77b8ffa..814b694 100644--- a/SKILL.md+++ b/SKILL.md@@ -1,6 +1,6 @@---name: claude绘图-description: Claude 绘图 / Claude Drawing —— 不借助任何生图模型,由 Claude 用代码一笔一笔「画」出图片(程序化绘画)。内置七十九种画风:中国水墨、水彩、剪纸拼贴、韩国彩铅、日本动漫、编辑风手绘(Riso)、油画厚涂(梵高式流向笔触+颜料浮雕打光)、浮世绘木版画(晕色、木纹、墨线主版、青海波)、像素风(低分辨率+Bayer 抖动+像素字体)、黏土定格(高度图捏出的彩泥+影棚打光)、蓝晒(普鲁士蓝日光晒图,植物剪影透光)、十字绣(Aida 布十字绣+回针绣+缎面绣+法式结)、复古仪器面板(60 年代收音机/仪器正面:柚木、拉丝铝、旋钮、刻度窗、指示灯)、贴纸拼贴·小票(模切乙烯贴纸、热敏小票、和纸胶带、吊牌、橡皮章)、实验笔记本·贴纸(线圈方格本、铅笔图表、荧光笔、红笔圈、便利贴)、黑板板书(墨绿石板、粉笔颗粒、板擦残影、示意图与公式)、赛博朋克(雨夜霓虹街道、玻璃管霓虹招牌、全息广告、湿路面倒影)、卡通手绘(蓝铅笔稿、毛笔线、错位平涂、赛璐璐阴影、逐帧抖线)、等轴 2.5D(正等轴微缩模型、一个太阳照出三面明暗、悬浮数据卡)、单线画(一根不断开的线一笔画完、唯一点睛色)、柔光 3D(光线追踪的糖果色小球海和鼓鼓的软字、景深)、形变动画(一条轮廓依次变形、洋葱皮残影、缓动曲线)、报刊拼贴(牛皮纸、手撕旧报纸、网点老照片、勒索信拼贴字)、弥散玻璃(弥散渐变、磨砂玻璃卡片界面)、包豪斯几何(三原色几何、丝网印刷海报)、复古 Synthwave(切口落日、霓虹网格、镀铬字、录像带质感)、拼豆(钉板上的熔珠小管、熨烫熔合)、岩画(沙漠漆上凿出的凹坑图形、新旧凿痕、剥落)、古埃及墓室壁画(灰泥墙、红格起稿、分栏叙事、象形文字、剥落)、罗马马赛克(石子与玻璃沿轮廓一排排铺、灰缝、燕尾铭牌)、彩色玻璃花窗(哥特尖拱窗、通体着色玻璃、grisaille 彩绘与银染、铅条、透光)、泥金手抄本(羊皮纸、鹅毛笔哥特体、朱红标题、打磨金箔首字母)、达·芬奇手稿(铁胆墨水、左手排线、红粉笔、镜像手写、机械分解图)、剪影(黑纸剪出的侧影小像、薄金粉、椭圆金框)、凸版印刷海报(木活字、红黑双色错版、木刻插图)、苏联构成主义(红黑两版、斜条与楔形、西里尔大字、网点照片拼贴)、装饰艺术 Art Deco(1930 年代喷枪流线型海报、交替射线、阶梯高楼、金色 Deco 字)、黄金时代漫画(毛笔墨线、Ben-Day 网点、四色错版、新闻纸)、波普丝网(多格撞色平涂 + 错位的照相黑版)、ASCII 字符画(行式打印机、绿条连续纸、叠打)、低多边形(1999 年代 3D:平面着色、仿射贴图、逐顶点雾、15 位色抖动)、喷漆模板涂鸦(混凝土墙上多层卡纸模板喷绘、雾化与滴痕)、刺绣徽章(牛仔布上的机绣徽章:填充绣、缎面绣、锁边)、蓝图工程图(描图墨线晒成蓝底白线)、儿童蜡笔画(小孩在糙纸上的蜡笔涂抹)、绿屏终端 CRT(荧光字符画、扫描线、余辉)、热成像(先画温度场再上伪彩色)、代尔夫特蓝瓷砖(锡釉砖上的钴蓝手绘)、洞穴壁画(火光下的赭石、吹喷手印)、1-bit 早期画图软件(黑白整屏、8×8 图案填充)、古希腊黑绘陶瓶(黑釉剪影、刻线、饰带展开图)、铅笔素描(石墨排线、擦笔、边缘只剩线稿)、X 光片(安检透视、轮廓发亮、伪彩)、1930 年代黑白橡皮管动画(白手套、饼切眼、老胶片)、黑白麻胶版画(刻刀减法、手拓发花、套色错版)、VHS 家庭录像(钨丝灯偏色、色度渗色、REC)、扁平矢量(分层几何色块、七色、层间投影)、绘本角色动画(小角色挤压拉伸的真动画)、圆珠笔涂鸦(蓝红圆珠笔线稿、墨团、彩铅、页边涂鸦)、描图纸叠层(灯箱上的黑线底图 + 一张张单色描图纸叠片:正片叠底、套准十字、定位钉、绘图胶带)、粉彩界面 · Pastel UI(产品发布片式的界面画面:纯色粉彩底与大光斑、macOS 窗口卡片、胶囊与粗黑标题色条、状态标签与 ✓ / ✗ 徽章、放大镜、从卡片边探头的扁平小图标)、阅卷批改 · Exam Grading(绿毛毡桌上被红笔批改的答题卡:定位黑块、考号涂卡、得分格与阅卷栏、长尾夹夹住的标准答案卡、油墨不均的朱红印章、立体红笔、波浪线 / 圈 / 引线 / 批注 / 叉 / 圈起来的分数)、皮影戏 · Shadow Puppetry(油灯照亮的幕布上,雕空、透明染色的驴皮关节人偶:镂空纹样、阳刻空脸、雉翎盔头、线结与操纵杆、离幕时虚化的双影;雕花戏台、红漆金字牌匾、红灯笼)、钢笔淡彩 · Pen & Wash(速写小卡上的针管笔线稿 + 松散淡彩:线条抖、出头、不闭合,颜色错位出线、留白缝、干边与颗粒,不铺满的背景色块;大头、圆眼镜、点点眼、红鼻子的呆萌小人;卡片拍在木桌上,旁边放着针管笔和水笔)、复古水粉 · Retro Gouache(复古绘本风的水粉大头像:不透明水粉从暗到亮一层层盖上去,单色背景用干笔皴擦;大红鼻子、腮红、圆眼和大耳朵用几阶色值塑出来;看得见针脚的毛衣和毛线帽,一根根的头发和胡子,毛毡;最后是印刷书页的纸纹)、蓝调绘本 · Blue Picture Book(软蓝色调的现代绘本跨页:几乎只用粉蓝、矢车菊蓝、深青蓝三阶蓝加黑墨和纸白,只点一点珊瑚红、粉色腮红和芥末黄;毛笔 / 墨铅笔线干、抖、断,粗细不匀,线不闭合,暗部用快速来回的乱线排出来;颜色是干蜡笔、粉彩、干水粉,错位出线,纸纹的白点透出来;白粉笔痕压在蓝上,甩点和细尘;背景蓝块毛边、不到纸边;大圆脑袋、带高光的点点眼、点彩腮红和雀斑、火柴腿穿靴子的小人,乱线毛边的白色毛绒动物;最后印在书上:中缝和页码)、江南园林 · Jiangnan Garden(细笔园林春景,数字水粉插画:成千上万片叶形小笔触按一个太阳堆出树冠,暗芯、亮边、一簇簇的高光;白色和淡粉的繁花是一簇簇圆点花瓣,枝条从缝里露出来;垂柳是一绺一绺发丝般的细枝挂满小叶;黛瓦飞檐是真的瓦垄:筒瓦板瓦一行行、檐口瓦当滴水、翘起的翼角和卷起的脊头;粉墙月洞门、冰裂纹漏窗、翡翠绿槅扇和挂落、红灯笼、匾额;九曲石桥、石阶、小木船;碧绿湖面倒映岸上的一切,更柔、更暗,加涟漪和细竖纹;睡莲、白鹭;从前景花枝到雾里青山层层退远,墙上桥上落着叶影;最后一方小红印)、干刷色块 · Dry-Brush Blocks(mid-century 海报 / 水粉拼贴式的编辑插画:米白纸上几大块干笔或滚筒刷出的色块,颜色严格限定在森林绿、鼠尾草绿、青蓝、藏蓝、近黑和朱红,外加一点天蓝、淡青瓷和米色;每块颜色在自己的笔刷坐标系里刷:一道道平行的笔,起笔饱满、收笔干枯,两侧几乎是直边,两端梳成长短不一的毛齿,块里有顺笔的鬃毛纹、皴擦斑和露出来的纸色;背后的大色板用滚筒:近乎平涂、成簇的细点、干的两侧和几道细刮痕;色块像丝网套印或撕纸拼贴一样叠起来,撕口带一圈浅色纤维边;人物拆成几个大块面:亮暗两半朝不同方向刷的外套、几块肤色平面拼的头、粗黑框眼镜、干笔皴擦的白胡子;瓶子是竖刷的深色剪影加一道高光和小块标签;一旁一个小朱红方块;不勾线、不做渐变;最后像胶印:轻微柔化、纸纹、暗部零星白点、纸上细尘)、暮色微缩绘本 · Twilight Storybook(温柔、怀旧的黄昏绘本单页,满是微缩细节:大片粉彩黄昏天空,从顶上的薰衣草紫经玫瑰、蜜桃到地平线的暖金,柔和的平底云带、细细的光线和一轮低垂的淡日;一侧天空已经入夜:星空、带暗带的银河、弯月、流星,昼夜交界经过淡紫和靛蓝,不发灰;下面是一层层粉彩条纹的起伏山丘,拼布似的田、细细的垄、小圆树;前景是几万朵小野花铺成的坡,坡顶是色点,越往下越大:雏菊、矢车菊、虞美人、波斯菊、金盏花、毛茛、羽扇豆、勿忘我,夜的一侧整片变成月光蓝;很小、扁平、可爱的原创角色;上面叠一层科学图版的语言:圆形的「detail a」放大图,细墨线、排线、尺寸标注、标签和比例尺,几行灰色的小写英文手写字;最后是细颗粒、光晕、暗角和底边一道撕纸边)、排线夜景 · Hatched Nocturne(彩铅 / 色粉排线式的小幅夜景版画:天空、云、山和海全由密密的短笔触叠成,每片区域的笔触顺着同一股「风」走——天空斜着流、蒸汽绕着云团卷、山坡顺着坡向、海面横着长拖,每一笔色相和明度都差一点,笔毛分道、拖干的笔尾、纸纹里漏出的细缝,没有一处平滑渐变;深靛蓝、藏青、冷灰蓝的夜色里只有一个暖色光源,光是一层层加上去的发光笔触:核心黄白、外圈橙红、再外是被照亮的笔触,被照亮的蒸汽按「光 × 受光」上色,所以是红橙而不是粉;发光的细丝(会蜿蜒、分股、末端亮珠)、火星、星点;海面上被横向笔触打碎的倒影和光柱;几十像素高的小人靠一点亮色(围巾)点出来;最后装裱成小版画:米白纸边、压印的版痕、左下铅笔小标题、右下更小的说明,用细的普通字体)、笔记应用界面 · Obsidian UI(讲解片里的深色笔记应用窗口:近黑页面上一团淡紫光晕,窗口里有标签栏、细长图标栏、带缩进线的文件列表、粗黑 H1 下一道紫色短条、属性块和「#标签」、紫色的内部链接和行内代码、带语法色的 mermaid 代码块——点「阅读」后渲染成扁平深色的流程图,一个节点亮紫——紫色左边的引用标注,右栏关系图谱里被链接的笔记亮成紫色光点;全画只有一个紫色强调色,不画官方 logo)、白板卡片 · Canvas Board(深色笔记应用的白板视图:深色页面上一扇应用窗口——红黄绿三点和「.canvas」标签页的标签栏、左边一列线性图标——里面是一块随镜头平移缩放的灰点阵无限白板;分组框和浮在框上方的组名,深色圆角卡片带 2 px 的卡片色边(红、橙、黄、绿、青、紫)和一层很淡的同色底,卡片之间是从边的中点沿法线弯出去的曲线连线,末端实心箭头、中间一块白板底色的标签;卡片里是 Markdown:标题、正文、紫色高亮、等宽行内代码、勾选清单(勾上时紫色方框弹出、对勾画出、文字变灰加删除线)、紫色竖条的引用、紫色标签胶囊、颜色编号胶囊;图片卡片上方写文件名,里面可以用手绘笔触画草图(每笔画两遍、略弯、出头,手写体批注);右上角一列缩放按钮;全画只有一个紫色强调色加卡片色;所有东西都记在白板坐标里、每次按镜头重画,任意缩放都锐利,镜头能平移缩放、卡片能掉落、连线能一点点画出来)、Flexoki 纸面 · Flexoki Paper(文档站式的图解页:暖白纸(#FFFCF0) 上的墨黑字和一串暖灰,几张不描边、不投影的浅灰圆角卡片,粗黑中文标题、灰色英文类型名、等宽编号;卡片里的图照轻量图表渲染器的样子画——比底色差一级的框和 2 px 灰边(直角、圆角、胶囊、菱形、圆柱、圆)、墨线末端一个小的实心三角箭头、普通半粗体标签垫一块底色,虚线生命线和回复、带纸色缝的饼图、细网格上的柱状图、表头着色的对比表;Flexoki 的橙、红、蓝、绿、紫、青只放在有意义的地方,橙色聚焦框、黑底胶囊、字距收紧的大数字;能做成图一边一边画出来、数字滚动的动图)、暖调彩铅绘本 · Warm Pencil Storybook(暖白、有齿纹的纸上一层层叠涂的彩色铅笔绘本页:天空、山坡、草、水、一只大而温柔的生物和一个小小的孩子,全由顺着形体走向的细铅笔线叠成——天空横向长排线,山坡顺着坡势,龟壳绕着每块盾片的生长纹,脖子横过褶皱,雨衣顺着衣褶,苔藓和头发一簇簇顺毛;每块先铺一层浅色底,再上固有色、背光处叠同色系的深色,受光处罩一层暖色、阴影里罩一层冷色,每层角度错开一点、笔触交叉;蜡只挂在纸齿的峰上,同一批纸坑一层层都透出细白点,压得重、叠得多的地方才慢慢合上;后画的东西先留白再铺背景,颜色不互相混;毛是一绺一绺的:根部散开、尖端聚拢、顺着毛向,每绺受光一侧亮、背光一侧暗;没有墨线、没有黑色,只有很淡的同色轮廓;黄昏的暖光:灯笼和窗灯是一层层橙黄的发光叠涂(不是一团光晕,也不是放射线),低低的太阳给受光一侧一道暖边;水里的倒影也是一笔笔横排线;附带树、小房子、石头、鳞片、野花、纸灯笼和穿雨衣提灯笼的小孩等绘本部件)、彩色小镇 · Colour Town(不透明水粉平涂加细细的深棕墨线画的童话山城街景:高高窄窄的房子漆成番茄红、芥末黄、青绿、薄荷、珊瑚、奶白,一排压一排堆上山坡,近大远小、前后遮挡;深蓝灰的石板曼莎屋顶是一片片瓦错缝铺出来的,带老虎窗、烟囱和赤陶烟囱帽、电视天线;白色钟楼、淡蓝的天和奶白的云;三角彩旗串在好几层深度上斜穿街道,远处的小、近处的大,每面旗有一道深一点的折痕;红色爬藤玫瑰、溢出来的窗台花箱、铁艺阳台、石头台阶和扶手、路灯、吊挂的店招、拱门和彩色木门、写着字的店面和条纹遮阳篷;前景是湿亮的街面,把整条街倒映成一道道竖向的笔触;每块颜色都是带一点笔刷纹理的不透明平涂,边缘像手画的那样微微抖,和描线不完全对齐;墨线分成几段、粗细略有变化,方框的转角偶尔出头;墨是半透明的,压在红墙上是深红棕,压在玻璃上近乎黑;窗户排得整齐,但每扇都略有不同;一整面墙可以用透视单应贴成往消失点收的峡谷墙;几乎没有投影;附带钟楼、台阶、矮墙、栏杆、树、花盆、彩旗、路灯、店招、海报、咖啡桌、猫和概括的小人等部件)、色粉小像 · Pastel Vignette(白纸上的绘本角色小像,软色粉加一点水粉:一个人和他的小动物,半身、略偏一边,四周大片留白,不画背景色块、不加边框,画面在边上用干笔散开、融进白纸;颜色柔和、粉粉的——浅粉蓝的衣服上看得见顺着衣褶的干笔、奶油色的毛衣、暖肤色——只有一组暖橙饱和(橘猫、绒球、蝴蝶结这类);脸是揉开的平滑色粉:大圆眼、深色虹膜和两点白高光、一大圈腮红、红鼻尖、小嘴;头发和毛是成百上千根细丝,一绺一绺,有几根飞出轮廓,毛的轮廓蓬松地融进后面的东西;几乎不描线,只有眼皮、鼻翼、脸的背光侧几道细的软线;背后至多一枝叶子和一层很淡的铅笔小镇;附带圆眼、眉毛、腮红、鼻子、嘴、发丝、毛簇、蓬松轮廓、叶子和枝条等部件)、诗意万圣夜 · Poetic Halloween(忧郁、带一点超现实的秋夜 / 万圣节绘本肖像,暗色画板上的不透明水粉加细彩铅排线,再印出来:瓷白的脸,鼻子、脸颊、眼皮和眼睛四周泛着很重的红晕(平滑的一层红加单像素的细红斑点),下眼睑一道湿红,厚眼皮半闭、往外眼角垂,小嘴不笑,体积极简;头发是一整块雕塑般的实体——刀切一样平的齐刘海、乌黑(或银白)的波波头,几乎看不见发丝,只有一道柔和的光泽;衣物是摸得着的织物:粗麻 / 毛毡帽子(一上一下交织的粗线、线间的黑孔、毛边)、粗针织围巾和手套、斜纹织出来的格子呢外套;底子暗而沉——靛蓝夜空和星星、浓密的深色叶丛;每幅只有一处发光的点睛:眼睛和衣摆尖发着暖光的床单小幽灵,暖光照亮身边的叶子、毛线和脸的下侧;满画面一层细的印刷颗粒;附带重眼皮眼、红晕、长鼻子、小嘴、光泽带、粗麻、针织、罗纹、格子呢、毛边、掌状叶和叶丛、暖光照明和光晕、小幽灵、星星等部件)、油画棒肖像 · Oil-Pastel Portrait(白色糙面纸上的油画棒 / 蜡笔干刷人物小像,人浮在白纸上、不画背景(至多一抹天色或一块干刷的黑色投影):颜色收得紧而浓——藏红花黄 / 金盏黄、偏青的藏青和黑、一种冷蓝,加橙色腮红和橙红嘴唇;毛衣、帽子、大衣、围巾这类大块颜色用一道道平行的干笔铺满,蜡只挂在纸纹的凸起上、跳过纸坑,所以每块颜色里都撒着顺着笔拉长的纸纹白点,笔触的收尾是硬的、一把长短不一的梳齿;黑色蜡笔只点在要紧处:眼睛、眉毛、鼻孔、几笔轮廓和衣褶,不勾满轮廓线;脸就是纸本身,背光一侧几笔桃色,两块排线的橙色腮红,平涂的橙红嘴唇——简化、略歪、有表情;头发是几笔松而有劲的长笔触,针织的条纹是一段段短而粗的色条;附带干笔铺色、蜡笔线、排线腮红、短色条、干刷投影、热气、黑眼睛、粗眉、嘴唇、长发丝等部件)、手账线描 · Sketchbook Doodle(速写本里的一页小画:暖米白、带一点粉的纸上大片空着,一个小小的人物加两三件稀疏的小道具浮在纸上,不画地面和背景;发丝细的深色墨线,略抖,起笔轻、收笔挑出一个细尖,轮廓一两笔画完、接口不闭合,偶尔断开;头发是一根根分开的细线,一起顺着一个方向起伏,线与线之间露着纸;脸小而简单——闭着的弧线眼加几根睫毛(或两个小黑点)、一笔鼻子、小小的红嘴、两颗圆圆的粉腮红;衣服用彩铅和马克笔涂成一道道松散的彩虹条纹(红、黄、青绿、橙、品红、蓝),条与条之间留着纸白,每条的上下边各自游移,有的冲出墨线、有的够不到,看得见彩铅的颗粒和顺笔的道子,颜色压在一起会变(红压黄成橙);道具用细的彩色线:单片叶子带人字形叶脉排线(或在填色里留白的叶脉)、小花、几根细线叠成的小树、一缕带卷的热气、一只团着睡觉的猫;附带抖线墨线、不闭合的轮廓、发丝、条纹、彩铅 / 马克笔上色、圆腮红、闭眼、点眼、小红嘴、叶子、小花、细线树、热气、短毛刺、小涂鸦等部件)。用户说「claude绘图」「用代码画」「你自己画」「不用生图模型画」「程序化绘画」,或点名以上任一画风(含黏土、彩泥、定格动画、蓝晒、晒图、十字绣、刺绣、复古面板、老式收音机、贴纸、小票、收据、手帐拼贴、实验笔记本、方格本、荧光笔、便利贴、黑板、板书、粉笔、赛博朋克、霓虹、雨夜街道、卡通、手绘卡通、逐帧手绘、抖线、等轴、2.5D、微缩模型、单线画、一笔画、线条动画、柔光 3D、3D 渲染、C4D 风、软糖字、小球海、形变、变形动画、报刊拼贴、剪报、达达、勒索信字、网点印刷、弥散渐变、玻璃拟态、毛玻璃、包豪斯、几何构成、丝网印刷、Synthwave、蒸汽波、合成器浪潮、80 年代复古、拼豆、拼拼豆、熔珠、熨豆、豆豆画、钉板、烫豆、岩画、岩刻、凿刻、石刻、沙漠漆、史前壁刻、大角羊、古埃及、埃及壁画、墓室壁画、法老时代、象形文字、尼罗河、底比斯、罗马马赛克、马赛克镶嵌、镶嵌画、石子拼画、地砖画、古罗马地板、彩色玻璃、彩绘玻璃、花窗、玻璃花窗、教堂花窗、哥特花窗、铅条玻璃、泥金手抄本、手抄本、彩饰手抄本、中世纪手稿、羊皮纸、哥特体、花体首字母、泥金、贴金、星盘、达芬奇、达·芬奇、达芬奇手稿、手稿风、文艺复兴手稿、发明手稿、镜像字、镜像书写、扑翼机、红粉笔、钢笔排线、机械草图、分解图、剪影、剪影肖像、侧影、侧面像、黑纸剪影、剪影小像、椭圆金框、乔治时代肖像、摄政时期肖像、凸版印刷、活版印刷、木活字、铅字海报、马戏团海报、复古海报、老海报、19 世纪海报、双色套印、错版、套色错位、木刻插图、构成主义、苏联海报、苏联构成主义、俄国先锋派、罗德琴科风、红黑海报、照片蒙太奇、照片拼贴海报、西里尔字、装饰艺术、装饰风、流线型、流线型海报、1930 年代海报、旅行海报、铁路海报、火车海报、喷枪画、喷笔画、阶梯高楼、射线背景、盖茨比风、黄金时代漫画、老漫画、复古漫画、美漫封面、漫画封面、Ben-Day 网点、本戴点、网点上色、四色印刷、四色错版、新闻纸、对白框、拟声字、1940 年代漫画、波普、波普艺术、波普丝网、沃霍尔风、丝网版画头像、撞色头像、多格重复头像、六宫格撞色头像、ASCII、字符画、字符艺术、文字画、行式打印机、绿条纸、连续打印纸、针孔打印纸、老电脑打印、叠打、低多边形、低面数、低模、多边形风、千禧年 3D、90 年代 3D、复古 3D 游戏、老游戏截图、PS1 风、N64 风、平面着色、线框、游戏 HUD、飞行游戏、穿环、喷漆、模板涂鸦、镂空模板、喷漆模板、模板喷绘、街头涂鸦、街头艺术、墙绘、滴漆、班克西风格、刺绣徽章、徽章、布章、臂章、刺绣贴、绣标、锁边、牛仔外套徽章、户外徽章、营地徽章、弧形条章、蓝图、工程图、施工图、蜡笔画、儿童画、绿屏终端、CRT、显像管、热成像、热像仪、温度图、代尔夫特、荷兰蓝瓷砖、洞穴壁画、史前壁画、赭石、1-bit、黑白画图软件、MacPaint 风、黑绘、古希腊陶瓶、希腊瓶画、铅笔素描、素描、铅笔画、X 光、X 光片、安检图像、橡皮管动画、黑白卡通、老动画、麻胶版画、黑白版画、藏书票、VHS、家庭录像、录像带、扁平插画、扁平风、矢量插画、绘本动画、角色动画、挤压拉伸、圆珠笔、圆珠笔涂鸦、原子笔、页边涂鸦、课本涂鸦、手画棋盘、描图纸、硫酸纸、叠片、叠层、分色片、灯箱、拷贝台、透光台、套准、定位钉、粉彩界面、粉彩 UI、Dot 风、Dot 那种风格、产品发布会界面、发布会质感、窗口卡片、macOS 窗口、界面卡片、讲解片界面页、小图标探头、阅卷、阅卷批改、批改、判卷、改卷、改作业、答题卡、试卷、考卷、测验卷、红笔批改、红笔打分、打分数、盖章批改、朱红印章、标准答案卡、长尾夹、讲解片评测 / 打分页、皮影、皮影戏、影子戏、驴皮影、灯影戏、皮影人偶、雕花戏台、戏台牌匾、亮相、钢笔淡彩、淡彩、淡彩速写、钢笔淡彩小人、针管笔、勾线笔、针管笔加水彩、线稿上色、速写卡片、速写本小人、水彩小卡、城市速写、街头速写、水笔、自来水笔、复古水粉、水粉、水粉画、不透明水粉、哑光丙烯、复古绘本、绘本插画、绘本大头像、童书插画、复古童书、大头像、大鼻子人物、针织毛衣、麻花毛衣、毛线帽、毛毡帽、卷发、胡子、蓝调绘本、蓝色绘本、软蓝绘本、蓝调童书、软蓝童书插画、蓝色童书插画、蓝色系绘本、限色绘本、蓝白绘本、现代绘本跨页、手绘绘本跨页、绘本跨页、绘本内页、干笔墨线、墨铅笔线、粉彩蜡笔质感绘本、白色毛绒动物、毛绒白熊、点彩腮红、江南园林、园林春景、春水园林、中式园林插画、古典园林插画、国风园林插画、苏式园林、细笔园林、园林风景插画、水榭、临水茶榭、亭台楼阁、粉墙黛瓦、黛瓦白墙、飞檐翘角、翼角起翘、月洞门、漏窗、冰裂纹窗、槅扇、挂落、九曲桥、曲桥、垂柳园林、碧水倒影、园林倒影、睡莲池、数字水粉风景、细腻厚涂风景、干刷色块、干笔色块、干刷、干刷插画、干笔插画、滚筒刷、滚筒色块、色块插画、大色块插画、毛边色块、刷痕色块、粗刷笔触、mid-century、世纪中期插画、中世纪现代插画、复古编辑插画、复古海报插画、水粉拼贴、撕纸色块、限色海报、暮色微缩绘本、暮色绘本、黄昏绘本、微缩绘本、黄昏转夜、昼夜交界、日夜交界、半边黄昏半边星空、粉彩黄昏、粉紫晚霞、黄昏星空、银河插画、野花坡、野花草坡、花海插画、萤火虫、放风筝插画、拼布山丘、条纹田野、小圆树、细节放大图、局部放大图、技术细节小窗、科学图版风插画、手写英文小字、晚安绘本、治愈系绘本插画、排线夜景、排线风夜景、彩铅夜景、色粉夜景、粉彩排线、短笔触夜景、笔触夜空、方向笔触、夜景版画、小版画、限量版画风、版画装裱、版痕、纸边标题、铅笔题字、夜景插画、夜空插画、深蓝夜景、靛蓝夜空、冷暖对比夜景、唯一暖光、夜里的火光、发光的云、被照亮的云、红色精灵闪电、精灵闪电、火山夜景、熔岩入海、熔岩、岩浆、火山喷发插画、海上风暴、海面倒影、光柱倒影、火星飞溅、星点、看海的人、礁石上的人、远处的小人、小人比例尺、雪夜篝火、渔火、笔记应用界面、笔记软件界面、笔记 App 界面、Obsidian 风、Obsidian 界面、Obsidian 风格、黑曜石笔记、深色笔记界面、暗色主题界面、Markdown 笔记、Markdown 编辑器、双链笔记、内部链接、关系图谱、知识图谱界面、图谱视图、局部图谱、反向链接、文件列表、侧边栏、标签页、属性栏、行内代码、代码块、mermaid、mermaid 流程图、代码块渲染成图、源码 / 阅读切换、阅读视图、引用标注、callout、读书笔记界面、知识库界面、第二大脑、讲解片里的笔记应用、应用窗口演示、白板卡片、无限白板、白板视图、画布视图、Canvas 视图、Obsidian Canvas、Obsidian 白板、笔记应用白板、卡片白板、卡片和连线、节点和连线、带箭头的连线、弯曲连线、连线标签、分组框、点阵背景、点阵白板、深色白板、深色界面卡片、彩色边卡片、勾选清单卡片、待办卡片、引用卡片、图片卡片、草图卡片、手绘平面图、缩放按钮、镜头平移、镜头缩放、卡片掉落动画、连线画出来、搬家计划、旅行计划白板、活动计划白板、头脑风暴白板、项目拆解白板、计划白板、Flexoki、Flexoki 纸面、Flexoki 配色、Flexoki 风、暖白纸、米白纸面、墨黑字、文档站风格、文档页图解、技术文档配图、图解页、一页图解、讲解片图表页、几张图讲清楚、流程图、画流程图、时序图、序列图、饼图、柱状图、条形图、对比表、参数对比、图表合集、图表墙、Mermaid 风、Mermaid 图、图表渲染器、灰底圆角框、小三角箭头、橙色聚焦框、数字滚动、计时器大数字、配方图解、步骤图解、手冲咖啡图解、菜谱图解、工作流程图解、暖调彩铅绘本、暖调彩铅、彩铅绘本、彩铅童书、彩铅童书插画、彩色铅笔绘本、彩色铅笔童书、软彩铅、彩铅叠涂、层层叠涂的彩铅、顺着形体排线、纸齿白点、纸纹透白、怀旧童书、翻绘本的感觉、温暖怀旧的绘本、暖色绘本页、巨物与小孩、大动物和小孩、巨大温柔的生物、温柔的巨兽、大乌龟、巨龟、老乌龟、背着花园的乌龟、龟背上的小花园、大龟过河、过河、小溪、踏脚石、提灯笼的小孩、黄色雨衣、纸灯笼、亮灯的窗、亮灯的小房子、黄昏小镇、成簇的毛、顺毛、毛一绺一绺、苔藓、金黄的树、彩色小镇、彩色房子、彩色街景、童话小镇、童话街景、治愈小镇、理想的生活环境、欧洲小镇、山城小镇、钟楼小镇、彩虹小镇、彩旗、三角彩旗、彩旗串、彩旗街、节日街道、节日早晨、钟楼、白色钟楼、洋葱顶、石板屋顶、曼莎屋顶、老虎窗、烟囱帽、电视天线、风向标、爬藤玫瑰、窗台花箱、铁艺阳台、台阶街、石头台阶、拱门下的台阶、湿街倒影、雨后街道、雨后的广场、水粉街景、水粉加描线、水粉平涂加细线、细节多到看不完、小红书彩色小镇、色粉小像、色粉画、软色粉、色粉笔触、色粉质感、色粉加水粉、粉彩笔触、粉彩质感、绘本角色、绘本人物、绘本小像、角色小像、人物小像、半身像、人和宠物、人和猫、人和狗、主人和宠物、抱着猫、抱着狗、橘猫、大橘、毛茸茸的猫、毛茸茸的狗、狐狸、猫围巾、把猫当围巾、白底插画、留白插画、不画背景、边缘散开、干笔散开、画到边上就散了、大眼睛、大圆眼、大腮红、红鼻头、红鼻尖、发丝、一根根头发、头发丝、飞丝、毛绒绒、蓬松的毛、温柔的小像、治愈系角色、Midjourney 色粉风、诗意万圣夜、诗意万圣节、万圣节、万圣夜、万圣节插画、万圣节绘本、万圣节头像、秋夜、秋夜插画、忧郁绘本、忧郁风、超现实绘本、诡异又温柔、瓷白的脸、瓷娃娃脸、瓷偶、脸上的红晕、红眼眶、红眼圈、红鼻头、厚眼皮、半闭的眼睛、悲伤的眼睛、不笑的小嘴、波波头、黑色波波头、银白波波头、齐刘海、刀切刘海、粗麻、麻布、麻袋布、粗麻帽子、毛毡帽、粗针织围巾、毛线手套、格子呢、格纹外套、苏格兰格子、小幽灵、床单幽灵、发光的小幽灵、发光的眼睛、罐子里的幽灵、深色叶丛、星空肖像、Midjourney 万圣风、油画棒、油画棒肖像、油画棒人像、油画棒小像、油画棒插画、油画棒头像、蜡笔肖像、蜡笔干刷、干刷肖像、干刷人像、干笔人物、粗犷笔触、纸纹白点、露白的纸纹、手作感肖像、不完美的肖像、白底人物小像、白纸上的人物、藏红花黄、橙黄配藏青、芥末黄配藏青、条纹围巾、粗针织围巾、露指手套、捧着热饮、冒热气的纸杯、冬天的早市、冬日早晨、冻红的脸颊、橙色腮红、橙红嘴唇、黑色蜡笔线、Midjourney 油画棒风、手账线描、手账风、手账风插画、手账小画、手账插画、速写本插画、速写本小画、速写本的一页、线描小人、细线插画、细线手绘、发丝细的线、细墨线、童趣手绘、可爱手绘、治愈系手绘、彩虹条纹、条纹毛衣、彩虹毛衣、彩虹条纹毛衣、彩条衣服、彩铅条纹、马克笔条纹、粉腮红、圆腮红、闭着眼睛的小人、小红嘴、单片叶子、叶脉排线、细线小树、团着睡觉的猫、读书的女孩、小人物大留白、Midjourney 手账风),或 "draw it yourself", "paint with code", "procedural painting", "watercolor / collage / colored pencil / anime / editorial / impasto oil / ukiyo-e / pixel art / clay / claymation / cyanotype / sun print / cross-stitch / embroidery / retro instrument panel / vintage radio / sticker collage / receipt / lab notebook / graph paper / chalkboard / blackboard / cyberpunk / neon city / cartoon / hand-drawn animation / isometric / 2.5D / continuous line / one-line drawing / soft 3D / 3D render / puffy letters / ball pit / shape morph / morphing / newspaper collage / Dada / ransom note / halftone / glassmorphism / aurora gradient / Bauhaus / geometric poster / screen print / synthwave / retrowave / outrun / perler beads / hama beads / artkal / fuse beads / melty beads / pegboard beads / petroglyph / rock art / rock carving / desert varnish / Egyptian tomb painting / ancient Egypt / hieroglyphs / Theban tomb / Roman mosaic / floor mosaic / tesserae / opus vermiculatum / Pompeii mosaic / stained glass / leaded glass / church window / Gothic window / grisaille / illuminated manuscript / medieval manuscript / book of hours / gold leaf / illuminated initial / blackletter / vellum / astrolabe / da Vinci notebook / Leonardo codex / Renaissance sketchbook / mirror writing / iron-gall ink / red chalk / sanguine / ornithopter / exploded view / inventor's sketch / silhouette / silhouette portrait / cut-paper profile / shade portrait / Georgian portrait / Regency portrait / oval gilt frame / letterpress / wood type / playbill / circus poster / Victorian poster / two-colour misregistration / woodcut poster / constructivism / constructivist poster / Soviet avant-garde / Russian avant-garde / Rodchenko style / photomontage poster / art deco / streamline moderne / 1930s travel poster / railway poster / airbrush poster / sunburst rays / Gatsby style / golden age comic / vintage comic book / comic cover / Ben-Day dots / four-color printing / newsprint / speech balloon / pulp cover / pop art / Warhol-style / pop silkscreen / silkscreen portrait / repeated pop portrait grid / ASCII art / text art / typewriter art / line printer / greenbar / fanfold paper / tractor feed / overstrike / printer plot / low poly / low-poly / retro 3D / 90s 3D game / PS1 style / N64 style / software rasterizer / flat shading / affine texture mapping / vertex fog / game HUD / stencil / stencil graffiti / spray paint stencil / street art / drips and overspray / Banksy-style stencil / embroidered patch / embroidery patch / iron-on patch / sew-on patch / merit badge / camp badge / merrow border / rocker patch / denim jacket patches / blueprint / technical drawing / crayon / kid's drawing / CRT terminal / green screen / thermal camera / thermal imaging / Delft tiles / Delft blue / cave painting / ochre / Lascaux-style / 1-bit / MacPaint-style / black-figure / Greek vase / pencil drawing / graphite / X-ray / baggage scanner / rubber hose / 1930s cartoon / linocut / lino print / VHS / home video / flat vector / flat illustration / storybook animation / squash and stretch / ballpoint / biro / ballpoint doodle / margin doodles / hand-drawn board game / overlay sheets / tracing-paper overlays / light box / colour separations / registration marks / acetate overlay / pastel UI / Dot-style product film / launch-film interface / macOS window cards / exam grading / grading an answer sheet / red-pen marking / graded test paper / rubber-stamped answer sheet / shadow puppet / shadow puppetry / Chinese shadow play / leather shadow puppets / backlit puppet screen / pen and wash / pen & wash / line and wash / ink and watercolour / ink and watercolor / fineliner sketch / fineliner and watercolour / sketchbook characters / sketch cards / urban sketching / water brush / gouache / retro gouache / gouache portrait / gouache illustration / opaque gouache / matte acrylic / picture-book portrait / vintage picture book / retro children's book illustration / mid-century children's book / big-nosed character portrait / cable-knit sweater / knitted bobble hat / blue picture book / soft blue picture book / soft-blue children's book illustration / modern picture book / limited-palette picture book / picture-book spread / scratchy ink line / dry-brush ink line / ink pencil line / crayon and pastel texture / chalky white marks / blue and coral palette / fluffy white bear / Jiangnan garden / Chinese garden / classical Chinese garden illustration / Chinese water garden / spring garden illustration / lush painterly garden / waterside pavilion / moon gate / lattice windows / zigzag bridge / weeping willow garden / upturned eaves / grey-tiled roof / blossom trees and reflections / lily pond with egrets / digital gouache landscape / dry-brush blocks / dry brush illustration / dry-brushed colour blocks / roller texture / brush-textured shapes / mid-century illustration / mid-century modern poster / mid-century editorial illustration / gouache collage / torn-paper collage poster / limited palette poster / scumbled texture / vintage book cover illustration / twilight storybook / dusk picture book / dusk to night sky / day and night split sky / pastel sunset sky / Milky Way illustration / wildflower meadow / wildflower hill / patchwork hills / tiny round trees / fireflies / paper kite / magnified detail inset / detail callout circle / scientific plate overlay / handwritten lowercase captions / cozy miniature illustration / bedtime story illustration / hatched nocturne / hatched night scene / pastel hatching night / coloured-pencil nocturne / directional strokes / short brush strokes sky / night print with margins / small art print / plate mark / pencilled title and caption / indigo night with one warm light / glowing cloud lit from below / red sprites / lava entering the sea / volcano at night / glowing threads and sparks / broken reflection on the sea / tiny figures for scale / Obsidian UI / Obsidian-style note app / dark note-taking app / dark-theme Markdown editor / note app window / file explorer sidebar / wiki links / backlinks / graph view / local graph / knowledge graph UI / properties and tags / inline code / mermaid code block / mermaid flowchart rendered / source vs reading view / callout block / reading notes app / second brain UI / knowledge base screen / canvas board / infinite whiteboard / dotted board / note-app canvas view / Obsidian-style canvas / cards and connectors / curved arrows between cards / edge labels / group frames / coloured card borders / task-list card / quote card / image card with a sketch / hand-drawn floor plan / zoom controls / camera pan and zoom / cards dropping in / moving plan board / Flexoki / Flexoki paper / Flexoki palette / warm paper and ink / docs-site diagrams / explainer sheet / diagram sheet / Mermaid-style diagrams / lightweight diagram renderer / flowchart / sequence diagram / pie chart / bar chart / comparison table / diagram wall / grey-bordered boxes / small triangular arrowheads / orange focus ring / rolling numbers / recipe explainer / warm pencil storybook / coloured-pencil storybook / colored pencil picture book / soft pencil textures / layered coloured pencil / pencil strokes following the form / paper tooth specks / nostalgic children's storybook / giant gentle creature and a small child / giant tortoise / tortoise with a garden on its back / stepping stones / child with a lantern / yellow raincoat / paper lantern / lit windows at dusk / tufted fur in locks / Midjourney sref 3220081856 look without an image model / colour town / colorful European town / storybook street / fairy-tale town / candy-coloured houses / hill town / bunting / pennant flags / festival street / clock tower / onion dome / slate mansard roofs / dormers / chimney pots / TV aerials / climbing roses / window boxes / wrought-iron balconies / stepped lane / wet street reflection / gouache and ink cityscape / pastel vignette / soft pastel character / chalk pastel portrait / pastel textures and painterly brushstrokes / whimsical character design / picture-book character on white / person with a pet / girl and her cat / ginger cat / cat scarf / big round eyes / rosy cheeks / red-tipped nose / wispy hair strands / fluffy fur / feathered edges / vignette on white paper / Midjourney sref 455581803 look without an image model / poetic halloween / halloween portrait / autumn night portrait / melancholic picture book / surreal storybook portrait / porcelain face / red flush round the eyes / red-rimmed eyes / red nose / heavy-lidded sad eyes / blunt black bob / straight fringe / silver bob / burlap hat / felt hat / chunky knit scarf / knitted mittens / tartan coat / plaid coat / sheet ghost / little glowing ghosts / ghost in a jar / glowing eyes / dark foliage / starry night sky / Midjourney sref 3822619412 look without an image model / oil pastel / oil-pastel portrait / oil pastel illustration / wax crayon portrait / dry brush portrait / bold dry brush strokes / textured colors / beautifully imperfect portraits / handmade aesthetic / paper tooth showing through / white specks of paper / saffron and navy / mustard and navy / striped scarf / chunky knit scarf / fingerless gloves / steaming paper cup / winter morning portrait / orange blush / red-orange lips / black crayon accents / figure vignette on white / Midjourney sref 2703086978 look without an image model / sketchbook doodle / sketchbook illustration / whimsical hand-drawn illustration / delicate ink lines / playful colors / charming characters / beautiful sketchbook aesthetic / so simple yet full of personality / fine ink line drawing / hair drawn strand by strand / rainbow-striped sweater / striped jumper / colored-pencil stripes / marker stripes / round pink blush / closed eyes with lashes / tiny red lips / leaf with vein hatching / thin line trees / steam curl / curled-up sleeping cat / small figure on a big empty page / Midjourney sref 1970397074 look without an image model" 时使用;也用于需要逐步画出(draw-on)动画的插画。单独说「剪纸」指剪纸拼贴、「刺绣」指十字绣、「丝网印刷 / screen print」指包豪斯几何;「打马赛克」是打码,不是马赛克画风;单说「蓝图」指蓝图工程图,「蓝晒 / 晒图」仍指蓝晒;「铅笔 / 素描」指铅笔素描,「彩铅」指韩国彩铅;「像素」仍指像素风,「1-bit / 黑白画图软件」指 1-bit 早期画图软件;「霓虹」仍指赛博朋克;「喷漆 / 街头涂鸦」仍指喷漆模板涂鸦,「圆珠笔 / 随手涂鸦 / 页边涂鸦」指圆珠笔涂鸦;「描图纸 / 硫酸纸 / 叠片 / 灯箱」指描图纸叠层(蓝图工程图那张描图布是晒成蓝图的,不是叠片);「Dot 风 / 粉彩界面 / 窗口卡片 / 发布会界面」指粉彩界面(纯色底 + 白色实心窗口卡片),要磨砂玻璃和弥散渐变仍用弥散玻璃;「阅卷 / 批改 / 答题卡 / 判卷 / 红笔打分」指阅卷批改,实验记录里的红笔圈和便利贴仍用实验笔记本,带「已付」橡皮章的小票拼贴仍用贴纸拼贴 · 小票;「皮影 / 皮影戏 / 影子戏」指皮影戏(透光的彩色驴皮人偶),黑纸剪出的侧影小像仍用剪影,彩纸剪贴仍用剪纸拼贴。「钢笔淡彩 / 淡彩速写 / 针管笔加水彩 / 线稿上色的速写小卡」指钢笔淡彩;单说「水彩」仍指水彩(风景、花卉的大片晕染),蓝铅笔稿 + 毛笔线 + 赛璐璐阴影的拟人小物仍用卡通手绘,「素描 / 铅笔」仍指铅笔素描。「水粉 / 复古水粉 / 绘本大头像 / 复古童书插画」指复古水粉(不透明水粉画的特写大头像);梵高式厚涂的风景、名画感仍用油画厚涂,扁平矢量、会挤压拉伸的小角色动画(「绘本动画」)仍用绘本角色动画,针管笔线稿加淡彩的速写小卡仍用钢笔淡彩,撞色多格的头像仍用波普丝网。「蓝调绘本 / 软蓝绘本 / 蓝色童书插画 / 绘本跨页」指蓝调绘本(软蓝限色的现代绘本跨页:干笔墨线 + 干蜡笔粉彩上色 + 白粉笔痕);单说「绘本」仍指绘本角色动画,「水粉 / 绘本大头像」仍指复古水粉,「编辑风 / Riso」仍指编辑风手绘,针管笔线稿加淡彩的速写小卡仍用钢笔淡彩,小孩自己画的蜡笔画仍用儿童蜡笔画。「江南园林 / 园林春景 / 中式园林插画 / 粉墙黛瓦 / 飞檐 / 月洞门 / 九曲桥」指江南园林(细笔数字水粉的园林春景:叶形小笔触堆出的繁茂树冠、繁花、垂柳、黛瓦飞檐、碧水倒影、层层远山);单说「水墨 / 山水」仍指水墨,单说「水彩」仍指水彩,动漫背景 / 赛璐璐天空仍指日本动漫,浮世绘仍是浮世绘;梵高式厚涂的风景仍用油画厚涂,皮影人偶的一场戏仍用皮影戏。「干刷色块 / 干笔色块 / 滚筒色块 / mid-century 海报插画」指干刷色块(米白纸上几大块干笔或滚筒刷出的限色色块,人物拆成几个大块面,背后一块纯色板、一旁一个小红方块);单说「水粉 / 绘本大头像」仍指复古水粉,「剪纸 / 彩纸拼贴」仍指剪纸拼贴,「丝网印刷 / screen print」仍指包豪斯几何,「Riso / 编辑风」仍指编辑风手绘,没有笔触的平滑几何色块仍用扁平矢量。「暮色微缩绘本 / 暮色绘本 / 黄昏转夜 / 昼夜交界 / 野花坡 / 细节放大图」指暮色微缩绘本(粉彩黄昏转入银河夜空、拼布山丘、几万朵小野花、很小的原创角色,加圆形放大图和手写小字);单说「绘本」仍指绘本角色动画,「蓝调绘本 / 软蓝绘本」仍指蓝调绘本,赛璐璐天空和夏日少年感仍用日本动漫,大片晕染的风景仍用水彩,整页的机械分解手稿仍用达·芬奇手稿,剖面和施工图仍用蓝图工程图。「排线夜景 / 彩铅或色粉夜景 / 短笔触夜空 / 夜景小版画 / 熔岩入海 / 精灵闪电 / 被照亮的云」指排线夜景(满画面顺着风向的短笔触、深蓝夜色里只有一个暖光、发光的丝和火星、碎的倒影、很小的人,装成带纸边和铅笔字的小版画);梵高式的厚涂漩涡和颜料浮雕仍用油画厚涂,明亮可爱的彩铅甜品仍用韩国彩铅,黑白石墨排线仍用铅笔素描,粉彩黄昏转入银河星空、满坡小野花仍用暮色微缩绘本,霓虹雨夜街道仍用赛博朋克。「Obsidian 风 / 笔记应用界面 / 深色笔记软件 / 双链笔记 / 关系图谱 / mermaid 代码块渲染成图」指笔记应用界面(深色主题的笔记应用窗口:文件列表、Markdown 正文、代码块切到阅读视图渲染成流程图、亮紫光点的关系图谱,只有一个紫色强调色);明亮的粉彩底和白色窗口卡片仍用粉彩界面,点阵无限白板上的卡片和弯曲连线用白板卡片,暖白纸面上的浅灰卡片图表用 Flexoki 纸面,磨砂玻璃和弥散渐变仍用弥散玻璃,绿屏荧光字符的老终端仍用绿屏终端 CRT,霓虹全息的未来界面仍用赛博朋克。「白板卡片 / 无限白板 / Canvas 视图 / 卡片和连线 / 点阵白板 / 分组框 / 带箭头的弯曲连线」指白板卡片(深色应用窗口里随镜头平移缩放的点阵白板:分组框、彩色边卡片、带箭头和标签的弯曲连线、清单 / 引用 / 草图卡片、右上角缩放按钮);笔记正文页、文件列表和关系图谱仍用笔记应用界面,暖白纸上的流程图、时序图和图表仍用 Flexoki 纸面,明亮的粉彩产品界面和检查结果仍用粉彩界面,一层层叠起来的图解仍用描图纸叠层。「Flexoki / Flexoki 纸面 / 暖白纸上的图解页 / Mermaid 那样的流程图、时序图、饼图、柱状图、对比表 / 讲解片里的图表页」指 Flexoki 纸面(暖白纸、墨黑字、不描边的浅灰圆角卡片,卡片里的图照轻量图表渲染器画:灰边框、墨线小三角箭头、普通标签,强调色只点在有意义的地方);手写粉笔的示意图仍用黑板板书,铅笔图表、荧光笔和便利贴仍用实验笔记本,彩色粉彩底、macOS 窗口和 ✓ / ✗ 徽章的产品界面仍用粉彩界面,深色笔记应用窗口仍用笔记应用界面,点阵无限白板上的卡片和连线仍用白板卡片,系统的微缩模型仍用等轴 2.5D,剖面和施工图仍用蓝图工程图。「暖调彩铅绘本 / 彩铅绘本 / 彩铅童书插画 / 巨物与小孩 / 大龟过河 / 纸齿白点 / 层层叠涂」指暖调彩铅绘本(暖白纸上满画面顺形体的彩铅叠涂、纸齿透出细白点、毛发成簇顺毛,大而温柔的生物和小小的孩子,黄昏暖光和橙黄的灯,没有墨线和黑色);单说「彩铅」仍指韩国彩铅(明亮可爱的甜品小物、粉嫩高光),黑白石墨仍用铅笔素描,软蓝限色、刮擦墨线加蜡笔颗粒的绘本跨页仍用蓝调绘本,粉彩黄昏转入星空、满坡小野花仍用暮色微缩绘本,不透明水粉的特写大头像仍用复古水粉,深蓝夜色里只有一个暖光的排线小版画仍用排线夜景;单说「绘本」仍指绘本角色动画。「彩色小镇 / 彩色房子 / 童话小镇 / 童话街景 / 彩旗街 / 钟楼小镇 / 水粉加描线的街景 / 有被这彩色小镇治愈到」指彩色小镇(水粉平涂加细墨线,密密的彩色房子堆上山坡,石板曼莎屋顶、白色钟楼、好几层三角彩旗、爬藤玫瑰和窗台花、湿街倒影);中式园林和古镇仍用江南园林,锡釉蓝砖上的运河小镇仍用代尔夫特蓝瓷砖,黑白刻版的雪村仍用黑白麻胶版画,彩纸剪出来的热气球小镇仍用剪纸拼贴,系统的微缩模型和小岛仍用等轴 2.5D,针管笔速写加淡彩的小卡仍用钢笔淡彩,水粉画的人物大头像仍用复古水粉,彩铅叠出来的黄昏小镇和巨物仍用暖调彩铅绘本,没有描线、没有笔触的几何色块仍用扁平矢量。「色粉小像 / 色粉画 / 绘本角色小像 / 人和宠物 / 猫围巾 / 白底不画背景、边上干笔散开的角色 / 大眼睛大腮红红鼻尖」指色粉小像(白纸上的半身角色小像,软色粉加一点水粉,大圆眼、大腮红、红鼻尖、一根根的发丝和蓬松的毛,柔和的粉蓝和奶油色里只有一组暖橙,边缘散进白纸);背后刷一块单色、看得见毛衣针脚的复古童书大头像仍用复古水粉,满画面彩铅叠涂、带天空和场景的黄昏绘本页仍用暖调彩铅绘本,软蓝限色、乱线墨线的绘本跨页仍用蓝调绘本,针管笔线稿加淡彩的速写小卡仍用钢笔淡彩,明亮可爱的彩铅甜品小物仍用韩国彩铅;「色粉夜景」仍指排线夜景,「粉彩界面」仍指产品界面。「诗意万圣夜 / 万圣节绘本 / 忧郁的瓷白脸 / 红眼眶红鼻头 / 黑色齐刘海波波头 / 粗麻帽子 / 发光的小幽灵」指诗意万圣夜(暗色画板上忧郁、超现实的秋夜绘本肖像:瓷白的脸泛红晕、半闭的厚眼皮、一整块的波波头、粗麻 / 针织 / 格子呢织物,靛蓝星空或深色叶丛里只有一处发光的点睛);白纸上不画背景、色调粉粉的角色小像仍用色粉小像,背后刷一块单色、大鼻子红脸蛋的复古童书大头像仍用复古水粉,满画面短排线、只有一个暖光的夜景小版画仍用排线夜景,粉彩黄昏转入星空的微缩风景仍用暮色微缩绘本,满画面彩铅叠涂的温暖黄昏童书页仍用暖调彩铅绘本。「油画棒 / 油画棒肖像 / 蜡笔干刷的人物 / 白纸上露着纸纹白点的粗笔触小像 / 橙黄配藏青」指油画棒肖像(浮在白色糙面纸上的人物小像:一道道平行干笔铺成的大块颜色里撒满纸纹白点,笔尾是硬的梳齿,藏红花黄、藏青、黑、一种冷蓝加橙色腮红和橙红嘴唇,黑色蜡笔只点在眼睛、眉毛和几处轮廓);同样白纸不画背景、但柔和粉粉、揉开的色粉小像仍用色粉小像,米白纸上几大块色加一块滚筒背景板的 mid-century 海报仍用干刷色块,小孩在糙纸上画的蜡笔画仍用儿童蜡笔画,梵高式厚涂的风景仍用油画厚涂。「手账线描 / 手账风 / 速写本小画 / 细线墨线加彩虹条纹 / 粉腮红闭着眼的小人」指手账线描(大片空着的暖米白纸上一个小人物和两三件道具:发丝细、略抖、不闭合的墨线,一根根分开的头发,彩铅和马克笔涂的彩虹条纹衣服,圆粉腮红、闭着的眼睛、小红嘴,单片叶子和细线小树);贴纸、小票、和纸胶带的「手帐拼贴」仍用贴纸拼贴 · 小票,橡木桌上针管笔加松散淡彩的速写小卡(「速写本小人」)仍用钢笔淡彩,满画面彩铅叠涂、带天空和场景的童书页仍用暖调彩铅绘本,白纸上粗笔干刷的人物小像仍用油画棒肖像,软色粉揉开、大圆眼的角色小像仍用色粉小像,草稿纸上的蓝色圆珠笔涂鸦仍用圆珠笔涂鸦。+description: Claude 绘图 / Claude Drawing —— 不借助任何生图模型,由 Claude 用代码一笔一笔「画」出图片(程序化绘画)。内置八十种画风:中国水墨、水彩、剪纸拼贴、韩国彩铅、日本动漫、编辑风手绘(Riso)、油画厚涂(梵高式流向笔触+颜料浮雕打光)、浮世绘木版画(晕色、木纹、墨线主版、青海波)、像素风(低分辨率+Bayer 抖动+像素字体)、黏土定格(高度图捏出的彩泥+影棚打光)、蓝晒(普鲁士蓝日光晒图,植物剪影透光)、十字绣(Aida 布十字绣+回针绣+缎面绣+法式结)、复古仪器面板(60 年代收音机/仪器正面:柚木、拉丝铝、旋钮、刻度窗、指示灯)、贴纸拼贴·小票(模切乙烯贴纸、热敏小票、和纸胶带、吊牌、橡皮章)、实验笔记本·贴纸(线圈方格本、铅笔图表、荧光笔、红笔圈、便利贴)、黑板板书(墨绿石板、粉笔颗粒、板擦残影、示意图与公式)、赛博朋克(雨夜霓虹街道、玻璃管霓虹招牌、全息广告、湿路面倒影)、卡通手绘(蓝铅笔稿、毛笔线、错位平涂、赛璐璐阴影、逐帧抖线)、等轴 2.5D(正等轴微缩模型、一个太阳照出三面明暗、悬浮数据卡)、单线画(一根不断开的线一笔画完、唯一点睛色)、柔光 3D(光线追踪的糖果色小球海和鼓鼓的软字、景深)、形变动画(一条轮廓依次变形、洋葱皮残影、缓动曲线)、报刊拼贴(牛皮纸、手撕旧报纸、网点老照片、勒索信拼贴字)、弥散玻璃(弥散渐变、磨砂玻璃卡片界面)、包豪斯几何(三原色几何、丝网印刷海报)、复古 Synthwave(切口落日、霓虹网格、镀铬字、录像带质感)、拼豆(钉板上的熔珠小管、熨烫熔合)、岩画(沙漠漆上凿出的凹坑图形、新旧凿痕、剥落)、古埃及墓室壁画(灰泥墙、红格起稿、分栏叙事、象形文字、剥落)、罗马马赛克(石子与玻璃沿轮廓一排排铺、灰缝、燕尾铭牌)、彩色玻璃花窗(哥特尖拱窗、通体着色玻璃、grisaille 彩绘与银染、铅条、透光)、泥金手抄本(羊皮纸、鹅毛笔哥特体、朱红标题、打磨金箔首字母)、达·芬奇手稿(铁胆墨水、左手排线、红粉笔、镜像手写、机械分解图)、剪影(黑纸剪出的侧影小像、薄金粉、椭圆金框)、凸版印刷海报(木活字、红黑双色错版、木刻插图)、苏联构成主义(红黑两版、斜条与楔形、西里尔大字、网点照片拼贴)、装饰艺术 Art Deco(1930 年代喷枪流线型海报、交替射线、阶梯高楼、金色 Deco 字)、黄金时代漫画(毛笔墨线、Ben-Day 网点、四色错版、新闻纸)、波普丝网(多格撞色平涂 + 错位的照相黑版)、ASCII 字符画(行式打印机、绿条连续纸、叠打)、低多边形(1999 年代 3D:平面着色、仿射贴图、逐顶点雾、15 位色抖动)、喷漆模板涂鸦(混凝土墙上多层卡纸模板喷绘、雾化与滴痕)、刺绣徽章(牛仔布上的机绣徽章:填充绣、缎面绣、锁边)、蓝图工程图(描图墨线晒成蓝底白线)、儿童蜡笔画(小孩在糙纸上的蜡笔涂抹)、绿屏终端 CRT(荧光字符画、扫描线、余辉)、热成像(先画温度场再上伪彩色)、代尔夫特蓝瓷砖(锡釉砖上的钴蓝手绘)、洞穴壁画(火光下的赭石、吹喷手印)、1-bit 早期画图软件(黑白整屏、8×8 图案填充)、古希腊黑绘陶瓶(黑釉剪影、刻线、饰带展开图)、铅笔素描(石墨排线、擦笔、边缘只剩线稿)、X 光片(安检透视、轮廓发亮、伪彩)、1930 年代黑白橡皮管动画(白手套、饼切眼、老胶片)、黑白麻胶版画(刻刀减法、手拓发花、套色错版)、VHS 家庭录像(钨丝灯偏色、色度渗色、REC)、扁平矢量(分层几何色块、七色、层间投影)、绘本角色动画(小角色挤压拉伸的真动画)、圆珠笔涂鸦(蓝红圆珠笔线稿、墨团、彩铅、页边涂鸦)、描图纸叠层(灯箱上的黑线底图 + 一张张单色描图纸叠片:正片叠底、套准十字、定位钉、绘图胶带)、粉彩界面 · Pastel UI(产品发布片式的界面画面:纯色粉彩底与大光斑、macOS 窗口卡片、胶囊与粗黑标题色条、状态标签与 ✓ / ✗ 徽章、放大镜、从卡片边探头的扁平小图标)、阅卷批改 · Exam Grading(绿毛毡桌上被红笔批改的答题卡:定位黑块、考号涂卡、得分格与阅卷栏、长尾夹夹住的标准答案卡、油墨不均的朱红印章、立体红笔、波浪线 / 圈 / 引线 / 批注 / 叉 / 圈起来的分数)、皮影戏 · Shadow Puppetry(油灯照亮的幕布上,雕空、透明染色的驴皮关节人偶:镂空纹样、阳刻空脸、雉翎盔头、线结与操纵杆、离幕时虚化的双影;雕花戏台、红漆金字牌匾、红灯笼)、钢笔淡彩 · Pen & Wash(速写小卡上的针管笔线稿 + 松散淡彩:线条抖、出头、不闭合,颜色错位出线、留白缝、干边与颗粒,不铺满的背景色块;大头、圆眼镜、点点眼、红鼻子的呆萌小人;卡片拍在木桌上,旁边放着针管笔和水笔)、复古水粉 · Retro Gouache(复古绘本风的水粉大头像:不透明水粉从暗到亮一层层盖上去,单色背景用干笔皴擦;大红鼻子、腮红、圆眼和大耳朵用几阶色值塑出来;看得见针脚的毛衣和毛线帽,一根根的头发和胡子,毛毡;最后是印刷书页的纸纹)、蓝调绘本 · Blue Picture Book(软蓝色调的现代绘本跨页:几乎只用粉蓝、矢车菊蓝、深青蓝三阶蓝加黑墨和纸白,只点一点珊瑚红、粉色腮红和芥末黄;毛笔 / 墨铅笔线干、抖、断,粗细不匀,线不闭合,暗部用快速来回的乱线排出来;颜色是干蜡笔、粉彩、干水粉,错位出线,纸纹的白点透出来;白粉笔痕压在蓝上,甩点和细尘;背景蓝块毛边、不到纸边;大圆脑袋、带高光的点点眼、点彩腮红和雀斑、火柴腿穿靴子的小人,乱线毛边的白色毛绒动物;最后印在书上:中缝和页码)、江南园林 · Jiangnan Garden(细笔园林春景,数字水粉插画:成千上万片叶形小笔触按一个太阳堆出树冠,暗芯、亮边、一簇簇的高光;白色和淡粉的繁花是一簇簇圆点花瓣,枝条从缝里露出来;垂柳是一绺一绺发丝般的细枝挂满小叶;黛瓦飞檐是真的瓦垄:筒瓦板瓦一行行、檐口瓦当滴水、翘起的翼角和卷起的脊头;粉墙月洞门、冰裂纹漏窗、翡翠绿槅扇和挂落、红灯笼、匾额;九曲石桥、石阶、小木船;碧绿湖面倒映岸上的一切,更柔、更暗,加涟漪和细竖纹;睡莲、白鹭;从前景花枝到雾里青山层层退远,墙上桥上落着叶影;最后一方小红印)、干刷色块 · Dry-Brush Blocks(mid-century 海报 / 水粉拼贴式的编辑插画:米白纸上几大块干笔或滚筒刷出的色块,颜色严格限定在森林绿、鼠尾草绿、青蓝、藏蓝、近黑和朱红,外加一点天蓝、淡青瓷和米色;每块颜色在自己的笔刷坐标系里刷:一道道平行的笔,起笔饱满、收笔干枯,两侧几乎是直边,两端梳成长短不一的毛齿,块里有顺笔的鬃毛纹、皴擦斑和露出来的纸色;背后的大色板用滚筒:近乎平涂、成簇的细点、干的两侧和几道细刮痕;色块像丝网套印或撕纸拼贴一样叠起来,撕口带一圈浅色纤维边;人物拆成几个大块面:亮暗两半朝不同方向刷的外套、几块肤色平面拼的头、粗黑框眼镜、干笔皴擦的白胡子;瓶子是竖刷的深色剪影加一道高光和小块标签;一旁一个小朱红方块;不勾线、不做渐变;最后像胶印:轻微柔化、纸纹、暗部零星白点、纸上细尘)、暮色微缩绘本 · Twilight Storybook(温柔、怀旧的黄昏绘本单页,满是微缩细节:大片粉彩黄昏天空,从顶上的薰衣草紫经玫瑰、蜜桃到地平线的暖金,柔和的平底云带、细细的光线和一轮低垂的淡日;一侧天空已经入夜:星空、带暗带的银河、弯月、流星,昼夜交界经过淡紫和靛蓝,不发灰;下面是一层层粉彩条纹的起伏山丘,拼布似的田、细细的垄、小圆树;前景是几万朵小野花铺成的坡,坡顶是色点,越往下越大:雏菊、矢车菊、虞美人、波斯菊、金盏花、毛茛、羽扇豆、勿忘我,夜的一侧整片变成月光蓝;很小、扁平、可爱的原创角色;上面叠一层科学图版的语言:圆形的「detail a」放大图,细墨线、排线、尺寸标注、标签和比例尺,几行灰色的小写英文手写字;最后是细颗粒、光晕、暗角和底边一道撕纸边)、排线夜景 · Hatched Nocturne(彩铅 / 色粉排线式的小幅夜景版画:天空、云、山和海全由密密的短笔触叠成,每片区域的笔触顺着同一股「风」走——天空斜着流、蒸汽绕着云团卷、山坡顺着坡向、海面横着长拖,每一笔色相和明度都差一点,笔毛分道、拖干的笔尾、纸纹里漏出的细缝,没有一处平滑渐变;深靛蓝、藏青、冷灰蓝的夜色里只有一个暖色光源,光是一层层加上去的发光笔触:核心黄白、外圈橙红、再外是被照亮的笔触,被照亮的蒸汽按「光 × 受光」上色,所以是红橙而不是粉;发光的细丝(会蜿蜒、分股、末端亮珠)、火星、星点;海面上被横向笔触打碎的倒影和光柱;几十像素高的小人靠一点亮色(围巾)点出来;最后装裱成小版画:米白纸边、压印的版痕、左下铅笔小标题、右下更小的说明,用细的普通字体)、笔记应用界面 · Obsidian UI(讲解片里的深色笔记应用窗口:近黑页面上一团淡紫光晕,窗口里有标签栏、细长图标栏、带缩进线的文件列表、粗黑 H1 下一道紫色短条、属性块和「#标签」、紫色的内部链接和行内代码、带语法色的 mermaid 代码块——点「阅读」后渲染成扁平深色的流程图,一个节点亮紫——紫色左边的引用标注,右栏关系图谱里被链接的笔记亮成紫色光点;全画只有一个紫色强调色,不画官方 logo)、白板卡片 · Canvas Board(深色笔记应用的白板视图:深色页面上一扇应用窗口——红黄绿三点和「.canvas」标签页的标签栏、左边一列线性图标——里面是一块随镜头平移缩放的灰点阵无限白板;分组框和浮在框上方的组名,深色圆角卡片带 2 px 的卡片色边(红、橙、黄、绿、青、紫)和一层很淡的同色底,卡片之间是从边的中点沿法线弯出去的曲线连线,末端实心箭头、中间一块白板底色的标签;卡片里是 Markdown:标题、正文、紫色高亮、等宽行内代码、勾选清单(勾上时紫色方框弹出、对勾画出、文字变灰加删除线)、紫色竖条的引用、紫色标签胶囊、颜色编号胶囊;图片卡片上方写文件名,里面可以用手绘笔触画草图(每笔画两遍、略弯、出头,手写体批注);右上角一列缩放按钮;全画只有一个紫色强调色加卡片色;所有东西都记在白板坐标里、每次按镜头重画,任意缩放都锐利,镜头能平移缩放、卡片能掉落、连线能一点点画出来)、Flexoki 纸面 · Flexoki Paper(文档站式的图解页:暖白纸(#FFFCF0) 上的墨黑字和一串暖灰,几张不描边、不投影的浅灰圆角卡片,粗黑中文标题、灰色英文类型名、等宽编号;卡片里的图照轻量图表渲染器的样子画——比底色差一级的框和 2 px 灰边(直角、圆角、胶囊、菱形、圆柱、圆)、墨线末端一个小的实心三角箭头、普通半粗体标签垫一块底色,虚线生命线和回复、带纸色缝的饼图、细网格上的柱状图、表头着色的对比表;Flexoki 的橙、红、蓝、绿、紫、青只放在有意义的地方,橙色聚焦框、黑底胶囊、字距收紧的大数字;能做成图一边一边画出来、数字滚动的动图)、暖调彩铅绘本 · Warm Pencil Storybook(暖白、有齿纹的纸上一层层叠涂的彩色铅笔绘本页:天空、山坡、草、水、一只大而温柔的生物和一个小小的孩子,全由顺着形体走向的细铅笔线叠成——天空横向长排线,山坡顺着坡势,龟壳绕着每块盾片的生长纹,脖子横过褶皱,雨衣顺着衣褶,苔藓和头发一簇簇顺毛;每块先铺一层浅色底,再上固有色、背光处叠同色系的深色,受光处罩一层暖色、阴影里罩一层冷色,每层角度错开一点、笔触交叉;蜡只挂在纸齿的峰上,同一批纸坑一层层都透出细白点,压得重、叠得多的地方才慢慢合上;后画的东西先留白再铺背景,颜色不互相混;毛是一绺一绺的:根部散开、尖端聚拢、顺着毛向,每绺受光一侧亮、背光一侧暗;没有墨线、没有黑色,只有很淡的同色轮廓;黄昏的暖光:灯笼和窗灯是一层层橙黄的发光叠涂(不是一团光晕,也不是放射线),低低的太阳给受光一侧一道暖边;水里的倒影也是一笔笔横排线;附带树、小房子、石头、鳞片、野花、纸灯笼和穿雨衣提灯笼的小孩等绘本部件)、彩色小镇 · Colour Town(不透明水粉平涂加细细的深棕墨线画的童话山城街景:高高窄窄的房子漆成番茄红、芥末黄、青绿、薄荷、珊瑚、奶白,一排压一排堆上山坡,近大远小、前后遮挡;深蓝灰的石板曼莎屋顶是一片片瓦错缝铺出来的,带老虎窗、烟囱和赤陶烟囱帽、电视天线;白色钟楼、淡蓝的天和奶白的云;三角彩旗串在好几层深度上斜穿街道,远处的小、近处的大,每面旗有一道深一点的折痕;红色爬藤玫瑰、溢出来的窗台花箱、铁艺阳台、石头台阶和扶手、路灯、吊挂的店招、拱门和彩色木门、写着字的店面和条纹遮阳篷;前景是湿亮的街面,把整条街倒映成一道道竖向的笔触;每块颜色都是带一点笔刷纹理的不透明平涂,边缘像手画的那样微微抖,和描线不完全对齐;墨线分成几段、粗细略有变化,方框的转角偶尔出头;墨是半透明的,压在红墙上是深红棕,压在玻璃上近乎黑;窗户排得整齐,但每扇都略有不同;一整面墙可以用透视单应贴成往消失点收的峡谷墙;几乎没有投影;附带钟楼、台阶、矮墙、栏杆、树、花盆、彩旗、路灯、店招、海报、咖啡桌、猫和概括的小人等部件)、色粉小像 · Pastel Vignette(白纸上的绘本角色小像,软色粉加一点水粉:一个人和他的小动物,半身、略偏一边,四周大片留白,不画背景色块、不加边框,画面在边上用干笔散开、融进白纸;颜色柔和、粉粉的——浅粉蓝的衣服上看得见顺着衣褶的干笔、奶油色的毛衣、暖肤色——只有一组暖橙饱和(橘猫、绒球、蝴蝶结这类);脸是揉开的平滑色粉:大圆眼、深色虹膜和两点白高光、一大圈腮红、红鼻尖、小嘴;头发和毛是成百上千根细丝,一绺一绺,有几根飞出轮廓,毛的轮廓蓬松地融进后面的东西;几乎不描线,只有眼皮、鼻翼、脸的背光侧几道细的软线;背后至多一枝叶子和一层很淡的铅笔小镇;附带圆眼、眉毛、腮红、鼻子、嘴、发丝、毛簇、蓬松轮廓、叶子和枝条等部件)、诗意万圣夜 · Poetic Halloween(忧郁、带一点超现实的秋夜 / 万圣节绘本肖像,暗色画板上的不透明水粉加细彩铅排线,再印出来:瓷白的脸,鼻子、脸颊、眼皮和眼睛四周泛着很重的红晕(平滑的一层红加单像素的细红斑点),下眼睑一道湿红,厚眼皮半闭、往外眼角垂,小嘴不笑,体积极简;头发是一整块雕塑般的实体——刀切一样平的齐刘海、乌黑(或银白)的波波头,几乎看不见发丝,只有一道柔和的光泽;衣物是摸得着的织物:粗麻 / 毛毡帽子(一上一下交织的粗线、线间的黑孔、毛边)、粗针织围巾和手套、斜纹织出来的格子呢外套;底子暗而沉——靛蓝夜空和星星、浓密的深色叶丛;每幅只有一处发光的点睛:眼睛和衣摆尖发着暖光的床单小幽灵,暖光照亮身边的叶子、毛线和脸的下侧;满画面一层细的印刷颗粒;附带重眼皮眼、红晕、长鼻子、小嘴、光泽带、粗麻、针织、罗纹、格子呢、毛边、掌状叶和叶丛、暖光照明和光晕、小幽灵、星星等部件)、油画棒肖像 · Oil-Pastel Portrait(白色糙面纸上的油画棒 / 蜡笔干刷人物小像,人浮在白纸上、不画背景(至多一抹天色或一块干刷的黑色投影):颜色收得紧而浓——藏红花黄 / 金盏黄、偏青的藏青和黑、一种冷蓝,加橙色腮红和橙红嘴唇;毛衣、帽子、大衣、围巾这类大块颜色用一道道平行的干笔铺满,蜡只挂在纸纹的凸起上、跳过纸坑,所以每块颜色里都撒着顺着笔拉长的纸纹白点,笔触的收尾是硬的、一把长短不一的梳齿;黑色蜡笔只点在要紧处:眼睛、眉毛、鼻孔、几笔轮廓和衣褶,不勾满轮廓线;脸就是纸本身,背光一侧几笔桃色,两块排线的橙色腮红,平涂的橙红嘴唇——简化、略歪、有表情;头发是几笔松而有劲的长笔触,针织的条纹是一段段短而粗的色条;附带干笔铺色、蜡笔线、排线腮红、短色条、干刷投影、热气、黑眼睛、粗眉、嘴唇、长发丝等部件)、手账线描 · Sketchbook Doodle(速写本里的一页小画:暖米白、带一点粉的纸上大片空着,一个小小的人物加两三件稀疏的小道具浮在纸上,不画地面和背景;发丝细的深色墨线,略抖,起笔轻、收笔挑出一个细尖,轮廓一两笔画完、接口不闭合,偶尔断开;头发是一根根分开的细线,一起顺着一个方向起伏,线与线之间露着纸;脸小而简单——闭着的弧线眼加几根睫毛(或两个小黑点)、一笔鼻子、小小的红嘴、两颗圆圆的粉腮红;衣服用彩铅和马克笔涂成一道道松散的彩虹条纹(红、黄、青绿、橙、品红、蓝),条与条之间留着纸白,每条的上下边各自游移,有的冲出墨线、有的够不到,看得见彩铅的颗粒和顺笔的道子,颜色压在一起会变(红压黄成橙);道具用细的彩色线:单片叶子带人字形叶脉排线(或在填色里留白的叶脉)、小花、几根细线叠成的小树、一缕带卷的热气、一只团着睡觉的猫;附带抖线墨线、不闭合的轮廓、发丝、条纹、彩铅 / 马克笔上色、圆腮红、闭眼、点眼、小红嘴、叶子、小花、细线树、热气、短毛刺、小涂鸦等部件)、日系扁平小插画 · Flat Spot Illustration(几幅日常小事的小插画散在白纸上,中间留足白,不画地面和背景(至多一个水洼或一道小影子):每块颜色都是平涂的不透明色块,没有渐变和明暗,只有极淡的印刷颗粒,边缘略不规整、像手剪或马克笔铺出来的;颜色克制——藏青、灰蓝和粉蓝、芥末黄、橄榄绿和墨绿、几种灰、近黑的头发,皮肤就是白纸,每幅小画里只有一个反复出现的暖红(伞、锅、碗、马克杯、一双袜子);线很少:同色的两块之间留一道白缝,深色衣服上的衣褶和接缝刻成白线,浅色衣服上画深一号的线,深色细线只画侧脸、手指和家具腿;脸几乎空白,一点眼、侧脸线上一个鼻头;头发是鼓包的一整块深色,刻两三根白发丝;手像连指手套,指缝是红线;小动作交给手画的小记号:热气的 S 形、惊讶的三短线、z、雨点;附带手剪边的平涂形状、白缝、自动选色的衣褶线、用简单零件拼的人(站、走、坐、蹲、躺)和手、鞋,伞、锅、马克杯、碗、托特包、自行车、长椅、扶手椅、沙发、猫、盆栽等道具,热气、惊讶线、z、雨等记号)。用户说「claude绘图」「用代码画」「你自己画」「不用生图模型画」「程序化绘画」,或点名以上任一画风(含黏土、彩泥、定格动画、蓝晒、晒图、十字绣、刺绣、复古面板、老式收音机、贴纸、小票、收据、手帐拼贴、实验笔记本、方格本、荧光笔、便利贴、黑板、板书、粉笔、赛博朋克、霓虹、雨夜街道、卡通、手绘卡通、逐帧手绘、抖线、等轴、2.5D、微缩模型、单线画、一笔画、线条动画、柔光 3D、3D 渲染、C4D 风、软糖字、小球海、形变、变形动画、报刊拼贴、剪报、达达、勒索信字、网点印刷、弥散渐变、玻璃拟态、毛玻璃、包豪斯、几何构成、丝网印刷、Synthwave、蒸汽波、合成器浪潮、80 年代复古、拼豆、拼拼豆、熔珠、熨豆、豆豆画、钉板、烫豆、岩画、岩刻、凿刻、石刻、沙漠漆、史前壁刻、大角羊、古埃及、埃及壁画、墓室壁画、法老时代、象形文字、尼罗河、底比斯、罗马马赛克、马赛克镶嵌、镶嵌画、石子拼画、地砖画、古罗马地板、彩色玻璃、彩绘玻璃、花窗、玻璃花窗、教堂花窗、哥特花窗、铅条玻璃、泥金手抄本、手抄本、彩饰手抄本、中世纪手稿、羊皮纸、哥特体、花体首字母、泥金、贴金、星盘、达芬奇、达·芬奇、达芬奇手稿、手稿风、文艺复兴手稿、发明手稿、镜像字、镜像书写、扑翼机、红粉笔、钢笔排线、机械草图、分解图、剪影、剪影肖像、侧影、侧面像、黑纸剪影、剪影小像、椭圆金框、乔治时代肖像、摄政时期肖像、凸版印刷、活版印刷、木活字、铅字海报、马戏团海报、复古海报、老海报、19 世纪海报、双色套印、错版、套色错位、木刻插图、构成主义、苏联海报、苏联构成主义、俄国先锋派、罗德琴科风、红黑海报、照片蒙太奇、照片拼贴海报、西里尔字、装饰艺术、装饰风、流线型、流线型海报、1930 年代海报、旅行海报、铁路海报、火车海报、喷枪画、喷笔画、阶梯高楼、射线背景、盖茨比风、黄金时代漫画、老漫画、复古漫画、美漫封面、漫画封面、Ben-Day 网点、本戴点、网点上色、四色印刷、四色错版、新闻纸、对白框、拟声字、1940 年代漫画、波普、波普艺术、波普丝网、沃霍尔风、丝网版画头像、撞色头像、多格重复头像、六宫格撞色头像、ASCII、字符画、字符艺术、文字画、行式打印机、绿条纸、连续打印纸、针孔打印纸、老电脑打印、叠打、低多边形、低面数、低模、多边形风、千禧年 3D、90 年代 3D、复古 3D 游戏、老游戏截图、PS1 风、N64 风、平面着色、线框、游戏 HUD、飞行游戏、穿环、喷漆、模板涂鸦、镂空模板、喷漆模板、模板喷绘、街头涂鸦、街头艺术、墙绘、滴漆、班克西风格、刺绣徽章、徽章、布章、臂章、刺绣贴、绣标、锁边、牛仔外套徽章、户外徽章、营地徽章、弧形条章、蓝图、工程图、施工图、蜡笔画、儿童画、绿屏终端、CRT、显像管、热成像、热像仪、温度图、代尔夫特、荷兰蓝瓷砖、洞穴壁画、史前壁画、赭石、1-bit、黑白画图软件、MacPaint 风、黑绘、古希腊陶瓶、希腊瓶画、铅笔素描、素描、铅笔画、X 光、X 光片、安检图像、橡皮管动画、黑白卡通、老动画、麻胶版画、黑白版画、藏书票、VHS、家庭录像、录像带、扁平插画、扁平风、矢量插画、绘本动画、角色动画、挤压拉伸、圆珠笔、圆珠笔涂鸦、原子笔、页边涂鸦、课本涂鸦、手画棋盘、描图纸、硫酸纸、叠片、叠层、分色片、灯箱、拷贝台、透光台、套准、定位钉、粉彩界面、粉彩 UI、Dot 风、Dot 那种风格、产品发布会界面、发布会质感、窗口卡片、macOS 窗口、界面卡片、讲解片界面页、小图标探头、阅卷、阅卷批改、批改、判卷、改卷、改作业、答题卡、试卷、考卷、测验卷、红笔批改、红笔打分、打分数、盖章批改、朱红印章、标准答案卡、长尾夹、讲解片评测 / 打分页、皮影、皮影戏、影子戏、驴皮影、灯影戏、皮影人偶、雕花戏台、戏台牌匾、亮相、钢笔淡彩、淡彩、淡彩速写、钢笔淡彩小人、针管笔、勾线笔、针管笔加水彩、线稿上色、速写卡片、速写本小人、水彩小卡、城市速写、街头速写、水笔、自来水笔、复古水粉、水粉、水粉画、不透明水粉、哑光丙烯、复古绘本、绘本插画、绘本大头像、童书插画、复古童书、大头像、大鼻子人物、针织毛衣、麻花毛衣、毛线帽、毛毡帽、卷发、胡子、蓝调绘本、蓝色绘本、软蓝绘本、蓝调童书、软蓝童书插画、蓝色童书插画、蓝色系绘本、限色绘本、蓝白绘本、现代绘本跨页、手绘绘本跨页、绘本跨页、绘本内页、干笔墨线、墨铅笔线、粉彩蜡笔质感绘本、白色毛绒动物、毛绒白熊、点彩腮红、江南园林、园林春景、春水园林、中式园林插画、古典园林插画、国风园林插画、苏式园林、细笔园林、园林风景插画、水榭、临水茶榭、亭台楼阁、粉墙黛瓦、黛瓦白墙、飞檐翘角、翼角起翘、月洞门、漏窗、冰裂纹窗、槅扇、挂落、九曲桥、曲桥、垂柳园林、碧水倒影、园林倒影、睡莲池、数字水粉风景、细腻厚涂风景、干刷色块、干笔色块、干刷、干刷插画、干笔插画、滚筒刷、滚筒色块、色块插画、大色块插画、毛边色块、刷痕色块、粗刷笔触、mid-century、世纪中期插画、中世纪现代插画、复古编辑插画、复古海报插画、水粉拼贴、撕纸色块、限色海报、暮色微缩绘本、暮色绘本、黄昏绘本、微缩绘本、黄昏转夜、昼夜交界、日夜交界、半边黄昏半边星空、粉彩黄昏、粉紫晚霞、黄昏星空、银河插画、野花坡、野花草坡、花海插画、萤火虫、放风筝插画、拼布山丘、条纹田野、小圆树、细节放大图、局部放大图、技术细节小窗、科学图版风插画、手写英文小字、晚安绘本、治愈系绘本插画、排线夜景、排线风夜景、彩铅夜景、色粉夜景、粉彩排线、短笔触夜景、笔触夜空、方向笔触、夜景版画、小版画、限量版画风、版画装裱、版痕、纸边标题、铅笔题字、夜景插画、夜空插画、深蓝夜景、靛蓝夜空、冷暖对比夜景、唯一暖光、夜里的火光、发光的云、被照亮的云、红色精灵闪电、精灵闪电、火山夜景、熔岩入海、熔岩、岩浆、火山喷发插画、海上风暴、海面倒影、光柱倒影、火星飞溅、星点、看海的人、礁石上的人、远处的小人、小人比例尺、雪夜篝火、渔火、笔记应用界面、笔记软件界面、笔记 App 界面、Obsidian 风、Obsidian 界面、Obsidian 风格、黑曜石笔记、深色笔记界面、暗色主题界面、Markdown 笔记、Markdown 编辑器、双链笔记、内部链接、关系图谱、知识图谱界面、图谱视图、局部图谱、反向链接、文件列表、侧边栏、标签页、属性栏、行内代码、代码块、mermaid、mermaid 流程图、代码块渲染成图、源码 / 阅读切换、阅读视图、引用标注、callout、读书笔记界面、知识库界面、第二大脑、讲解片里的笔记应用、应用窗口演示、白板卡片、无限白板、白板视图、画布视图、Canvas 视图、Obsidian Canvas、Obsidian 白板、笔记应用白板、卡片白板、卡片和连线、节点和连线、带箭头的连线、弯曲连线、连线标签、分组框、点阵背景、点阵白板、深色白板、深色界面卡片、彩色边卡片、勾选清单卡片、待办卡片、引用卡片、图片卡片、草图卡片、手绘平面图、缩放按钮、镜头平移、镜头缩放、卡片掉落动画、连线画出来、搬家计划、旅行计划白板、活动计划白板、头脑风暴白板、项目拆解白板、计划白板、Flexoki、Flexoki 纸面、Flexoki 配色、Flexoki 风、暖白纸、米白纸面、墨黑字、文档站风格、文档页图解、技术文档配图、图解页、一页图解、讲解片图表页、几张图讲清楚、流程图、画流程图、时序图、序列图、饼图、柱状图、条形图、对比表、参数对比、图表合集、图表墙、Mermaid 风、Mermaid 图、图表渲染器、灰底圆角框、小三角箭头、橙色聚焦框、数字滚动、计时器大数字、配方图解、步骤图解、手冲咖啡图解、菜谱图解、工作流程图解、暖调彩铅绘本、暖调彩铅、彩铅绘本、彩铅童书、彩铅童书插画、彩色铅笔绘本、彩色铅笔童书、软彩铅、彩铅叠涂、层层叠涂的彩铅、顺着形体排线、纸齿白点、纸纹透白、怀旧童书、翻绘本的感觉、温暖怀旧的绘本、暖色绘本页、巨物与小孩、大动物和小孩、巨大温柔的生物、温柔的巨兽、大乌龟、巨龟、老乌龟、背着花园的乌龟、龟背上的小花园、大龟过河、过河、小溪、踏脚石、提灯笼的小孩、黄色雨衣、纸灯笼、亮灯的窗、亮灯的小房子、黄昏小镇、成簇的毛、顺毛、毛一绺一绺、苔藓、金黄的树、彩色小镇、彩色房子、彩色街景、童话小镇、童话街景、治愈小镇、理想的生活环境、欧洲小镇、山城小镇、钟楼小镇、彩虹小镇、彩旗、三角彩旗、彩旗串、彩旗街、节日街道、节日早晨、钟楼、白色钟楼、洋葱顶、石板屋顶、曼莎屋顶、老虎窗、烟囱帽、电视天线、风向标、爬藤玫瑰、窗台花箱、铁艺阳台、台阶街、石头台阶、拱门下的台阶、湿街倒影、雨后街道、雨后的广场、水粉街景、水粉加描线、水粉平涂加细线、细节多到看不完、小红书彩色小镇、色粉小像、色粉画、软色粉、色粉笔触、色粉质感、色粉加水粉、粉彩笔触、粉彩质感、绘本角色、绘本人物、绘本小像、角色小像、人物小像、半身像、人和宠物、人和猫、人和狗、主人和宠物、抱着猫、抱着狗、橘猫、大橘、毛茸茸的猫、毛茸茸的狗、狐狸、猫围巾、把猫当围巾、白底插画、留白插画、不画背景、边缘散开、干笔散开、画到边上就散了、大眼睛、大圆眼、大腮红、红鼻头、红鼻尖、发丝、一根根头发、头发丝、飞丝、毛绒绒、蓬松的毛、温柔的小像、治愈系角色、Midjourney 色粉风、诗意万圣夜、诗意万圣节、万圣节、万圣夜、万圣节插画、万圣节绘本、万圣节头像、秋夜、秋夜插画、忧郁绘本、忧郁风、超现实绘本、诡异又温柔、瓷白的脸、瓷娃娃脸、瓷偶、脸上的红晕、红眼眶、红眼圈、红鼻头、厚眼皮、半闭的眼睛、悲伤的眼睛、不笑的小嘴、波波头、黑色波波头、银白波波头、齐刘海、刀切刘海、粗麻、麻布、麻袋布、粗麻帽子、毛毡帽、粗针织围巾、毛线手套、格子呢、格纹外套、苏格兰格子、小幽灵、床单幽灵、发光的小幽灵、发光的眼睛、罐子里的幽灵、深色叶丛、星空肖像、Midjourney 万圣风、油画棒、油画棒肖像、油画棒人像、油画棒小像、油画棒插画、油画棒头像、蜡笔肖像、蜡笔干刷、干刷肖像、干刷人像、干笔人物、粗犷笔触、纸纹白点、露白的纸纹、手作感肖像、不完美的肖像、白底人物小像、白纸上的人物、藏红花黄、橙黄配藏青、芥末黄配藏青、条纹围巾、粗针织围巾、露指手套、捧着热饮、冒热气的纸杯、冬天的早市、冬日早晨、冻红的脸颊、橙色腮红、橙红嘴唇、黑色蜡笔线、Midjourney 油画棒风、手账线描、手账风、手账风插画、手账小画、手账插画、速写本插画、速写本小画、速写本的一页、线描小人、细线插画、细线手绘、发丝细的线、细墨线、童趣手绘、可爱手绘、治愈系手绘、彩虹条纹、条纹毛衣、彩虹毛衣、彩虹条纹毛衣、彩条衣服、彩铅条纹、马克笔条纹、粉腮红、圆腮红、闭着眼睛的小人、小红嘴、单片叶子、叶脉排线、细线小树、团着睡觉的猫、读书的女孩、小人物大留白、Midjourney 手账风、日系扁平小插画、日系扁平插画、扁平小插画、日系小插画、spot illustration、小插图、点缀插画、专栏插画、杂志小插画、生活小插画、日常小插画、生活方式插画、一天里的小事、日常小事、几幅小画、白底小插画、平涂色块小人、平涂插画、无描边插画、手剪边、白线衣褶、一个红色点睛、红色点睛、藏青芥末黄、空白的脸、侧脸线、一块黑头发、热气小曲线、惊讶三短线、雨天的星期六、下雨天在家、撑红伞、喂猫、午睡、看书喝茶、煮汤),或 "draw it yourself", "paint with code", "procedural painting", "watercolor / collage / colored pencil / anime / editorial / impasto oil / ukiyo-e / pixel art / clay / claymation / cyanotype / sun print / cross-stitch / embroidery / retro instrument panel / vintage radio / sticker collage / receipt / lab notebook / graph paper / chalkboard / blackboard / cyberpunk / neon city / cartoon / hand-drawn animation / isometric / 2.5D / continuous line / one-line drawing / soft 3D / 3D render / puffy letters / ball pit / shape morph / morphing / newspaper collage / Dada / ransom note / halftone / glassmorphism / aurora gradient / Bauhaus / geometric poster / screen print / synthwave / retrowave / outrun / perler beads / hama beads / artkal / fuse beads / melty beads / pegboard beads / petroglyph / rock art / rock carving / desert varnish / Egyptian tomb painting / ancient Egypt / hieroglyphs / Theban tomb / Roman mosaic / floor mosaic / tesserae / opus vermiculatum / Pompeii mosaic / stained glass / leaded glass / church window / Gothic window / grisaille / illuminated manuscript / medieval manuscript / book of hours / gold leaf / illuminated initial / blackletter / vellum / astrolabe / da Vinci notebook / Leonardo codex / Renaissance sketchbook / mirror writing / iron-gall ink / red chalk / sanguine / ornithopter / exploded view / inventor's sketch / silhouette / silhouette portrait / cut-paper profile / shade portrait / Georgian portrait / Regency portrait / oval gilt frame / letterpress / wood type / playbill / circus poster / Victorian poster / two-colour misregistration / woodcut poster / constructivism / constructivist poster / Soviet avant-garde / Russian avant-garde / Rodchenko style / photomontage poster / art deco / streamline moderne / 1930s travel poster / railway poster / airbrush poster / sunburst rays / Gatsby style / golden age comic / vintage comic book / comic cover / Ben-Day dots / four-color printing / newsprint / speech balloon / pulp cover / pop art / Warhol-style / pop silkscreen / silkscreen portrait / repeated pop portrait grid / ASCII art / text art / typewriter art / line printer / greenbar / fanfold paper / tractor feed / overstrike / printer plot / low poly / low-poly / retro 3D / 90s 3D game / PS1 style / N64 style / software rasterizer / flat shading / affine texture mapping / vertex fog / game HUD / stencil / stencil graffiti / spray paint stencil / street art / drips and overspray / Banksy-style stencil / embroidered patch / embroidery patch / iron-on patch / sew-on patch / merit badge / camp badge / merrow border / rocker patch / denim jacket patches / blueprint / technical drawing / crayon / kid's drawing / CRT terminal / green screen / thermal camera / thermal imaging / Delft tiles / Delft blue / cave painting / ochre / Lascaux-style / 1-bit / MacPaint-style / black-figure / Greek vase / pencil drawing / graphite / X-ray / baggage scanner / rubber hose / 1930s cartoon / linocut / lino print / VHS / home video / flat vector / flat illustration / storybook animation / squash and stretch / ballpoint / biro / ballpoint doodle / margin doodles / hand-drawn board game / overlay sheets / tracing-paper overlays / light box / colour separations / registration marks / acetate overlay / pastel UI / Dot-style product film / launch-film interface / macOS window cards / exam grading / grading an answer sheet / red-pen marking / graded test paper / rubber-stamped answer sheet / shadow puppet / shadow puppetry / Chinese shadow play / leather shadow puppets / backlit puppet screen / pen and wash / pen & wash / line and wash / ink and watercolour / ink and watercolor / fineliner sketch / fineliner and watercolour / sketchbook characters / sketch cards / urban sketching / water brush / gouache / retro gouache / gouache portrait / gouache illustration / opaque gouache / matte acrylic / picture-book portrait / vintage picture book / retro children's book illustration / mid-century children's book / big-nosed character portrait / cable-knit sweater / knitted bobble hat / blue picture book / soft blue picture book / soft-blue children's book illustration / modern picture book / limited-palette picture book / picture-book spread / scratchy ink line / dry-brush ink line / ink pencil line / crayon and pastel texture / chalky white marks / blue and coral palette / fluffy white bear / Jiangnan garden / Chinese garden / classical Chinese garden illustration / Chinese water garden / spring garden illustration / lush painterly garden / waterside pavilion / moon gate / lattice windows / zigzag bridge / weeping willow garden / upturned eaves / grey-tiled roof / blossom trees and reflections / lily pond with egrets / digital gouache landscape / dry-brush blocks / dry brush illustration / dry-brushed colour blocks / roller texture / brush-textured shapes / mid-century illustration / mid-century modern poster / mid-century editorial illustration / gouache collage / torn-paper collage poster / limited palette poster / scumbled texture / vintage book cover illustration / twilight storybook / dusk picture book / dusk to night sky / day and night split sky / pastel sunset sky / Milky Way illustration / wildflower meadow / wildflower hill / patchwork hills / tiny round trees / fireflies / paper kite / magnified detail inset / detail callout circle / scientific plate overlay / handwritten lowercase captions / cozy miniature illustration / bedtime story illustration / hatched nocturne / hatched night scene / pastel hatching night / coloured-pencil nocturne / directional strokes / short brush strokes sky / night print with margins / small art print / plate mark / pencilled title and caption / indigo night with one warm light / glowing cloud lit from below / red sprites / lava entering the sea / volcano at night / glowing threads and sparks / broken reflection on the sea / tiny figures for scale / Obsidian UI / Obsidian-style note app / dark note-taking app / dark-theme Markdown editor / note app window / file explorer sidebar / wiki links / backlinks / graph view / local graph / knowledge graph UI / properties and tags / inline code / mermaid code block / mermaid flowchart rendered / source vs reading view / callout block / reading notes app / second brain UI / knowledge base screen / canvas board / infinite whiteboard / dotted board / note-app canvas view / Obsidian-style canvas / cards and connectors / curved arrows between cards / edge labels / group frames / coloured card borders / task-list card / quote card / image card with a sketch / hand-drawn floor plan / zoom controls / camera pan and zoom / cards dropping in / moving plan board / Flexoki / Flexoki paper / Flexoki palette / warm paper and ink / docs-site diagrams / explainer sheet / diagram sheet / Mermaid-style diagrams / lightweight diagram renderer / flowchart / sequence diagram / pie chart / bar chart / comparison table / diagram wall / grey-bordered boxes / small triangular arrowheads / orange focus ring / rolling numbers / recipe explainer / warm pencil storybook / coloured-pencil storybook / colored pencil picture book / soft pencil textures / layered coloured pencil / pencil strokes following the form / paper tooth specks / nostalgic children's storybook / giant gentle creature and a small child / giant tortoise / tortoise with a garden on its back / stepping stones / child with a lantern / yellow raincoat / paper lantern / lit windows at dusk / tufted fur in locks / Midjourney sref 3220081856 look without an image model / colour town / colorful European town / storybook street / fairy-tale town / candy-coloured houses / hill town / bunting / pennant flags / festival street / clock tower / onion dome / slate mansard roofs / dormers / chimney pots / TV aerials / climbing roses / window boxes / wrought-iron balconies / stepped lane / wet street reflection / gouache and ink cityscape / pastel vignette / soft pastel character / chalk pastel portrait / pastel textures and painterly brushstrokes / whimsical character design / picture-book character on white / person with a pet / girl and her cat / ginger cat / cat scarf / big round eyes / rosy cheeks / red-tipped nose / wispy hair strands / fluffy fur / feathered edges / vignette on white paper / Midjourney sref 455581803 look without an image model / poetic halloween / halloween portrait / autumn night portrait / melancholic picture book / surreal storybook portrait / porcelain face / red flush round the eyes / red-rimmed eyes / red nose / heavy-lidded sad eyes / blunt black bob / straight fringe / silver bob / burlap hat / felt hat / chunky knit scarf / knitted mittens / tartan coat / plaid coat / sheet ghost / little glowing ghosts / ghost in a jar / glowing eyes / dark foliage / starry night sky / Midjourney sref 3822619412 look without an image model / oil pastel / oil-pastel portrait / oil pastel illustration / wax crayon portrait / dry brush portrait / bold dry brush strokes / textured colors / beautifully imperfect portraits / handmade aesthetic / paper tooth showing through / white specks of paper / saffron and navy / mustard and navy / striped scarf / chunky knit scarf / fingerless gloves / steaming paper cup / winter morning portrait / orange blush / red-orange lips / black crayon accents / figure vignette on white / Midjourney sref 2703086978 look without an image model / sketchbook doodle / sketchbook illustration / whimsical hand-drawn illustration / delicate ink lines / playful colors / charming characters / beautiful sketchbook aesthetic / so simple yet full of personality / fine ink line drawing / hair drawn strand by strand / rainbow-striped sweater / striped jumper / colored-pencil stripes / marker stripes / round pink blush / closed eyes with lashes / tiny red lips / leaf with vein hatching / thin line trees / steam curl / curled-up sleeping cat / small figure on a big empty page / Midjourney sref 1970397074 look without an image model / flat spot illustration / spot illustrations / Japanese flat illustration / Japanese spot illustration / everyday life vignettes / small vignettes on white / editorial spot art / flat colour shapes / no outlines / hand-cut edges / white fold lines / one red accent / navy and mustard / powder blue / blank faces / dot eyes / black hair blob / steam squiggles / surprise marks / rainy day vignettes / slice of life illustration" 时使用;也用于需要逐步画出(draw-on)动画的插画。单独说「剪纸」指剪纸拼贴、「刺绣」指十字绣、「丝网印刷 / screen print」指包豪斯几何;「打马赛克」是打码,不是马赛克画风;单说「蓝图」指蓝图工程图,「蓝晒 / 晒图」仍指蓝晒;「铅笔 / 素描」指铅笔素描,「彩铅」指韩国彩铅;「像素」仍指像素风,「1-bit / 黑白画图软件」指 1-bit 早期画图软件;「霓虹」仍指赛博朋克;「喷漆 / 街头涂鸦」仍指喷漆模板涂鸦,「圆珠笔 / 随手涂鸦 / 页边涂鸦」指圆珠笔涂鸦;「描图纸 / 硫酸纸 / 叠片 / 灯箱」指描图纸叠层(蓝图工程图那张描图布是晒成蓝图的,不是叠片);「Dot 风 / 粉彩界面 / 窗口卡片 / 发布会界面」指粉彩界面(纯色底 + 白色实心窗口卡片),要磨砂玻璃和弥散渐变仍用弥散玻璃;「阅卷 / 批改 / 答题卡 / 判卷 / 红笔打分」指阅卷批改,实验记录里的红笔圈和便利贴仍用实验笔记本,带「已付」橡皮章的小票拼贴仍用贴纸拼贴 · 小票;「皮影 / 皮影戏 / 影子戏」指皮影戏(透光的彩色驴皮人偶),黑纸剪出的侧影小像仍用剪影,彩纸剪贴仍用剪纸拼贴。「钢笔淡彩 / 淡彩速写 / 针管笔加水彩 / 线稿上色的速写小卡」指钢笔淡彩;单说「水彩」仍指水彩(风景、花卉的大片晕染),蓝铅笔稿 + 毛笔线 + 赛璐璐阴影的拟人小物仍用卡通手绘,「素描 / 铅笔」仍指铅笔素描。「水粉 / 复古水粉 / 绘本大头像 / 复古童书插画」指复古水粉(不透明水粉画的特写大头像);梵高式厚涂的风景、名画感仍用油画厚涂,扁平矢量、会挤压拉伸的小角色动画(「绘本动画」)仍用绘本角色动画,针管笔线稿加淡彩的速写小卡仍用钢笔淡彩,撞色多格的头像仍用波普丝网。「蓝调绘本 / 软蓝绘本 / 蓝色童书插画 / 绘本跨页」指蓝调绘本(软蓝限色的现代绘本跨页:干笔墨线 + 干蜡笔粉彩上色 + 白粉笔痕);单说「绘本」仍指绘本角色动画,「水粉 / 绘本大头像」仍指复古水粉,「编辑风 / Riso」仍指编辑风手绘,针管笔线稿加淡彩的速写小卡仍用钢笔淡彩,小孩自己画的蜡笔画仍用儿童蜡笔画。「江南园林 / 园林春景 / 中式园林插画 / 粉墙黛瓦 / 飞檐 / 月洞门 / 九曲桥」指江南园林(细笔数字水粉的园林春景:叶形小笔触堆出的繁茂树冠、繁花、垂柳、黛瓦飞檐、碧水倒影、层层远山);单说「水墨 / 山水」仍指水墨,单说「水彩」仍指水彩,动漫背景 / 赛璐璐天空仍指日本动漫,浮世绘仍是浮世绘;梵高式厚涂的风景仍用油画厚涂,皮影人偶的一场戏仍用皮影戏。「干刷色块 / 干笔色块 / 滚筒色块 / mid-century 海报插画」指干刷色块(米白纸上几大块干笔或滚筒刷出的限色色块,人物拆成几个大块面,背后一块纯色板、一旁一个小红方块);单说「水粉 / 绘本大头像」仍指复古水粉,「剪纸 / 彩纸拼贴」仍指剪纸拼贴,「丝网印刷 / screen print」仍指包豪斯几何,「Riso / 编辑风」仍指编辑风手绘,没有笔触的平滑几何色块仍用扁平矢量。「暮色微缩绘本 / 暮色绘本 / 黄昏转夜 / 昼夜交界 / 野花坡 / 细节放大图」指暮色微缩绘本(粉彩黄昏转入银河夜空、拼布山丘、几万朵小野花、很小的原创角色,加圆形放大图和手写小字);单说「绘本」仍指绘本角色动画,「蓝调绘本 / 软蓝绘本」仍指蓝调绘本,赛璐璐天空和夏日少年感仍用日本动漫,大片晕染的风景仍用水彩,整页的机械分解手稿仍用达·芬奇手稿,剖面和施工图仍用蓝图工程图。「排线夜景 / 彩铅或色粉夜景 / 短笔触夜空 / 夜景小版画 / 熔岩入海 / 精灵闪电 / 被照亮的云」指排线夜景(满画面顺着风向的短笔触、深蓝夜色里只有一个暖光、发光的丝和火星、碎的倒影、很小的人,装成带纸边和铅笔字的小版画);梵高式的厚涂漩涡和颜料浮雕仍用油画厚涂,明亮可爱的彩铅甜品仍用韩国彩铅,黑白石墨排线仍用铅笔素描,粉彩黄昏转入银河星空、满坡小野花仍用暮色微缩绘本,霓虹雨夜街道仍用赛博朋克。「Obsidian 风 / 笔记应用界面 / 深色笔记软件 / 双链笔记 / 关系图谱 / mermaid 代码块渲染成图」指笔记应用界面(深色主题的笔记应用窗口:文件列表、Markdown 正文、代码块切到阅读视图渲染成流程图、亮紫光点的关系图谱,只有一个紫色强调色);明亮的粉彩底和白色窗口卡片仍用粉彩界面,点阵无限白板上的卡片和弯曲连线用白板卡片,暖白纸面上的浅灰卡片图表用 Flexoki 纸面,磨砂玻璃和弥散渐变仍用弥散玻璃,绿屏荧光字符的老终端仍用绿屏终端 CRT,霓虹全息的未来界面仍用赛博朋克。「白板卡片 / 无限白板 / Canvas 视图 / 卡片和连线 / 点阵白板 / 分组框 / 带箭头的弯曲连线」指白板卡片(深色应用窗口里随镜头平移缩放的点阵白板:分组框、彩色边卡片、带箭头和标签的弯曲连线、清单 / 引用 / 草图卡片、右上角缩放按钮);笔记正文页、文件列表和关系图谱仍用笔记应用界面,暖白纸上的流程图、时序图和图表仍用 Flexoki 纸面,明亮的粉彩产品界面和检查结果仍用粉彩界面,一层层叠起来的图解仍用描图纸叠层。「Flexoki / Flexoki 纸面 / 暖白纸上的图解页 / Mermaid 那样的流程图、时序图、饼图、柱状图、对比表 / 讲解片里的图表页」指 Flexoki 纸面(暖白纸、墨黑字、不描边的浅灰圆角卡片,卡片里的图照轻量图表渲染器画:灰边框、墨线小三角箭头、普通标签,强调色只点在有意义的地方);手写粉笔的示意图仍用黑板板书,铅笔图表、荧光笔和便利贴仍用实验笔记本,彩色粉彩底、macOS 窗口和 ✓ / ✗ 徽章的产品界面仍用粉彩界面,深色笔记应用窗口仍用笔记应用界面,点阵无限白板上的卡片和连线仍用白板卡片,系统的微缩模型仍用等轴 2.5D,剖面和施工图仍用蓝图工程图。「暖调彩铅绘本 / 彩铅绘本 / 彩铅童书插画 / 巨物与小孩 / 大龟过河 / 纸齿白点 / 层层叠涂」指暖调彩铅绘本(暖白纸上满画面顺形体的彩铅叠涂、纸齿透出细白点、毛发成簇顺毛,大而温柔的生物和小小的孩子,黄昏暖光和橙黄的灯,没有墨线和黑色);单说「彩铅」仍指韩国彩铅(明亮可爱的甜品小物、粉嫩高光),黑白石墨仍用铅笔素描,软蓝限色、刮擦墨线加蜡笔颗粒的绘本跨页仍用蓝调绘本,粉彩黄昏转入星空、满坡小野花仍用暮色微缩绘本,不透明水粉的特写大头像仍用复古水粉,深蓝夜色里只有一个暖光的排线小版画仍用排线夜景;单说「绘本」仍指绘本角色动画。「彩色小镇 / 彩色房子 / 童话小镇 / 童话街景 / 彩旗街 / 钟楼小镇 / 水粉加描线的街景 / 有被这彩色小镇治愈到」指彩色小镇(水粉平涂加细墨线,密密的彩色房子堆上山坡,石板曼莎屋顶、白色钟楼、好几层三角彩旗、爬藤玫瑰和窗台花、湿街倒影);中式园林和古镇仍用江南园林,锡釉蓝砖上的运河小镇仍用代尔夫特蓝瓷砖,黑白刻版的雪村仍用黑白麻胶版画,彩纸剪出来的热气球小镇仍用剪纸拼贴,系统的微缩模型和小岛仍用等轴 2.5D,针管笔速写加淡彩的小卡仍用钢笔淡彩,水粉画的人物大头像仍用复古水粉,彩铅叠出来的黄昏小镇和巨物仍用暖调彩铅绘本,没有描线、没有笔触的几何色块仍用扁平矢量。「色粉小像 / 色粉画 / 绘本角色小像 / 人和宠物 / 猫围巾 / 白底不画背景、边上干笔散开的角色 / 大眼睛大腮红红鼻尖」指色粉小像(白纸上的半身角色小像,软色粉加一点水粉,大圆眼、大腮红、红鼻尖、一根根的发丝和蓬松的毛,柔和的粉蓝和奶油色里只有一组暖橙,边缘散进白纸);背后刷一块单色、看得见毛衣针脚的复古童书大头像仍用复古水粉,满画面彩铅叠涂、带天空和场景的黄昏绘本页仍用暖调彩铅绘本,软蓝限色、乱线墨线的绘本跨页仍用蓝调绘本,针管笔线稿加淡彩的速写小卡仍用钢笔淡彩,明亮可爱的彩铅甜品小物仍用韩国彩铅;「色粉夜景」仍指排线夜景,「粉彩界面」仍指产品界面。「诗意万圣夜 / 万圣节绘本 / 忧郁的瓷白脸 / 红眼眶红鼻头 / 黑色齐刘海波波头 / 粗麻帽子 / 发光的小幽灵」指诗意万圣夜(暗色画板上忧郁、超现实的秋夜绘本肖像:瓷白的脸泛红晕、半闭的厚眼皮、一整块的波波头、粗麻 / 针织 / 格子呢织物,靛蓝星空或深色叶丛里只有一处发光的点睛);白纸上不画背景、色调粉粉的角色小像仍用色粉小像,背后刷一块单色、大鼻子红脸蛋的复古童书大头像仍用复古水粉,满画面短排线、只有一个暖光的夜景小版画仍用排线夜景,粉彩黄昏转入星空的微缩风景仍用暮色微缩绘本,满画面彩铅叠涂的温暖黄昏童书页仍用暖调彩铅绘本。「油画棒 / 油画棒肖像 / 蜡笔干刷的人物 / 白纸上露着纸纹白点的粗笔触小像 / 橙黄配藏青」指油画棒肖像(浮在白色糙面纸上的人物小像:一道道平行干笔铺成的大块颜色里撒满纸纹白点,笔尾是硬的梳齿,藏红花黄、藏青、黑、一种冷蓝加橙色腮红和橙红嘴唇,黑色蜡笔只点在眼睛、眉毛和几处轮廓);同样白纸不画背景、但柔和粉粉、揉开的色粉小像仍用色粉小像,米白纸上几大块色加一块滚筒背景板的 mid-century 海报仍用干刷色块,小孩在糙纸上画的蜡笔画仍用儿童蜡笔画,梵高式厚涂的风景仍用油画厚涂。「手账线描 / 手账风 / 速写本小画 / 细线墨线加彩虹条纹 / 粉腮红闭着眼的小人」指手账线描(大片空着的暖米白纸上一个小人物和两三件道具:发丝细、略抖、不闭合的墨线,一根根分开的头发,彩铅和马克笔涂的彩虹条纹衣服,圆粉腮红、闭着的眼睛、小红嘴,单片叶子和细线小树);贴纸、小票、和纸胶带的「手帐拼贴」仍用贴纸拼贴 · 小票,橡木桌上针管笔加松散淡彩的速写小卡(「速写本小人」)仍用钢笔淡彩,满画面彩铅叠涂、带天空和场景的童书页仍用暖调彩铅绘本,白纸上粗笔干刷的人物小像仍用油画棒肖像,软色粉揉开、大圆眼的角色小像仍用色粉小像,草稿纸上的蓝色圆珠笔涂鸦仍用圆珠笔涂鸦。「日系扁平小插画 / spot illustration / 几幅日常小事的小插画 / 平涂色块的小人加一个红色点睛 / 白线衣褶」指日系扁平小插画(几幅小画散在白纸上:平涂的不透明色块、手剪似的边、极淡的颗粒,藏青、粉蓝、芥末黄、橄榄绿、灰和近黑的头发,每幅只有一个红色的东西,衣褶刻成白线,脸是白纸加一道侧脸线和一点眼);分层几何色块、层间投影的风景和夜景仍用扁平矢量,发丝细墨线加彩虹条纹、一个小人物占一页的仍用手账线描,针管笔线稿加淡彩的速写小卡仍用钢笔淡彩,米白纸上几大块干刷色的 mid-century 海报仍用干刷色块,白纸上粗笔干刷的人物小像仍用油画棒肖像,产品发布片的界面仍用粉彩界面。---# Claude 绘图@@ -93,6 +93,7 @@ description: Claude 绘图 / Claude Drawing —— 不借助任何生图模型| 诗意万圣夜 · Poetic Halloween | `lib/poetichalloween.py` · `PoeticHalloween` | `examples/poetichalloween_ghost_jar.py` 罐子里的小幽灵 · The Ghost in the Jar(1920×1080 的秋夜绘本肖像,暗色画板上的水粉加细排线:十月的最后一夜,一个苍白的孩子站在深色的树丛里,戴一顶软塌的粗麻钟形帽(帽檐垂着松开的麻线,一圈麻绳打了个小蝴蝶结),乌黑的齐耳波波头、刀切一样平的齐刘海,整块头发上一道柔和的光泽;瓷白的脸,眼睛一圈、鼻梁和脸颊泛着红晕(平滑的红加细密的红斑点),厚眼皮半闭、往外眼角垂,低头看着手里的罐子,虹膜里映着一点暖光,红鼻尖,不笑的小嘴;深红的粗针织围巾围到下巴,一头垂在胸前,深色格子呢外套(藏青、墨绿加细的锈红和赭黄线,斜纹织出来,格子随衣褶起伏),两颗牛角扣;一双深红针织手套从两边扶着一个玻璃罐,罐口蒙着粗麻布、用麻绳扎住,罐子里一个床单小幽灵发着光,暖光照亮手套、玻璃边和她的下巴;树丛里和星空中还有五个小幽灵(银色细丝的身子,琥珀色发光的眼睛,衣摆每个尖一颗光珠),身边的叶子被照成橄榄色和橙色,其余的叶子几乎是黑绿的,每片都往后面投一块影子;靛蓝夜空里有细的斜笔触和星星;照在暗色画板上作画的顺序画:画板 → 粉笔起稿 → 夜空和星星 → 深色叶丛 → 平涂大块 → 极简的体积 → 织物 → 五官 → 小幽灵和它们的暖光 → 前景叶子和最后几笔;`--stages` 出 9 个阶段加成品) | 约 10 秒 || 油画棒肖像 · Oil-Pastel Portrait | `lib/oilpastel.py` · `OilPastel` | `examples/oilpastel_warm_cup.py` 捧着一杯热的 · Something Warm to Hold(1600×1600 的白纸人物小像,油画棒干刷:冬天早上的露天市集,一个年轻女人把黑头发松松地挽成一个髻,双手捧着一个纸杯举到胸前,低头看着它,热气从杯口卷上来、飘过她的脸边;脸颊、鼻尖和耳朵冻得发红(两块排线的橙色腮红、一点橙红的鼻尖),平涂的橙红嘴唇,压低的厚眼皮下一对黑眼睛;藏红花黄的粗针织围巾在脖子上绕两圈、围到下巴,一头垂在胸前,上面是一段段藏青的短色条,末端一排流苏;藏青大衣用一道道长的平行干笔铺满,满是顺着笔拉长的纸纹白点,下摆一道道收成长短不一的梳齿;冷蓝的露指针织手套,一只手的四根手指绕在牛皮纸杯套前面,另一只手的拇指搭在上面,黑色塑料杯盖;没有背景,人浮在白纸上;照油画棒画家的顺序画:白纸 → 大衣和袖子 → 围巾 → 头发 → 肤色(背光一侧的桃色、脖子、耳朵、手指)→ 杯子和手套 → 条纹和罗纹 → 黑色蜡笔的点睛 → 五官 → 热气和最后几笔飞出来的头发;`--stages` 出 9 个阶段加成品) | 约 6 秒 || 手账线描 · Sketchbook Doodle | `lib/sketchbook.py` · `Sketchbook` | `examples/sketchbook_reading_hour.py` 读书的午后 · The Reading Hour(1600×1600 的速写本一页,大片暖米白纸空着,画都在下半部:一个女孩坐在小木凳上读书,双手把书举在胸前,低着头、闭着眼,读得入了神;中分的黑色长发一根根垂过肩膀,一侧别着一朵橙色小雏菊发夹;彩虹条纹毛衣(红、黄、青绿、橙、品红、蓝,条与条之间留着纸白,袖子上的条纹绕着胳膊转,有的冲出墨线、有的够不到),红色罗纹领口、芥末黄袖口;书是青绿色封面,上面画着一个小太阳,手指搭在封面边上,书拿得有点歪;蓝色百褶裙,白袜子、红鞋,一只脚垂得高一点、两只脚尖朝里;她的灰色虎斑猫在旁边地上团成一团睡着,旁边一杯冒热气的马克杯,热气一直卷到空白的纸上;另一边一盆植物伸出几片叶子(一片只用墨线画出人字形叶脉、一片蓝色的叶脉留白)和一个红花苞;右上方飘下一片黄叶;不画地面和背景;照速写本插画的顺序:空纸 → 细墨线线稿(脸、脖子、毛衣和袖子、书和手指、裙子、腿、鞋、后面的凳子)→ 一根根的头发 → 彩铅 / 马克笔的条纹 → 其他颜色(裙子、领口袖口、书皮、鞋、凳子)→ 猫 → 植物 → 马克杯和热气 → 脸(闭眼、鼻子、腮红、小嘴)→ 飘落的叶子和一个小涂鸦;`--stages` 出 9 个阶段加成品);`examples/sketchbook_kite_day.py` 放风筝 · Kite Day(1920×1080 的宽页,给讲解片用:一个穿条纹上衣、芥末黄短裤的小男孩站在空白页的左边,一只胳膊举着线轴,仰着头冲他的风筝笑;风筝飞在右上方,是红、黄、青绿、蓝四块的菱形,拖着一条挂着小蝴蝶结的长尾巴,一根发丝细的风筝线横穿整页;他身后两棵红线和绿线画的细树(绿的那棵点着粉色花苞),右边远处一棵小黄树,几丛草,两片叶子被风吹着走,两道轻轻的风;`--stages` 出 8 个阶段加成品) | 约 2.4 秒 / 约 1.4 秒 |+| 日系扁平小插画 · Flat Spot Illustration | `lib/spotillo.py` · `SpotIllustration` | `examples/spotillo_rainy_saturday.py` 雨天的星期六 · A Rainy Saturday(1500×2000 的白纸上散着五幅小画,讲两个人下雨的星期六:一个人撑着红伞出门,托特包里探出一根大葱和一截法棍,一脚踩进水洼溅起几道水花,伞外斜斜地下着雨;一个人系着米色围裙,在橱柜台面上用木勺搅一锅红珐琅锅里的汤,三缕热气卷上来;沙发上午睡,红袜子搭在扶手边,一本书扣在胸口,z z,黑猫在沙发前团成一团也睡着;一个人蹲下来把一碗猫粮放到地上,黑猫刚发现,头顶三道惊讶的短线;一个人窝在橄榄绿的扶手椅里低头看书,小凳上一只红马克杯冒着热气;每幅一个红色的东西(伞、锅、袜子、碗、马克杯),平涂色块、手剪似的边、白线刻出的衣褶和同色之间的白缝,脸是白纸加侧脸线和一点眼;一幅一幅画,最后统一加雨、热气、惊讶线和 z;`--layout wide` 把同样五幅排成 1920×1080(动图和画廊的宽页用),`--stages` 出空纸和五幅小画 6 个阶段加成品) | 约 1 秒 |各画风共用 `lib/core.py` 里的底层工具:噪声、模糊、样条曲线、多边形遮罩、有机轮廓 `blob_pts`、毛笔 `bristle_stroke`、中文字体查找;新四种还用到补零平移 `shift`、文字遮罩 `text_mask`、西文字体查找 `latin_font`/`load_font`,以及高度图打光 `height_normals`、`height_shadow`(沿光线步进的投影)、`ambient_occlusion`。@@ -175,7 +176,8 @@ description: Claude 绘图 / Claude Drawing —— 不借助任何生图模型- 一两个讨喜的角色的小像:一个人和他的小动物(猫、狗、狐狸)、温柔的一刻(抱着、依偎、对视)、人设卡和头像,要一眼就是「绘本里的色粉加一点水粉」——白纸上不画背景,画到边上就干笔散开,大圆眼、大腮红、红鼻尖,一根根的发丝和蓬松的毛,柔和的粉彩色里只有一种暖橙,讲解片里「这个人 / 这只宠物 / 陪伴」的页,小红书头像和封面 → 色粉小像(要复古童书味、背后刷一块单色、看得见毛衣针脚的大头像用复古水粉;要满画面彩铅叠涂、有天空有场景的黄昏绘本页用暖调彩铅绘本;要软蓝限色、乱线墨线的绘本跨页用蓝调绘本;要针管笔线稿加淡彩的速写小卡用钢笔淡彩;要明亮可爱的彩铅甜品小物用韩国彩铅);- 秋天和万圣节的夜晚、忧郁又有点超现实的一刻:一个苍白的孩子或年轻人独自站在夜里,手里捧着一点光或一个发光的小东西,身边有几个发光的小幽灵,要一眼就是「诗意的万圣节绘本」——瓷白的脸上一圈红晕、半闭的厚眼皮、刀切的黑色波波头,摸得着的粗麻帽子、粗针织围巾、格子呢外套,暗沉的靛蓝夜空和深色叶丛里只有一处暖光,讲解片里「孤独 / 守护 / 秋天 / 夜晚」的页,万圣节海报、头像和小红书封面 → 诗意万圣夜(要白纸上不画背景、粉粉的温柔角色小像用色粉小像;要背后刷一块单色、看得见毛衣针脚的复古童书大头像用复古水粉;要深蓝夜色里只有一个暖光、满画面短排线的小版画用排线夜景;要粉彩黄昏转入星空、满坡小野花的微缩风景用暮色微缩绘本;要满画面彩铅叠涂、温暖治愈的黄昏童书页用暖调彩铅绘本);- 一个人的小像或半身像(街上的路人、冬天捧着热饮的人、戴帽子的姑娘、「一个人在做一件小事」),人设卡、头像和小红书封面,要一眼就是「手画的油画棒 / 蜡笔干刷」——白纸上不画背景,颜色收得紧而浓(藏红花黄、藏青、黑、一种冷蓝,橙色腮红、橙红嘴唇),大块颜色用粗笔一道道铺满、露着纸纹白点,笔触收尾干而硬,黑色蜡笔只点在眼睛和几处轮廓,脸简化、略歪、有表情,讲解片里「这个人 / 用户画像 / 一个普通人的一刻」的页 → 油画棒肖像(要柔和粉粉、揉开的色粉加一个小动物用色粉小像;要米白纸上几大块色、背后一块滚筒色板的 mid-century 海报用干刷色块;要背后刷一块单色、看得见毛衣针脚的复古童书大头像用复古水粉;要小孩画的蜡笔画用儿童蜡笔画;要梵高式的厚涂漩涡用油画厚涂);-- 一个小人物的小日常(读书、喝茶、浇花、撸猫、放风筝,「一个人慢慢地做一件小事」),手账、日记和读书笔记的配图,小红书封面和头像,讲解片里「轻松的小场景 / 生活方式 / 慢下来」的页,要一眼就是「手账风 / 速写本里的小画」——大片空着的暖米白纸,发丝细、略抖、不闭合的墨线,一根根分开的头发,彩铅马克笔涂的彩虹条纹衣服,圆圆的粉腮红、闭着的眼睛和小红嘴,道具只有两三件(单片叶子、小花、细线小树、一缕热气、团着睡觉的猫) → 手账线描(要橡木桌上的速写小卡、针管笔加松散淡彩、搞笑的街坊用钢笔淡彩;要满画面彩铅叠涂、天空和场景俱全的温暖童书页用暖调彩铅绘本;要软蓝限色、乱线墨线的绘本跨页用蓝调绘本;要白纸上粗笔干刷的人物小像用油画棒肖像;要软色粉揉开、大圆眼的角色小像用色粉小像;要小孩画的蜡笔画用儿童蜡笔画;要草稿纸上的圆珠笔涂鸦用圆珠笔涂鸦)。+- 一个小人物的小日常(读书、喝茶、浇花、撸猫、放风筝,「一个人慢慢地做一件小事」),手账、日记和读书笔记的配图,小红书封面和头像,讲解片里「轻松的小场景 / 生活方式 / 慢下来」的页,要一眼就是「手账风 / 速写本里的小画」——大片空着的暖米白纸,发丝细、略抖、不闭合的墨线,一根根分开的头发,彩铅马克笔涂的彩虹条纹衣服,圆圆的粉腮红、闭着的眼睛和小红嘴,道具只有两三件(单片叶子、小花、细线小树、一缕热气、团着睡觉的猫) → 手账线描(要橡木桌上的速写小卡、针管笔加松散淡彩、搞笑的街坊用钢笔淡彩;要满画面彩铅叠涂、天空和场景俱全的温暖童书页用暖调彩铅绘本;要软蓝限色、乱线墨线的绘本跨页用蓝调绘本;要白纸上粗笔干刷的人物小像用油画棒肖像;要软色粉揉开、大圆眼的角色小像用色粉小像;要小孩画的蜡笔画用儿童蜡笔画;要草稿纸上的圆珠笔涂鸦用圆珠笔涂鸦);+- 几件日常小事排在一张白纸上(喝一杯热的、下雨天出门、煮汤、喂猫、看书、午睡、骑车、做饭),杂志 / 书籍内页和专栏的小插图(spot illustration),生活方式和「一天里的几个瞬间」,讲解片里「几个使用场景 / 一组小习惯 / 生活的几个片段」的页,要一眼就是「日系扁平小插画」——几幅小画散在白纸上、不画地面和背景,每块颜色都是平涂的不透明色块,边缘略不规整,颜色克制(藏青、灰蓝和粉蓝、芥末黄、橄榄绿和墨绿、几种灰、近黑的头发),每幅里只有一个红色的东西,衣褶用白线刻进颜色里,线很少,脸几乎空白(一点眼、一道侧脸线) → 日系扁平小插画(要分层几何色块、层间投影的风景和夜景用扁平矢量;要发丝细的墨线加彩铅条纹、一个小人物占一页用手账线描;要针管笔线稿加淡彩、搞笑的街坊速写小卡用钢笔淡彩;要米白纸上几大块干刷色、背后一块色板的 mid-century 海报用干刷色块;要白纸上粗笔干刷的人物小像用油画棒肖像;要产品发布片的界面页用粉彩界面)。每种画风一幅范例作为质量基准(范例都不用禅意主题);水墨另加一幅「月印万川」(留白托月、水面倒影)。@@ -1393,6 +1395,24 @@ from core import spline, curve, blob_pts, fbm1d, blur, polygon_mask- 颜色用 `PAINTS` 里的名字(paper paper_light white;ink ink_soft sepia graphite grey forest_ink;red scarlet vermilion coral orange yellow gold mustard teal turquoise aqua blue cobalt navy sky magenta pink rose violet;cheek blush lip;leaf olive sage moss forest terracotta ochre tan wood cream ginger stone)或 '#rrggbb'。- 范例的场景脚本先把所有形状的遮罩算好(`plan()`,存成 uint8),描每一层的线时把它前面所有东西的遮罩 `grow()` 一点传给 `avoid`(书和手指 > 袖子 > 头发 > 脸 > 脖子 > 毛衣 > 裙子 > 腿和鞋 > 凳子),上色时也 `avoid` 前面的东西;头发只绕开「看得见的脸」(脸的椭圆减去发际线以上),所以额头上方被头发盖住;浅色要放在深色上时(黑发里的小雏菊发夹、青绿书皮上的黄太阳)先在深色里把位置留出来,因为颜色是正片叠底,叠上去只会更暗。+**日系扁平小插画 `SpotIllustration`**:+- 思路:照日系 spot illustration 的做法,几幅小画散在白纸上,每幅各自从后往前叠平涂的不透明色块(远处的腿和胳膊 → 近处的腿 → 脖子和上衣 → 头和头发 → 近处的胳膊和手,道具用 `hooks` 插在中间),最后统一加小记号(雨、热气、惊讶线、z);不画地面和背景,至多一个水洼或一道小影子。+ - 形状:一块颜色就是一条闭合轮廓(点列)。下刀前先按弧长重采样,再沿法向推一个周期的低频起伏加一层细的(`wobble` 是幅度,单位 px × k;`lumps` 是波长,头发用短的,鼓包更多),圆有点鼓包、直边会「呼吸」;Pillow 在 3 倍超采样、只有包围盒大小的小块(`Patch`)里填,再拿细噪声对边缘取阈值,边缘毛一点点。颜料不透明:新 = 旧 + 遮罩 ×(颜色 − 旧);`clip=` / `avoid=` 让一块只画在别的块里面 / 外面。+ - 白缝:`gap=` 在落一块颜色之前先在它周围刻一道白缝——同色两块之间露出来的纸(毛衣上的胳膊、外套下的裤腿、沙发上的坐垫和扶手);白缝是这块的遮罩模糊后按中尺度噪声取阈值,所以有宽有窄,`gap_keep` 之外的那部分边上没有缝。+ - 线:两头收尖、圆头的细带,沿略抖的路径,4 倍超采样。`fold()` 自己看底下是什么颜色:深色和中间色的布料上刻白线(亮度 < 0.74),浅色布料上画深一号的线;`cut()` 就是白线。+ - 人:用简单零件按从后往前的顺序拼(远腿、远胳膊和手、近腿、脖子和上衣、头和头发、近胳膊和手;蹲着时近腿在上衣前面):`limb()` 袖子或裤腿是一根粗管子,袖口 / 裤口平切;`torso()` 宽松的方上衣,在自己的坐标系里搭(所以躺着也对);`head()` 白纸的脸、一道侧脸线(鼻头、嘴唇、下巴)、一点眼、一块鼓包的头发和两三根刻进去的白发丝;`hand()` 像连指手套的白手,前沿四个指头鼓包,细轮廓,指缝是红线;`shoe()` 球鞋,或只穿袜子的脚。`person()` 从姿势预设('stand' 'walk' 'sit' 'crouch' 'reach')画一整个人:`rel` 以头高为单位改任意关节,`rot` 转整个人(-90 就是仰面躺下、头朝左),肘、膝、小腿和下摆自动加衣褶,`hooks` 在两层之间插进道具(伞柄在近处的手下面、书在近处的胳膊下面、扶手椅的扶手盖住坐着的人)。+ - 道具和记号:马克杯、碗、锅、托特包、伞、自行车、长椅、椅子、扶手椅(近处的扶手单独返回、画完人再画)、沙发、小凳、桌子、灶台 / 橱柜、盆栽、书(打开、合上、扣着)、坐着的猫、团着睡的猫、窗;热气的 S 形、惊讶的三短线、z、雨点、运动短线、一道小影子。+ - 收尾:`finish()` 只记参数、在 render 里加(每张阶段快照都和成品一致,要在画第一笔之前调用):颜色里一层软的斑驳和细颗粒、零星几个发白的小点、空白纸上极淡的纸纹(空白纸角上约 0.5 级,参考图 0.44–0.48 级)、极轻的柔化。+- 构造:`SpotIllustration(W, H, seed, keep_stages=True, stages_dir=None)`,先 `finish()` 再 `paper(tone)`。坐标是整张画布的像素;`k` = min(W, H) / 1000,缩放默认线宽和起伏;人的尺寸 `u` 是一个头高(px),姿势预设里的关节都以 u 为单位、原点在两脚之间的地面上、面朝右(`facing=-1` 镜像)。+- 轮廓:`ellipse(cx, cy, rx, ry, rot)`、`rrect(x0, y0, x1, y1, r)`、`blob(cx, cy, rx, ry, rough, rot)`、`curve(pts)`(闭合样条)、`tube(path, widths, cap)` 返回点列。+- 上色:`shape(pts, colour, smooth, wobble, rough, gap, gap_keep, clip, avoid, alpha, lumps)` 返回 `Patch`;`knock(pts)` 白纸色的形状;`line(path, width, colour, taper, wobble, clip, avoid, smooth, closed, tip)`;`cut(path, width)`;`fold(path, width, colour, clip)`;`dot(x, y, r, colour)`;`union(*patches)`、`grow(patch, px)`、`under(path)`(路径下面的平均颜色)。+- 人:`limb(path, widths, colour, cap, gap, gap_keep)`;`torso(sh_back, sh_front, hem_back, hem_front, colour, facing, collar, bulge, gap, hood)`;`head(cx, cy, r, facing, turn, tilt, hair, hair_colour, eye, ear, strands, skin, line, mouth, fringe, hat)` 返回脸上几个点(下巴、后颈、眼、鼻、嘴、头顶);`hair(head, style, colour, strands, fringe, hat)`('bob' 'short' 'bun' 'long' 'cap');`neck(top, bottom, w)`;`hand(x, y, angle, size, pose, facing, finger)`('grip' 'fist' 'open' 'flat' 'cup');`shoe(x, y, angle, size, colour, facing, sole, line, laces)`(`line=None` 是只穿袜子的脚);`pose(name, x, y, u, facing, rot, rel, **joints)` 返回关节;`person(x, y, u, facing, pose, outfit, hooks, rel, rot, J, order, folds, **joints)`,`outfit` 里给 top bottom hair hair_style shoes sole laces socks eye turn tilt skin hood sleeve apron hand_n hand_f strands fringe hat(`shoes=None` 只穿袜子,`hand_n=None` 不画那只手)。+- 道具:`mug(x, y, h)`、`bowl(x, y, w, fill)`、`pot(x, y, w)`、`bag(x, y, w, h)`、`umbrella(x, y, r, angle, handle_len)`、`bicycle(x, y, size, facing)`、`bench(x0, x1, y, h)`、`chair(x, y, h, facing)`、`armchair(x, y, w, h, facing)`(返回的 `'arm'` 是一个函数,画完人再调用)、`sofa(x0, x1, y, h)`、`stool(x, y, w, h)`、`table(x0, x1, y, h)`、`stove(x0, x1, y, h)`、`plant(x, y, h, pot, leaf)`、`book(x, y, w, angle, open_)`(`open_` 取 True / False / 'tent')、`cat_sit(x, y, h, facing, head_down, eye)`、`cat_curl(x, y, w)`、`window(x0, y0, x1, y1)`;家具的 `y` 都是地面。+- 记号:`steam(x, y, h, n)`、`bang(x, y, r, angle)`、`zzz(x, y, size)`、`rain(x0, y0, x1, y1, n, slant)`、`ticks(x, y, r, angle, n)`、`shadow(cx, cy, rx, ry)`。+- 收尾:`finish(grain, speckle, soft)`;`render()`、`composite()`、`stage(name)`、`save(path, stages_dir)`;`save('x.jpg')` 默认 quality 92、4:4:4 色度。+- 颜色用 `PAINTS` 里的名字(paper white ink line black;navy_deep navy blue slate powder powder_light;mustard mustard_light olive green sage;grey_light grey grey_mid grey_dark cream skin wood wood_light;red red_deep red_line pink)或 '#rrggbb'。+- 范例的每幅小画是一个函数 `f(s, x, y, u)`(原点在地面、u 是头高),所以同样五幅可以排成竖幅(`--layout sheet`,1500×2000)或 16:9(`--layout wide`,1920×1080);雨、热气、惊讶线和 z 先收进 `MARKS`,五幅都画完再统一加。+**顺序**:都是先远后近、先大后小,文字最后叠加。水墨的雾要画在它该吞没的东西之后;水彩的叶梗要先画,并且只画在叶子外面。## 三、毛病清单(都真实出现过)@@ -2694,6 +2714,28 @@ from core import spline, curve, blob_pts, fbm1d, blur, polygon_mask| 放风筝的男孩:几绺头发各画各的,头顶露缝,像一顶假发;红嘴唇在男孩脸上像口红 | 一次 `hair()` 用六条导线从后颈一路扇到刘海,相邻导线之间都有头发(两边分开的地方自然翘起一撮);嘴改成一道上弯的线加线下一点红 || 正方形整页缩到动图的 405 px(0.25 倍),发丝细的墨线淡得几乎看不见 | 动图先裁出画周围 1100×1100 的一块再缩(0.37 倍),见第四节 |+**日系扁平小插画**++| 问题 | 改法 |+|---|---|+| 头飘在领口上面,中间一根细棍似的脖子 | 姿势预设里头往下挪(站姿头心 −5.5 → −5.2 个头高),脖子是一截白纸色的短管,前面只有一小段细线;下巴几乎贴着领口 |+| 近处的胳膊和同色的毛衣连成一片,看不出胳膊 | 近处的胳膊和腿加 `gap`(白缝),胳膊 `gap_keep` 0.92、腿 0.85;第一版白缝的阈值比较写反了,只有约 8 % 的边上有缝,改过来 |+| 头顶两道平行的白弧,像后脑勺上一双闭着的眼睛 | 白发丝改成短的、几乎是直的,位置错开,顺着头发往脸的方向 |+| 肘弯里的白色 Z 字衣褶像闪电 | 弯的内侧一道软弧,旁边再加一道短的 |+| 手是爪子:手套尖上几道发散的红线 | 握着东西的手前沿做出四个指头鼓包,细轮廓沿鼓包走,红线从指缝往回画到指根 |+| 头发是一顶光滑的头盔 | 头发轮廓起伏的波长 80 → 34(`lumps`),后颈加两撮收尖的发梢;下巴旁边那撮在躺着的人身上像鬓角,去掉 |+| 灶台是一个灰盒子上两个大黑点,像一张脸 | 改成橱柜:木色台面、门缝、一排小旋钮、两个把手 |+| 扶手椅的靠背像一块冲浪板;加了扶手又像一大块垫子盖住整个腿,下面一条深色底边很重 | 靠背压矮、上沿圆;扶手变薄变短,画完人再盖上去(`armchair()` 返回 `'arm'`);底座和椅子同色,只用白缝分开 |+| 睡着的人胸口竖着一本打开的书,像个盒子 | `book(open_='tent')`:扣着的书是一个低矮的实心「人」字(封底),脚下一条浅色的书页,书脊一道白线;第一次没生效是因为 'tent' 也是真值,先走进了打开的书那一支 |+| 红袜子的脚像一双红靴子 | 只穿袜子时画一只更细、脚尖更圆、没有鞋底和轮廓的脚,0.44 个头高 |+| 两个 z 叠成一个大 Z | z 改小、拉开间距,每个是一笔 |+| 猫粮和碗里的底色是同一个颜色,看不见 | 底色 `wood_light`,猫粮 `wood` |+| 雨只下在左边,还落在托特包上 | 两边都下,伞底下的一整条不下,包、大葱和腿周围留一块不下 |+| 长椅的 `y` 是座面,和椅子、凳子、桌子(`y` 是地面)不一样 | 统一成 `y` 是地面、`h` 是座高 |+| 'cap' 发型和短发分不出来 | 短发上面加一顶自己颜色(`hat`)的帽子:帽顶、帽檐、一道接缝和顶上的小纽 |+| 空白纸转成 JPG 后是一张平的数码白(标准差 0) | 纸纹 0.6 % → 1.2 %:空白纸角上 0.49 级(参考图 0.44–0.48 级) |+| 第一版 16:9 排成 3 + 2 的格子、头高 64 px,小画太小,中间一大块空 | 高的撑伞那幅单独占左边一列,其余四幅排成右边的 2 × 2,头高 84 px |+## 四、做成动画- 各画风都有 `stage(name)` 和 `save(path, stages_dir)`,按阶段依次淡入叠化,就是「一幅画被逐步画出来」。README 里的动图就是这样做的。@@ -2806,6 +2848,12 @@ from core import spline, curve, blob_pts, fbm1d, blur, polygon_mask- 调色板:第一帧是空白纸,只给 12 色;228 色只从和它不同的像素里切(末帧 ×3、饱和色 ×3——条纹、腮红、红嘴和红鞋、风筝,暗色 ×2——墨线和头发,它们细,颜色一少就淡进纸里);再留 15 色,其中 2 个是强制的(纸色和墨色,都在画上量出来),另外 13 色只从末帧误差超过 12 级的像素里切;最后 1 色是纯品红,当「和上一帧相同」的透明占位色。- 固定 4×4 Bayer(约 ±2.4 级),末帧不加抖动、精确发送;和屏上已显示颜色差不到 5 级(叠化帧)或 3 级(关键帧)的像素沿用上一帧。- 结果:读书的午后 40 帧、14.75 秒、0.33 MB,末帧误差中位数 0、p99 14;放风筝 34 帧、13.40 秒、0.31 MB,中位数 0、p99 8;都按解码结果逐帧自检(和应显示的画面最大差 0)。+- 日系扁平小插画的动图(脚本在 `workspace_projects/arte6/work/make_gif_spotillo.py`):+ - 竖幅(1500×2000)不硬塞进 16:9:范例有 `--layout wide`,把同样五幅排成 1920×1080(高的撑伞那幅单独占左边一列,其余四幅排成右边的 2 × 2),动图用这一版的阶段,缩成 720×405(LANCZOS)。+ - 阶段:空纸 → 撑伞出门 → 煮汤 → 看书 → 喂猫 → 午睡 → 成品(雨、热气、惊讶线和 z 一起出来)。每段 900 毫秒加 5 帧叠化,末帧停 2600 毫秒;叠化一片片铺上去,和色粉小像的做法一样。+ - 调色板:第一帧是空白纸,只给 8 色;228 色只从和它不同的像素里切(末帧 ×3、饱和色 ×3——红色的点睛、芥末黄、绿、橄榄绿、粉蓝,暗色 ×2——藏青、头发、猫);再强制放 11 个颜料色(红、近黑、芥末黄、绿、橄榄绿、粉蓝、蓝、米色、浅灰、纸色、墨色),剩下 8 色只从末帧误差超过 12 级的像素里切;最后 1 色是纯品红,当「和上一帧相同」的透明占位色。+ - 固定 4×4 Bayer(约 ±2.4 级),末帧不加抖动、精确发送;和屏上已显示颜色差不到 5 级(叠化帧)或 3 级(关键帧)的像素沿用上一帧。+ - 结果:30 帧,10.70 秒,约 0.20 MB,按解码结果逐帧自检(和应显示的画面最大差 0),末帧误差中位数 0、p99 12。平涂色块加大片白纸,所以小。- 绘本角色动画的动图是真动画,不是阶段叠化:`Storybook.gif()` 按时间逐帧渲染,720×405、15 fps(GIF 延时只能写厘秒,按累计取整写成 7、7、6 厘秒交替),共用一张加权调色板 + 固定 4×4 Bayer,没变的像素记成品红透明,151 帧(动作 9.95 秒 + 末帧停 1.4 秒)约 0.56 MB;范例加 `--gif out.gif` 出这张,`--stages` 的关键帧仍可喂给上面的阶段动图工具。- 形变动画可以直接出真动画:`Morph.at(keys, T)` 给出全局时间 T 的轮廓,逐帧渲染即可。- 更细的逐笔动画:把一组笔画单独画到透明层上导出,再用 Motion Canvas 遮罩按顺序显现。这个还没做成现成接口。@@ -2893,6 +2941,7 @@ lib/pastelvignette.py 色粉小像(直方图均衡的白纸纸纹与存成 uilib/poetichalloween.py 诗意万圣夜(直方图均衡的暗色画板纸纹与存成 uint8、沿 8 个方向拖开的纸纹,单像素细点子纹,颜料缓冲;和色粉小像同一套按段编号的 id 图光栅化,按 y 分带;取画布颜色「再画一遍」的笔触,以白为参照的乘法混色;按行分带的平滑色层和按软穹顶光取色阶的塑形,只在形状附近做的模糊;整块头发的窄带光泽和顺发流拉开的淡笔触、成绺的低对比发丝;重眼皮杏仁眼(眼皮盖住半个虹膜、外眼角下垂、湿红的下眼睑、虹膜里映出的暖光),平滑加单像素斑点的红晕和软斑、软环场,自成体积的长鼻子和红鼻尖,不笑的小嘴;粗麻平纹(各自粗细、有疙瘩、游走、一上一下交织的线,高度场打光,黑孔、纤维、毛边,可顺弧线织)、粗针织 V 形针脚与罗纹、镜像 sett 的 2/2 斜纹格子呢、从轮廓长出的纤维、顺管子弯的坐标;宽裂片重锯齿的掌状叶(压扁、对折、叶脉、投影)和从后往前的叶丛;陡衰减的暖色点光源、按接受度照亮已画好的东西、发光缓冲;银色细丝的半透明床单小幽灵(发光的眼睛、每绺末端的光珠);星星;柔化、三档光晕、印刷颗粒和暗部更显的粗纸纹、提亮的黑,按行分带算)lib/oilpastel.py 油画棒肖像(直方图均衡的白纸纸纹、沿 8 个方向拖得更长的纸纹(uint8);和色粉小像同一套按段编号的 id 图光栅化,按 y 分带;宽度不变的棒:钝而饱满的起笔、略摆的两侧,分道的磨损面(每道自己的压力、明暗、第二色和终点:一道道断掉的硬梳齿笔尾),陡阈值的纸纹露白,已有蜡的地方吃蜡更多;近乎不透明的蜡混色和带底色的拖色;按噪声加纸纹断开的裁边、每段边冲出距离各不相同的 spill;平行干笔铺色、给定路径的干笔;抖动、分段搭接、粗细不一、偶尔断开和补笔的黑色蜡笔线;排线腮红、短色条、干刷投影、热气;压低眼皮的黑眼睛、粗眉、平涂嘴唇、收尖的长发丝;渲染时透出的纸纹、按颜色深浅减弱的蜡厚度、颗粒和极轻的柔化)lib/sketchbook.py 手账线描(暖米白纸:直方图均衡的细纸纹、极淡的斑驳和纤维、一张可平铺的道子纹理;墨线:样条加慢手抖和快颤、起笔细收笔挑尖、粗细和墨色慢慢变、偶尔抬笔断开,按粗细和深浅不变切段、在 4 倍超采样图层里画,纸坑里断一点,正片叠底;一到三笔、接口留缺口或搭过头的轮廓;沿笔方向的 (u, s) 坐标里的彩铅 / 马克笔:长道子、顺笔细颗粒、挂纸纹或平铺、可选排线,颜色正片叠底;按角度、弯度或中心线排的彩虹条纹,每条自己的颜色、宽度、倾斜、颗粒、压力、两条游移的边和自己的出界阈值;圆粉腮红、圆点、闭眼弧线和睫毛、小红嘴;在导线之间插出、和相邻的线同相起伏、发梢收尖的一绺发丝;带人字叶脉或留白叶脉的单片叶子、螺旋 / 雏菊 / 郁金香小花、细线树、带卷的热气、短毛刺、小涂鸦;渲染时的纸面颗粒和极轻的柔化)+lib/spotillo.py 日系扁平小插画(按弧长重采样、沿法向推周期起伏的手剪边,3 倍超采样的包围盒小块光栅化、细噪声取阈值的毛边,不透明平涂,clip / avoid;按中尺度噪声断续的白缝;两头收尖的细线、按底色自动选白或深一号的衣褶线;按头高给关节的姿势预设(站、走、坐、蹲、伸手)、整个人转角度、hooks 插道具的人:粗管袖子和裤腿、在自己坐标系里搭的宽松上衣、白纸脸加侧脸线和点眼、鼓包头发刻白发丝、指头鼓包和红指缝的手、球鞋 / 袜子脚、帽子;马克杯、碗、锅、托特包、伞、自行车、长椅、椅子、扶手椅、沙发、小凳、桌子、橱柜、盆栽、书、猫、窗;热气、惊讶线、z、雨、运动短线、影子;渲染时的斑驳、细颗粒、发白小点、纸纹和极轻的柔化)examples/*.py 范例脚本;*.jpg 成品;drawing_*.gif 逐步画出的动图中文字体:自动找 Kaiti/Songti(macOS)、Noto CJK(Linux)、KaiTi/SimSun(Windows),或设 INKPAINT_FONT西文字体(后来新增的画风用):core.latin_font(style) 按 sans / sans_bold / rounded / script / hand / typewriter 等找系统字体,可用 INKPAINT_FONT_<STYLE> 指定;字体文件不要放进仓库diff --git a/examples/drawing_spotillo_rainy_saturday.gif b/examples/drawing_spotillo_rainy_saturday.gifnew file mode 100644index 0000000..7a97fc3Binary files /dev/null and b/examples/drawing_spotillo_rainy_saturday.gif differdiff --git a/examples/spotillo_rainy_saturday.jpg b/examples/spotillo_rainy_saturday.jpgnew file mode 100644index 0000000..a89efd8Binary files /dev/null and b/examples/spotillo_rainy_saturday.jpg differdiff --git a/examples/spotillo_rainy_saturday.py b/examples/spotillo_rainy_saturday.pynew file mode 100644index 0000000..d742d37--- /dev/null+++ b/examples/spotillo_rainy_saturday.py@@ -0,0 +1,196 @@+"""Example (flat spot illustration): 雨天的星期六 · A Rainy Saturday -- five small everyday vignettes on white.++Two people's rainy Saturday, told as Japanese-style spot illustrations floating on a white sheet: going out under a+red umbrella with a leek in the tote bag and stepping into a puddle; stirring soup in a red pot, steam curling up;+crouching to set down a red bowl for a black cat that has just noticed; reading in an armchair with a red mug+steaming on the stool; and an afternoon nap on the sofa, red socks up on the armrest, the book tented on the chest,+the cat curled up below. Flat opaque shapes with hand-cut edges and a faint print grain, a restrained palette (navy,+powder blue, mustard, green, olive, greys, near-black hair) with one red thing in every vignette, white folds cut+into the clothes, faces left as paper with a profile line and a dot eye, little hand marks for steam, rain, z's and+surprise. No ground, no background.++Drawn vignette by vignette, the little hand marks (rain, steam, '!', z's) last; --stages writes a snapshot after+each vignette and after the marks. --layout wide lays the same five vignettes out on a 1920 x 1080 sheet (used for+the draw-on GIF). No image model.+python3 spotillo_rainy_saturday.py [out.jpg] [--stages DIR] [--layout sheet|wide]+"""+import os, sys, time+sys.path.insert(0, os.path.join(os.path.dirname(os.path.abspath(__file__)), '..', 'lib'))+import numpy as np+from spotillo import SpotIllustration++P1 = dict(hair_style='bob', strands=2) # the one with the bob+P2 = dict(hair_style='short', strands=2) # the one with short hair+MARKS = [] # the little hand marks, drawn last+++def at(x, y, u, f=1):+ return lambda a, b: np.array([x + a * u * f, y + b * u])+++# ---------------------------------------------------------------- 1. out under the red umbrella+def going_out(s, x, y, u):+ P = at(x, y, u)+ s.shape(s.ellipse(*P(0.95, 0.03), 0.95 * u, 0.13 * u), 'powder_light', wobble=1.6) # the puddle+ hand = P(0.66, -3.66)+ tilt = 6.0+ d = np.array([-np.sin(np.deg2rad(tilt)), np.cos(np.deg2rad(tilt))])+ top = hand + np.array([0.27 * u, 0]) - d * 2.95 * u+ R = 1.5 * u+ canopy = {}++ def tote():+ sh = P(-0.22, -4.3)+ bag_c = P(-0.72, -2.1)+ # what sticks out of the bag first: a baguette and a leek (white stalk, green leaves)+ bt = bag_c + np.array([0.3 * u, -0.6 * u])+ Bq = s.shape(s.tube([bt, bt + np.array([0.28 * u, -1.25 * u])], 0.26 * u, ('flat', 'round'), smooth=False),+ 'wood_light', wobble=0.6)+ for t in (0.35, 0.6, 0.85):+ c = bt + np.array([0.28 * u, -1.25 * u]) * t+ s.line([c + np.array([-0.08 * u, 0.02 * u]), c + np.array([0.09 * u, -0.04 * u])], 2.2 * s.k, 'wood', clip=Bq)+ lk = bag_c + np.array([-0.08 * u, -0.7 * u])+ top_w = lk + np.array([-0.16 * u, -0.85 * u])+ for a, L, col in ((-0.55, 0.85, 'green'), (-0.2, 1.0, 'olive'), (0.15, 0.75, 'green')):+ tip = top_w + np.array([np.sin(a), -np.cos(a)]) * L * u+ s.shape(s.tube([top_w, (top_w + tip) / 2 + np.array([-0.05 * u, 0]), tip], [0.17 * u, 0.15 * u, 0.03 * u],+ ('round', 'round')), col, wobble=0.6)+ s.shape(s.tube([lk, top_w], [0.22 * u, 0.18 * u], ('flat', 'round'), smooth=False), 'paper', wobble=0.4)+ s.line([lk + np.array([-0.08 * u, -0.1 * u]), top_w + np.array([-0.05 * u, 0.2 * u])], 1.8 * s.k, 'sage', taper=0.3)+ Bg = s.bag(bag_c[0], bag_c[1] + 0.55 * u, 1.0 * u, 1.15 * u, 'cream', handles=False)+ s.fold([bag_c + np.array([-0.3 * u, 0.35 * u]), bag_c + np.array([-0.18 * u, 0.12 * u])], 2.2 * s.k, clip=Bg)++ def umbrella():+ # the tote's strap over the shoulder, behind the arm and down to the bag+ s.line([P(-0.02, -4.46), P(-0.32, -4.2), P(-0.5, -3.6), P(-0.55, -3.05)], 0.1 * u, 'cream', taper=0.0, wobble=0.4)+ canopy['P'] = s.umbrella(top[0], top[1], R, tilt, 'red', handle_len=(2.95 * u + 0.5 * u) / R)++ s.person(x, y, u, 1, 'walk', dict(P1, top='navy', bottom='grey', shoes='paper', hand_f=None, hand_n=('grip', -6)),+ hooks=dict(arm_near=tote, hand_near=umbrella),+ rel=dict(hem_b=(-0.6, -1.95), hem_f=(0.66, -1.98), elbow_n=(0.06, -3.25), wrist_n=hand_rel(hand, x, y, u),+ elbow_f=(0.55, -3.5), wrist_f=(0.6, -2.7), head=(0.24, -5.18)))+ s.fold([P(0.18, -2.5), P(0.25, -2.15)], 2.4 * s.k)++ def marks():+ left = top[0] - R * 1.02; right = top[0] + R * 1.02; rim = top[1] + R * 0.45+ r = np.random.default_rng(7)+ for _ in range(60):+ px, py = r.uniform(x - 2.1 * u, x + 3.9 * u), r.uniform(y - 8.0 * u, y - 0.1 * u)+ if left - 0.1 * u < px < right + 0.25 * u and py > top[1] - R * 0.5: continue+ if x - 1.5 * u < px < x + 0.2 * u and py > y - 5.4 * u: continue # the bag, the leek, the legs+ if abs(px - top[0]) < R * 1.2 and abs(py - (top[1] - R * 0.1)) < R * 0.6: continue+ L = 0.32 * u * r.uniform(0.6, 1.25)+ s.line([(px, py), (px - 0.28 * L, py + L)], 2.6 * s.k, 'slate', taper=0.3, wobble=0.1, smooth=False)+ for a in (-150, -120, -60, -30):+ q = P(0.95, -0.05) + np.array([np.cos(np.deg2rad(a)) * 0.75 * u, np.sin(np.deg2rad(a)) * 0.32 * u])+ q2 = q + np.array([np.cos(np.deg2rad(a)), np.sin(np.deg2rad(a))]) * 0.22 * u+ s.line([q, q2], 2.6 * s.k, 'slate', taper=0.2, wobble=0.1, smooth=False)+ MARKS.append(marks)+++def hand_rel(hand, x, y, u, f=1):+ return ((hand[0] - x) / (u * f), (hand[1] - y) / u)+++# ---------------------------------------------------------------- 2. soup on the stove+def soup(s, x, y, u):+ P = at(x, y, u)+ s.stove(*P(0.62, 0)[:1], P(3.1, 0)[0], y, 2.85 * u, 'grey_light')+ s.shape(s.rrect(*P(2.45, -3.35), *P(2.85, -2.85), 0.05 * u), 'paper', wobble=0.5) # a jar+ J = s.shape(s.rrect(*P(2.45, -3.35), *P(2.85, -2.85), 0.05 * u), 'powder', wobble=0.5)+ s.shape(s.rrect(*P(2.42, -3.5), *P(2.88, -3.32), 0.04 * u), 'navy', wobble=0.4)+ s.line([P(1.18, -3.95), P(1.5, -3.25)], 0.07 * u, 'wood', taper=0.0, wobble=0.3) # the ladle+ s.pot(*P(1.62, -2.85), 1.2 * u, 'red')+ s.person(x, y, u, 1, 'stand', dict(P2, top='green', bottom='navy', apron='cream', hand_n=('grip', -55),+ hand_f=('flat', 8)),+ rel=dict(elbow_n=(0.18, -3.35), wrist_n=(0.98, -3.78), elbow_f=(0.62, -3.55), wrist_f=(0.98, -3.02),+ head=(0.2, -5.2)))+ MARKS.append(lambda: s.steam(*P(1.62, -3.7), 0.95 * u, n=3, colour='red_line'))+++# ---------------------------------------------------------------- 3. dinner for the cat+def cat_dinner(s, x, y, u):+ P = at(x, y, u)+ cat = s.cat_sit(*P(2.75, 0.02), 1.15 * u, facing=-1, head_down=0.25)+ bowl = {}++ def put_bowl():+ bowl['P'] = s.bowl(*P(1.72, 0.02), 0.95 * u, colour='red', fill='wood_light')+ r = np.random.default_rng(3)+ for _ in range(9):+ bx, by = P(1.72 + r.uniform(-0.3, 0.3), -0.42 + r.uniform(-0.04, 0.04))+ s.dot(bx, by, 0.045 * u, 'wood')+ s.person(x, y, u, 1, 'crouch', dict(P1, top='powder', bottom='navy', hood=True, hand_n=('grip', 35),+ hand_f=('flat', 30)),+ hooks=dict(hand_near=put_bowl),+ rel=dict(wrist_n=(1.2, -0.62), elbow_n=(0.78, -1.5), elbow_f=(0.95, -2.0), wrist_f=(1.0, -1.5)))+ MARKS.append(lambda: s.bang(*P(2.86, -1.45), 0.2 * u, -90, 'red_line'))+++# ---------------------------------------------------------------- 4. a book and a mug+def reading(s, x, y, u):+ P = at(x, y, u)+ ch = s.armchair(*P(0.1, 0), 2.2 * u, 3.9 * u, 1, 'olive')+ s.stool(*P(2.55, 0), 0.9 * u, 1.75 * u, 'wood')+ s.mug(*P(2.55, -1.82), 0.5 * u, 'red', facing=-1)+ book = {}++ def open_book():+ ch['arm']()+ book['P'] = s.book(*P(0.95, -3.35), 0.95 * u, angle=-58, colour='blue')+ s.person(x, y, u, 1, 'sit', dict(P2, top='mustard', bottom='grey', shoes='grey_light', laces=False, eye='down',+ hand_n=('grip', -70), hand_f=('grip', -80), tilt=8),+ hooks=dict(arm_near=open_book),+ rel=dict(hip_n=(0.0, -1.75), hip_f=(0.15, -1.75), knee_n=(1.15, -1.95), knee_f=(1.2, -1.9),+ ankle_n=(1.1, -0.24), ankle_f=(1.3, -0.24), hem_b=(-0.5, -1.9), hem_f=(0.55, -1.9),+ sh_b=(-0.38, -3.62), sh_f=(0.44, -3.65), neck=(0.12, -3.86), head=(0.3, -4.32),+ elbow_n=(0.1, -2.6), wrist_n=(0.82, -3.05), elbow_f=(0.62, -2.75), wrist_f=(1.1, -3.2)))+ MARKS.append(lambda: s.steam(*P(2.55, -2.45), 0.75 * u, n=2, colour='red_line'))+++# ---------------------------------------------------------------- 5. the nap+def nap(s, x, y, u):+ P = at(x, y, u)+ sofa = s.sofa(*P(-3.7, 0)[:1], P(3.4, 0)[0], y, 2.3 * u, 'grey_light')+ s.shape(s.blob(*P(-2.95, -1.55), 0.55 * u, 0.42 * u, rough=0.06, rot=-20), 'powder', wobble=1.0) # cushion+ s.person(*P(2.65, -1.62), u, 1, 'stand', dict(P1, top='blue', bottom='grey', socks='red', shoes=None, eye='closed',+ hand_n=('flat', 0), hand_f=None),+ rot=-90,+ rel=dict(knee_n=(0.5, -1.5), ankle_n=(0.15, -0.3), knee_f=(0.35, -1.45), ankle_f=(0.0, -0.25),+ elbow_n=(-0.05, -3.3), wrist_n=(0.55, -3.0), head=(0.1, -5.2)),+ hooks=dict(arm_near=lambda: s.book(*P(-1.2, -2.02), 1.05 * u, angle=0, colour='mustard', open_='tent')))+ s.cat_curl(*P(1.6, 0.05), 1.15 * u)+ MARKS.append(lambda: s.zzz(*P(-2.6, -3.4), 0.32 * u, colour='navy'))+++LAYOUTS = {+ # name: canvas, [(vignette, x, y, u)]+ 'sheet': ((1500, 2000), [(going_out, 330, 860, 100), (soup, 860, 800, 100), (nap, 790, 1330, 100),+ (cat_dinner, 210, 1880, 100), (reading, 940, 1895, 100)]),+ 'wide': ((1920, 1080), [(going_out, 340, 860, 84), (soup, 810, 530, 84), (reading, 1440, 530, 84),+ (cat_dinner, 770, 1010, 84), (nap, 1500, 1010, 84)]),+}+NAMES = {going_out: 'going_out', soup: 'soup', cat_dinner: 'cat_dinner', reading: 'reading', nap: 'nap'}+++def main():+ out = sys.argv[1] if len(sys.argv) > 1 and not sys.argv[1].startswith('--') else 'spotillo_rainy_saturday.jpg'+ stages = sys.argv[sys.argv.index('--stages') + 1] if '--stages' in sys.argv else None+ layout = sys.argv[sys.argv.index('--layout') + 1] if '--layout' in sys.argv else 'sheet'+ T0 = time.time()+ (W, H), items = LAYOUTS[layout]+ s = SpotIllustration(W, H, seed=5, keep_stages=bool(stages), stages_dir=stages)+ s.finish()+ s.paper()+ s.stage('paper')+ MARKS.clear()+ for fn, x, y, u in items:+ fn(s, x, y, u)+ s.stage(NAMES[fn])+ for m in MARKS: m()+ s.save(out, stages_dir=stages)+ print('saved', out, f'{time.time() - T0:.1f}s')+++if __name__ == '__main__':+ main()diff --git a/examples/spotillo_rainy_saturday_wide.jpg b/examples/spotillo_rainy_saturday_wide.jpgnew file mode 100644index 0000000..9c53795Binary files /dev/null and b/examples/spotillo_rainy_saturday_wide.jpg differdiff --git a/lib/spotillo.py b/lib/spotillo.pynew file mode 100644index 0000000..1ebdecb--- /dev/null+++ b/lib/spotillo.py@@ -0,0 +1,1210 @@+"""spotillo — 日系扁平小插画 / Flat Spot Illustration: small Japanese-style everyday-life vignettes floating on white+(numpy + Pillow only).++The look: several small scenes of ordinary life (someone sipping from a mug, two people baking, a walk with a+bicycle, a nap) set apart on a white sheet with generous space between them -- no ground, no background, at most a+sliver of shadow or a bench leg. Every shape is a flat, opaque cut of one colour: no gradients, no shading, only a+faint print grain. Edges are slightly irregular, as if cut by hand or laid with a marker, never vector-perfect. The+palette is restrained -- navy, slate and powder blue, mustard, olive and forest green, a few greys, near-black+hair -- with skin left as the white paper (or a pale warm tone), and ONE warm red that recurs as the accent in+every vignette (a mug, a bowl, a bag, an umbrella, a pair of socks). Lines are few and thin: folds and seams cut+in white into dark fabric (or drawn a shade darker on pale fabric), a profile line down the face, fingers, chair+legs. Faces are almost blank: a tiny dot eye, a nose bump in the profile line. Hair is one solid dark blob with a+couple of white strands cut into it. Action is told with little hand marks: steam squiggles, three dashes of+surprise, z's, rain.++Model+ paper A warm white sheet (#fbfaf6); `finish()` adds a very faint tooth to the bare paper.+ shapes A shape is a closed outline (a point list). Before it is cut, the outline is resampled and pushed in+ and out along its normals by a periodic low-frequency wobble plus a finer one (`wobble` px x k,+ `lumps` its wavelength), so a circle is a little lumpy and a straight edge breathes. Pillow fills it+ into a 3x supersampled patch the size of its bounding box; the edge is then thresholded against a+ fine noise so it frays by a fraction of a pixel. Paint is opaque: new = old + mask x (colour - old). A+ patch can be clipped to (or kept out of) other patches (`clip=`, `avoid=`).+ gaps `gap=` cuts a thin white gap round a shape before it is laid -- the paper showing between two shapes+ of one colour (an arm over a sweater, trousers over a hoodie, a seat cushion on a sofa). The gap is+ the shape's blurred mask thresholded against a mid-scale noise, so it is wider here, narrower there+ and missing on (1 - `gap_keep`) of the edge.+ lines A line is a tapered ribbon along a slightly wobbling path (round ends, thin tips), rasterised at 4x.+ `fold()` picks its colour from what is under it: a white cut on dark and mid fabric (luminance < 0.74),+ a darker shade of a pale one. `cut()` is a white line.+ people Built from simple parts in a fixed back-to-front order (far leg, far arm and hand, near leg, neck and+ torso, head and hair, near arm and hand; the crouch puts the near leg in front of the torso):+ `limb()` a sleeve or trouser leg as a fat tube with a flat cuff; `torso()` a boxy oversized top built+ in its own frame; `head()` a paper-white face with a profile line (nose bump, lips, chin), a dot eye and+ a lumpy hair blob with white strands cut in; `hand()` a white mitten with finger bumps, a thin outline+ and red finger lines; `shoe()` a sneaker or a stocking foot. `person()` draws a whole figure from a+ pose preset ('stand', 'walk', 'sit', 'crouch', 'reach') with joints overridden in head units (`rel`),+ turned (`rot`, -90 lays it on its back), automatic folds at elbows, knees, shins and hem, and hooks to+ slip props in between the layers.+ props mug, bowl, pot, bag, umbrella, bicycle, bench, chair, armchair (its near arm drawn later, over the+ sitter), sofa, stool, table, stove / counter, plant, book (open, closed, tented face-down), cat_sit,+ cat_curl, window -- all from the same flat shapes and lines.+ marks steam squiggles, three dashes of surprise ('!'), z's, rain dashes, motion ticks, a sliver of shadow.+ finish `finish()` records the print grain (a soft mottle and a fine tooth in the ink, a few paper-light specks,+ a very slight softening), applied in render so every stage snapshot matches the final picture.++API (canvas pixel coordinates; colours are PAINTS names, '#rrggbb' or RGB triples; k = min(W, H) / 1000 scales the+ default widths; u = a figure's head height in px)+ surface SpotIllustration(W, H, seed, keep_stages, stages_dir); paper(tone); finish(grain, speckle, soft) -- call+ finish() before the first mark+ outlines ellipse(cx, cy, rx, ry, rot) / rrect(x0, y0, x1, y1, r) / blob(cx, cy, rx, ry, rough, rot) /+ curve(pts) (closed Catmull-Rom) / tube(path, widths, cap) -> point arrays+ paint shape(pts, colour, smooth, wobble, rough, gap, gap_keep, clip, avoid, alpha, lumps) -> Patch;+ knock(pts) (a paper-white shape); line(path, width, colour, taper, wobble, clip, avoid, smooth, closed,+ tip); cut(path, width); fold(path, width, colour, clip); dot(x, y, r, colour); union(*patches);+ grow(patch, px); under(path) (the mean colour under a path)+ people limb(path, widths, colour, cap, gap, gap_keep); torso(sh_back, sh_front, hem_back, hem_front, colour,+ facing, collar, bulge, gap, hood); head(cx, cy, r, facing, turn, tilt, hair, hair_colour, eye, ear,+ strands, skin, line, mouth, fringe, hat) -> dict of points; hair(head, style, colour, strands, fringe,+ hat); neck(top, bottom, w); hand(x, y, angle, size, pose, facing, finger) (pose 'grip' / 'fist' /+ 'open' / 'flat' / 'cup'); shoe(x, y, angle, size, colour, facing, sole, line, laces);+ pose(name, x, y, u, facing, rot, rel, **joints) -> joints; person(x, y, u, facing, pose, outfit, hooks,+ rel, rot, J, order, folds, **joints)+ props mug(x, y, h) / bowl(x, y, w, fill) / pot(x, y, w) / bag(x, y, w, h) / umbrella(x, y, r, angle,+ handle_len) / bicycle(x, y, size, facing) / bench(x0, x1, y, h) / chair(x, y, h, facing) /+ armchair(x, y, w, h, facing) -> {'arm': fn} / sofa(x0, x1, y, h) / stool(x, y, w, h) /+ table(x0, x1, y, h) / stove(x0, x1, y, h) / plant(x, y, h, pot, leaf) / book(x, y, w, angle, open_) /+ cat_sit(x, y, h, facing, head_down, eye) / cat_curl(x, y, w) / window(x0, y0, x1, y1)+ marks steam(x, y, h, n) / bang(x, y, r, angle) / zzz(x, y, size) / rain(x0, y0, x1, y1, n, slant) /+ ticks(x, y, r, angle, n) / shadow(cx, cy, rx, ry)+ output render(); composite(); stage(name); save(path, stages_dir) -- save('x.jpg') quality 92, 4:4:4 chroma++ import sys; sys.path.insert(0, 'lib')+ from spotillo import SpotIllustration+ s = SpotIllustration(1200, 900, seed=1); s.finish(); s.paper()+ u = 110 # one head height+ s.person(560, 820, u, facing=1, pose='stand', outfit=dict(top='mustard', bottom='grey', hand_n=('grip', -5)),+ rel=dict(elbow_n=(0.0, -3.4), wrist_n=(0.55, -3.7)),+ hooks={'hand_near': lambda: s.mug(560 + 0.95 * u, 820 - 3.45 * u, 0.5 * u)})+ s.steam(560 + 0.95 * u, 820 - 4.1 * u, 0.8 * u)+ s.save('spot.jpg')+"""+import io+import os+import numpy as np+from PIL import Image, ImageDraw+from core import blur, noise2d, spline, smoothstep, fbm1d++PAINTS = {+ # paper and lines+ 'paper': '#fbfaf6', 'white': '#ffffff', 'ink': '#262d3d', 'line': '#3a4152', 'black': '#252b3b',+ # blues+ 'navy_deep': '#222b40', 'navy': '#2c3956', 'blue': '#35548a', 'slate': '#5d7290', 'powder': '#92b5d0',+ 'powder_light': '#bcd3e5',+ # yellows and greens+ 'mustard': '#d6a235', 'mustard_light': '#e8c46a', 'olive': '#66804a', 'green': '#4d7b55', 'sage': '#a3b48c',+ # greys and creams+ 'grey_light': '#e0e0de', 'grey': '#c7c8c8', 'grey_mid': '#a7aaae', 'grey_dark': '#6f747c', 'cream': '#efe8da',+ 'skin': '#f7eadf', 'wood': '#c49a68', 'wood_light': '#dcc09a',+ # the one warm accent+ 'red': '#e2432a', 'red_deep': '#c3331f', 'red_line': '#e0563f', 'pink': '#f0b1a2',+}+++def hexc(c):+ if isinstance(c, str):+ c = PAINTS.get(c, c).lstrip('#')+ return np.array([int(c[i:i + 2], 16) for i in (0, 2, 4)], np.float32) / 255+ c = np.asarray(c, np.float32)+ return c / 255 if c.max() > 1.0 else c+++def mix(a, b, t):+ return hexc(a) * (1 - t) + hexc(b) * t+++def _lum(c):+ return float(0.3 * c[0] + 0.59 * c[1] + 0.11 * c[2])+++def _resample(P, step, closed):+ P = np.asarray(P, np.float64)+ if closed: P = np.vstack([P, P[:1]])+ d = np.hypot(*np.diff(P, axis=0).T)+ s = np.concatenate([[0], np.cumsum(d)])+ L = s[-1]+ if L < 1e-6: return P[:1].copy(), 0.0+ n = max(4 if closed else 2, int(np.ceil(L / step)) + (0 if closed else 1))+ t = np.linspace(0, L, n, endpoint=not closed)+ return np.stack([np.interp(t, s, P[:, 0]), np.interp(t, s, P[:, 1])], 1), L+++def _normals(P, closed):+ if closed: T = np.roll(P, -1, 0) - np.roll(P, 1, 0)+ else: T = np.gradient(P, axis=0)+ n = np.hypot(T[:, 0], T[:, 1])[:, None] + 1e-9+ T = T / n+ return np.stack([-T[:, 1], T[:, 0]], 1), T+++def _pnoise(n, cycles, rng):+ """periodic 1D noise over n samples with about `cycles` waves, roughly in [-1, 1]"""+ s = np.arange(n) / n+ k0 = max(1, int(cycles * 0.6)); k1 = max(k0 + 1, int(cycles * 1.6) + 1)+ out = np.zeros(n)+ for k in range(k0, k1 + 1):+ out += rng.normal() / (k / max(cycles, 1)) ** 0.7 * np.sin(2 * np.pi * (k * s + rng.random()))+ return out / (np.abs(out).max() + 1e-9)+++def closed_spline(pts, per=10):+ """closed Catmull-Rom through the control points"""+ P = np.asarray(pts, np.float64)+ n = len(P)+ out = []+ for i in range(n):+ p0, p1, p2, p3 = P[(i - 1) % n], P[i], P[(i + 1) % n], P[(i + 2) % n]+ for t in np.linspace(0, 1, per, endpoint=False):+ t2, t3 = t * t, t * t * t+ out.append(0.5 * ((2 * p1) + (-p0 + p2) * t + (2 * p0 - 5 * p1 + 4 * p2 - p3) * t2 ++ (-p0 + 3 * p1 - 3 * p2 + p3) * t3))+ return np.array(out)+++def open_spline(pts, per=10):+ P = np.asarray(pts, np.float64)+ if len(P) < 3:+ t = np.linspace(0, 1, per * 2)[:, None]+ return P[0] + (P[-1] - P[0]) * t+ return spline(P, per).astype(np.float64)+++class Patch:+ """a mask on a box of the canvas: x0, y0 and an (h, w) float array"""+ __slots__ = ('x0', 'y0', 'm')++ def __init__(self, x0, y0, m):+ self.x0, self.y0, self.m = int(x0), int(y0), m++ @property+ def box(self):+ return self.x0, self.y0, self.x0 + self.m.shape[1], self.y0 + self.m.shape[0]++ def at(self, x0, y0, x1, y1):+ """this patch's values on the box (zeros outside it)"""+ out = np.zeros((y1 - y0, x1 - x0), np.float32)+ a0, b0, a1, b1 = self.box+ ix0, iy0, ix1, iy1 = max(x0, a0), max(y0, b0), min(x1, a1), min(y1, b1)+ if ix1 > ix0 and iy1 > iy0:+ out[iy0 - y0:iy1 - y0, ix0 - x0:ix1 - x0] = self.m[iy0 - b0:iy1 - b0, ix0 - a0:ix1 - a0]+ return out+++class SpotIllustration:+ def __init__(self, W=1500, H=2000, seed=0, keep_stages=True, stages_dir=None):+ self.W, self.H = int(W), int(H)+ self.k = min(W, H) / 1000.0+ self.seed = seed+ self.rng = np.random.default_rng(seed)+ self.keep_stages, self.stages_dir = keep_stages, stages_dir+ self.stages, self._n_stages = [], 0+ self.paper_rgb = hexc('paper')+ self.C = np.ones((self.H, self.W, 3), np.float32) * self.paper_rgb+ self.fine = noise2d(self.H, self.W, 1.3, 2, seed + 11) # print grain, fraying of edges+ self.mid = noise2d(self.H, self.W, 34 * self.k, 3, seed + 12) # gaps that come and go, mottle+ self.fin = {}++ # ------------------------------------------------------------------ surface+ def paper(self, tone='paper', grain=1.0):+ self.paper_rgb = hexc(tone)+ self.C[:] = self.paper_rgb+ self.paper_grain = grain+ return self++ def finish(self, grain=1.0, speckle=1.0, soft=0.25):+ """record the print finish (applied in render so every stage snapshot matches the final look)"""+ self.fin = dict(grain=grain, speckle=speckle, soft=soft)+ return self++ def _r(self, seed=None):+ return np.random.default_rng(self.rng.integers(1 << 30) if seed is None else seed)++ # ------------------------------------------------------------------ outlines+ def ellipse(self, cx, cy, rx, ry=None, rot=0.0, n=None):+ ry = rx if ry is None else ry+ n = n or max(24, int(2 * np.pi * max(rx, ry) / 3))+ t = np.linspace(0, 2 * np.pi, n, endpoint=False)+ x, y = np.cos(t) * rx, np.sin(t) * ry+ c, s = np.cos(np.deg2rad(rot)), np.sin(np.deg2rad(rot))+ return np.stack([cx + x * c - y * s, cy + x * s + y * c], 1)++ def rrect(self, x0, y0, x1, y1, r=None):+ r = min(abs(x1 - x0), abs(y1 - y0)) * 0.18 if r is None else r+ r = min(r, abs(x1 - x0) / 2, abs(y1 - y0) / 2)+ out = []+ for cx, cy, a0 in ((x1 - r, y0 + r, -90), (x1 - r, y1 - r, 0), (x0 + r, y1 - r, 90), (x0 + r, y0 + r, 180)):+ for a in np.linspace(a0, a0 + 90, 8):+ out.append((cx + r * np.cos(np.deg2rad(a)), cy + r * np.sin(np.deg2rad(a))))+ return np.array(out)++ def blob(self, cx, cy, rx, ry=None, rough=0.08, rot=0.0, seed=None):+ ry = rx if ry is None else ry+ n = max(30, int(2 * np.pi * max(rx, ry) / 4))+ r = self._r(seed)+ t = np.linspace(0, 2 * np.pi, n, endpoint=False)+ w = 1 + rough * _pnoise(n, 5, r)+ x, y = np.cos(t) * rx * w, np.sin(t) * ry * w+ c, s = np.cos(np.deg2rad(rot)), np.sin(np.deg2rad(rot))+ return np.stack([cx + x * c - y * s, cy + x * s + y * c], 1)++ def curve(self, pts, per=10):+ return closed_spline(pts, per)++ def tube(self, path, widths, cap='round', smooth=True):+ """closed outline of a ribbon along `path` (widths: a number or one per control point; cap 'round' /+ 'flat' / ('flat', 'round') for start / end)"""+ P = open_spline(path, 10) if smooth else np.asarray(path, np.float64)+ P, L = _resample(P, max(1.0, 1.5 * self.k), closed=False)+ w = np.atleast_1d(np.asarray(widths, np.float64))+ wt = np.interp(np.linspace(0, 1, len(P)), np.linspace(0, 1, len(w)), w) if len(w) > 1 else np.full(len(P), w[0])+ N, T = _normals(P, False)+ left, right = P + N * wt[:, None] / 2, P - N * wt[:, None] / 2+ caps = (cap, cap) if isinstance(cap, str) else cap+ th = np.linspace(0, np.pi, 9)[1:-1]+ end = P[-1] + (wt[-1] / 2) * (np.cos(th)[:, None] * N[-1] + np.sin(th)[:, None] * T[-1]) if caps[1] == 'round' else np.zeros((0, 2))+ start = P[0] + (wt[0] / 2) * (np.cos(th)[:, None] * -N[0] + np.sin(th)[:, None] * -T[0]) if caps[0] == 'round' else np.zeros((0, 2))+ return np.vstack([left, end, right[::-1], start])++ # ------------------------------------------------------------------ rasterising+ def _wobble(self, pts, amp, r, lam=80.0):+ P, L = _resample(pts, max(1.2, 2.2 * self.k), closed=True)+ if amp <= 0 or len(P) < 8: return P+ N, _ = _normals(P, True)+ lam = lam * self.k+ d = amp * self.k * (1.0 * _pnoise(len(P), L / lam, r) + 0.35 * _pnoise(len(P), L / (lam / 5), r))+ return P + N * d[:, None]++ def _raster(self, pts, pad=2, ss=3):+ pts = np.asarray(pts, np.float64)+ x0 = max(0, int(np.floor(pts[:, 0].min())) - pad); x1 = min(self.W, int(np.ceil(pts[:, 0].max())) + pad + 1)+ y0 = max(0, int(np.floor(pts[:, 1].min())) - pad); y1 = min(self.H, int(np.ceil(pts[:, 1].max())) + pad + 1)+ if x1 <= x0 or y1 <= y0: return None+ im = Image.new('L', ((x1 - x0) * ss, (y1 - y0) * ss), 0)+ q = (pts - [x0, y0]) * ss+ ImageDraw.Draw(im).polygon([tuple(p) for p in q], fill=255)+ m = np.asarray(im.resize((x1 - x0, y1 - y0), Image.BOX), np.float32) / 255+ return Patch(x0, y0, m)++ def _fray(self, P, rough):+ if rough <= 0: return P+ x0, y0, x1, y1 = P.box+ n = self.fine[y0:y1, x0:x1]+ P.m = np.clip((P.m - 0.5) * 1.3 + 0.5 + rough * 0.3 * (n - 0.5), 0, 1)+ return P++ def _restrict(self, P, clip=None, avoid=None):+ if clip is None and avoid is None: return P+ x0, y0, x1, y1 = P.box+ m = P.m+ if clip is not None:+ for c in (clip if isinstance(clip, (list, tuple)) else [clip]): m = m * c.at(x0, y0, x1, y1)+ if avoid is not None:+ for a in (avoid if isinstance(avoid, (list, tuple)) else [avoid]): m = m * (1 - a.at(x0, y0, x1, y1))+ return Patch(x0, y0, m)++ def _apply(self, P, colour, alpha=1.0):+ x0, y0, x1, y1 = P.box+ sl = self.C[y0:y1, x0:x1]+ a = (P.m * alpha)[..., None]+ sl += (hexc(colour) - sl) * a++ def union(self, *patches):+ ps = [p for p in patches if p is not None]+ x0 = min(p.x0 for p in ps); y0 = min(p.y0 for p in ps)+ x1 = max(p.box[2] for p in ps); y1 = max(p.box[3] for p in ps)+ m = np.zeros((y1 - y0, x1 - x0), np.float32)+ for p in ps: m = np.maximum(m, p.at(x0, y0, x1, y1))+ return Patch(x0, y0, m)++ def grow(self, P, px):+ """a patch grown (px > 0) or shrunk (px < 0) by about px"""+ pad = int(abs(px) * 2) + 2+ x0, y0, x1, y1 = P.box+ X0, Y0, X1, Y1 = max(0, x0 - pad), max(0, y0 - pad), min(self.W, x1 + pad), min(self.H, y1 + pad)+ m = blur(P.at(X0, Y0, X1, Y1), abs(px) * 0.6)+ thr = 0.18 if px > 0 else 0.82+ return Patch(X0, Y0, np.clip((m - thr) * 6 + 0.5, 0, 1))++ # ------------------------------------------------------------------ painting+ def shape(self, pts, colour, smooth=False, wobble=1.0, rough=1.0, gap=0.0, gap_keep=0.75, clip=None, avoid=None,+ alpha=1.0, lumps=80.0, seed=None):+ """a flat, opaque, hand-cut shape. `gap` cuts a white gap of about that many px round it first (on+ `gap_keep` of its edge, in stretches). Returns the patch."""+ r = self._r(seed)+ pts = closed_spline(pts, 8) if smooth else np.asarray(pts, np.float64)+ pts = self._wobble(pts, wobble, r, lumps)+ P = self._raster(pts, pad=int(gap * 3) + 3 if gap else 2)+ if P is None: return None+ self._fray(P, rough)+ if gap > 0:+ x0, y0, x1, y1 = P.box+ D = blur(P.m, gap * 0.55)+ n = self.mid[y0:y1, x0:x1]+ n = (n - 0.5) * 1.6 + 0.5+ thr = 0.06 + 0.5 * smoothstep(gap_keep - 0.06, gap_keep + 0.06, n)+ ring = np.clip((D - thr) * 9, 0, 1) * (1 - P.m)+ G = self._restrict(Patch(x0, y0, ring), clip=None, avoid=avoid)+ self._apply(G, self.paper_rgb)+ P = self._restrict(P, clip, avoid)+ self._apply(P, colour, alpha)+ return P++ def knock(self, pts, smooth=False, wobble=1.0, gap=0.0, **kw):+ """a paper-white shape (skin, a white mug, the gap of a handle)"""+ return self.shape(pts, self.paper_rgb, smooth=smooth, wobble=wobble, gap=gap, **kw)++ def line(self, path, width=None, colour='ink', taper=(0.2, 0.25), wobble=0.6, clip=None, avoid=None, smooth=True,+ closed=False, tip=0.35, alpha=1.0, seed=None):+ """a thin hand line: a ribbon tapering to `tip` x width over the first / last `taper` of its length"""+ r = self._r(seed)+ width = (2.6 * self.k) if width is None else width+ P = np.asarray(path, np.float64)+ if closed: P = np.vstack([P, P[:1]])+ P = open_spline(P, 10) if smooth and len(P) > 2 else P+ P, L = _resample(P, max(0.8, 1.2 * self.k), closed=False)+ if len(P) < 2: return None+ n = len(P)+ N, T = _normals(P, False)+ if wobble:+ P = P + N * (wobble * self.k * fbm1d(n, max(4, 40 * self.k / max(L / n, 1e-3)), 3, int(r.integers(1 << 30))))[:, None]+ N, T = _normals(P, False)+ t = np.linspace(0, 1, n)+ ta, tb = (taper, taper) if np.isscalar(taper) else taper+ prof = np.ones(n)+ if ta > 0: prof = np.minimum(prof, tip + (1 - tip) * np.clip(t / ta, 0, 1) ** 0.6)+ if tb > 0: prof = np.minimum(prof, tip + (1 - tip) * np.clip((1 - t) / tb, 0, 1) ** 0.6)+ wv = width * prof * (1 + 0.12 * fbm1d(n, max(3, n / 3), 2, int(r.integers(1 << 30))))+ left, right = P + N * wv[:, None] / 2, P - N * wv[:, None] / 2+ th = np.linspace(0, np.pi, 7)[1:-1]+ end = P[-1] + (wv[-1] / 2) * (np.cos(th)[:, None] * N[-1] + np.sin(th)[:, None] * T[-1])+ start = P[0] + (wv[0] / 2) * (np.cos(th)[:, None] * -N[0] + np.sin(th)[:, None] * -T[0])+ Pp = self._raster(np.vstack([left, end, right[::-1], start]), pad=2, ss=4)+ if Pp is None: return None+ Pp = self._restrict(Pp, clip, avoid)+ self._apply(Pp, colour, alpha)+ return Pp++ def cut(self, path, width=None, **kw):+ """a white line cut into a colour (a fold, a seam, a strand of hair)"""+ return self.line(path, width, self.paper_rgb, **kw)++ def under(self, path):+ """the mean colour on the canvas under a path"""+ P = np.asarray(path, np.float64)+ xs = np.clip(P[:, 0].astype(int), 0, self.W - 1); ys = np.clip(P[:, 1].astype(int), 0, self.H - 1)+ return self.C[ys, xs].mean(0)++ def fold(self, path, width=None, colour=None, clip=None, **kw):+ """a fold or seam: white on dark and mid fabric, a darker shade on pale fabric (pass colour= to force)"""+ if colour is None:+ c = self.under(path)+ colour = self.paper_rgb if _lum(c) < 0.74 else c * 0.78 + hexc('ink') * 0.1+ return self.line(path, width, colour, clip=clip, **kw)++ def dot(self, x, y, r, colour='ink', **kw):+ return self.shape(self.ellipse(x, y, r, r), colour, wobble=0.25, rough=0.3, **kw)++ # ------------------------------------------------------------------ people: parts+ def limb(self, path, widths, colour, cap=('round', 'flat'), gap=0.0, gap_keep=0.75, clip=None, avoid=None, seed=None):+ """a sleeve or a trouser leg: a fat tube along [shoulder/hip, elbow/knee, wrist/ankle], flat at the cuff"""+ return self.shape(self.tube(path, widths, cap), colour, wobble=1.2, gap=gap, gap_keep=gap_keep, clip=clip,+ avoid=avoid, seed=seed)++ def torso(self, sh_back, sh_front, hem_back, hem_front, colour, facing=1, collar=None, bulge=0.12, gap=0.0,+ hood=False, seed=None):+ """a boxy oversized top from its shoulders (back, front) and hem corners (back, front), built in its own+ frame (so it works for a figure lying down); `collar` = the neck base -- the neckline dips round it"""+ sb, sf, hb, hf = (np.asarray(p, np.float64) for p in (sh_back, sh_front, hem_back, hem_front))+ up = (sb + sf) / 2 - (hb + hf) / 2; up /= (np.hypot(*up) + 1e-9)+ fw = np.array([-up[1], up[0]])+ if np.dot(fw, sf - sb) < 0: fw = -fw+ dn = -up+ wid = np.hypot(*(sf - sb))+ cx = (sb + sf) / 2 if collar is None else np.asarray(collar, np.float64)++ def V(a, b):+ return fw * a * wid + dn * b * wid++ pts = [cx + V(-0.18, -0.02), sb + V(0.05, -0.06), sb + V(-0.07, 0.12), (sb + hb) / 2 + V(-bulge, 0),+ hb + V(-0.02, -0.04), hb + V(0.08, 0.015), (hb + hf) / 2 + V(0, 0.03), hf + V(-0.08, 0.015),+ hf + V(0.02, -0.04), (sf + hf) / 2 + V(bulge * 0.7, 0), sf + V(0.06, 0.12), sf + V(-0.04, -0.05),+ cx + V(0.2, 0.02), cx + V(0.0, 0.07)]+ if hood:+ pts[0] = cx + V(-0.3, -0.12)+ pts.insert(1, cx + V(-0.45, 0.0))+ return self.shape(pts, colour, smooth=True, wobble=1.3, gap=gap, seed=seed)++ def head(self, cx, cy, r, facing=1, turn=0.5, tilt=0.0, hair='bob', hair_colour='black', eye='dot', ear=False,+ strands=2, skin='paper', line='ink', mouth=None, fringe=1.0, hat='mustard', seed=None, draw_hair=True):+ """a head seen in profile (turn=0) to three-quarter (turn=1) facing right (+1) or left (-1): a white face+ with a profile line, a dot eye, a hair blob with cut strands. `eye`: 'dot', 'closed', 'smile', 'down',+ None. `hair`: 'bob', 'short', 'bun', 'long', 'cap', None. Returns a dict of useful points (chin, nape,+ eye, nose, mouth, top) and the face patch."""+ r_ = self._r(seed)+ ca, sa = np.cos(np.deg2rad(tilt)), np.sin(np.deg2rad(tilt))++ def X(pts):+ p = np.asarray(pts, np.float64) * r+ x, y = p[:, 0] * facing, p[:, 1]+ return np.stack([cx + x * ca - y * sa, cy + x * sa + y * ca], 1)++ nose = 0.13 * (1 - 0.55 * turn)+ face = [(0.0, -1.0), (0.5, -0.86), (0.78, -0.55), (0.86, -0.24), (0.85, -0.04), (0.86 + nose, 0.15),+ (0.83, 0.26), (0.845, 0.35), (0.82, 0.41), (0.835, 0.47), (0.79, 0.6), (0.77, 0.7), (0.66, 0.81),+ (0.42, 0.86), (0.12, 0.7), (-0.15, 0.55), (-0.72, 0.42), (-0.95, 0.0), (-0.74, -0.66)]+ skin_rgb = self.paper_rgb if skin == 'paper' else hexc(skin)+ F = self.shape(X(closed_spline(face, 6)), skin_rgb, wobble=0.5, rough=0.5, seed=int(r_.integers(1 << 30)))+ prof = [(0.84, -0.3), (0.85, -0.04), (0.86 + nose, 0.15), (0.83, 0.26), (0.845, 0.35), (0.82, 0.41),+ (0.835, 0.47), (0.79, 0.6), (0.77, 0.7), (0.66, 0.81), (0.45, 0.86)]+ lw = 0.042 * r+ self.line(X(prof), lw, line, taper=(0.25, 0.35), tip=0.15, wobble=0.3)+ out = dict(face=F, chin=X([(0.7, 0.82)])[0], nape=X([(-0.25, 0.55)])[0], eye=X([(0.5 + 0.08 * turn, -0.02)])[0],+ nose=X([(0.86 + nose, 0.15)])[0], mouth=X([(0.8, 0.43)])[0], top=X([(0.0, -1.0)])[0],+ neck_top=X([(0.2, 0.7)])[0], X=X)+ if ear:+ self.line(X([(-0.02, -0.05), (0.1, -0.12), (0.16, 0.05), (0.08, 0.22), (0.0, 0.2)]), lw * 0.9, line,+ taper=0.3, wobble=0.2)+ if draw_hair and hair:+ self.hair(out, hair, hair_colour, strands, fringe, hat, seed=int(r_.integers(1 << 30)))+ ex, ey = out['eye']+ if eye == 'dot':+ self.dot(ex, ey, 0.055 * r, line)+ elif eye == 'down':+ self.line(X([(0.43 + 0.08 * turn, 0.0), (0.5 + 0.08 * turn, 0.03), (0.57 + 0.08 * turn, 0.01)]), lw * 1.1,+ line, taper=0.3, wobble=0.1)+ elif eye == 'closed':+ self.line(X([(0.42 + 0.08 * turn, -0.01), (0.5 + 0.08 * turn, 0.04), (0.58 + 0.08 * turn, 0.0)]), lw * 1.1,+ line, taper=0.3, wobble=0.1)+ elif eye == 'smile':+ self.line(X([(0.42 + 0.08 * turn, 0.03), (0.5 + 0.08 * turn, -0.03), (0.58 + 0.08 * turn, 0.02)]), lw * 1.1,+ line, taper=0.3, wobble=0.1)+ if mouth == 'open':+ self.dot(*X([(0.78, 0.44)])[0], 0.045 * r, line)+ return out++ def hair(self, h, style='bob', colour='black', strands=2, fringe=1.0, hat='mustard', seed=None):+ """the hair blob for a head() result `h` (drawn by head() unless draw_hair=False)"""+ X = h['X']+ r_ = self._r(seed)+ fr = fringe+ if style == 'bob':+ pts = [(0.56, -0.84), (0.76, -0.6), (0.77, -0.34 + 0.08 * (1 - fr)), (0.66, -0.42), (0.56, -0.28), (0.46, -0.42),+ (0.34, -0.3), (0.24, -0.4), (0.15, -0.14), (0.14, 0.18), (0.1, 0.46), (0.02, 0.62), (-0.16, 0.56),+ (-0.36, 0.68), (-0.6, 0.56), (-0.84, 0.6), (-0.98, 0.3), (-1.08, -0.06), (-1.0, -0.5), (-0.84, -0.84),+ (-0.5, -1.06), (-0.12, -1.1), (0.26, -1.06)]+ elif style == 'short':+ pts = [(0.56, -0.86), (0.76, -0.62), (0.74, -0.44), (0.6, -0.5), (0.48, -0.38), (0.34, -0.48), (0.2, -0.36),+ (0.14, -0.12), (0.06, 0.1), (-0.1, 0.32), (-0.34, 0.3), (-0.6, 0.42), (-0.86, 0.26), (-1.02, -0.12),+ (-0.94, -0.6), (-0.66, -0.94), (-0.24, -1.1), (0.22, -1.06)]+ elif style == 'bun':+ pts = [(0.56, -0.84), (0.74, -0.6), (0.66, -0.5), (0.5, -0.56), (0.32, -0.46), (0.16, -0.24), (0.08, 0.06),+ (-0.08, 0.32), (-0.36, 0.36), (-0.66, 0.38), (-0.9, 0.18), (-1.02, -0.2), (-0.9, -0.66), (-0.5, -1.0),+ (-0.04, -1.08), (0.3, -1.02)]+ elif style == 'long':+ pts = [(0.56, -0.84), (0.76, -0.6), (0.76, -0.36), (0.64, -0.42), (0.54, -0.3), (0.44, -0.42), (0.32, -0.3),+ (0.22, -0.4), (0.14, -0.12), (0.12, 0.3), (0.06, 0.9), (-0.08, 1.38), (-0.32, 1.28), (-0.56, 1.46),+ (-0.86, 1.3), (-1.04, 0.8), (-1.08, 0.1), (-1.0, -0.5), (-0.84, -0.84), (-0.5, -1.06), (-0.12, -1.1),+ (0.26, -1.06)]+ elif style == 'cap':+ pts = [(0.4, -0.5), (0.2, -0.36), (0.12, -0.12), (0.06, 0.1), (-0.1, 0.32), (-0.34, 0.3), (-0.6, 0.42),+ (-0.86, 0.26), (-1.0, -0.12), (-0.9, -0.5)]+ else:+ return None+ P = self.shape(X(closed_spline(pts, 5)), colour, wobble=2.4, rough=1.0, lumps=34.0, seed=int(r_.integers(1 << 30)))+ flicks = {'bob': [((-0.3, 0.62), (-0.22, 0.8)), ((-0.72, 0.52), (-0.78, 0.68))],+ 'short': [((-0.4, 0.33), (-0.36, 0.48))],+ 'long': [((-0.3, 1.32), (-0.24, 1.5)), ((-0.8, 1.3), (-0.86, 1.46))]}.get(style, [])+ u_ = self._unit(X)+ for a_, b_ in flicks:+ self.shape(self.tube(X([a_, b_]), [0.1 * u_, 0.01 * u_], ('round', 'round'), smooth=False), colour, wobble=0.3)+ if style == 'bun':+ self.shape(self.blob(*X([(-0.62, -0.92)])[0], 0.36 * self._unit(X), rough=0.12), colour, wobble=1.5)+ if style == 'cap':+ crown = [(-0.96, -0.36), (-0.86, -0.82), (-0.4, -1.1), (0.2, -1.08), (0.6, -0.84), (0.72, -0.5), (0.2, -0.42),+ (-0.5, -0.4)]+ Cp = self.shape(X(closed_spline(crown, 6)), hat, wobble=1.2)+ self.shape(X(closed_spline([(0.5, -0.56), (0.9, -0.5), (1.12, -0.4), (0.9, -0.34), (0.5, -0.4)], 5)), hat,+ wobble=0.6)+ self.fold(X([(-0.2, -1.06), (-0.1, -0.7), (-0.12, -0.44)]), 2.0 * self.k, clip=Cp)+ self.dot(*X([(-0.12, -1.1)])[0], 0.05 * self._unit(X), hat)+ return self.union(P, Cp)+ # a couple of strands cut in white near the crown, along the hair's flow toward the face+ cand = [[(-0.5, -0.84), (-0.3, -0.8), (-0.1, -0.7)], [(-0.7, -0.5), (-0.6, -0.36), (-0.52, -0.22)],+ [(-0.14, -0.98), (0.06, -0.92), (0.22, -0.8)], [(-0.86, -0.1), (-0.8, 0.08), (-0.78, 0.24)]]+ if style == 'cap':+ cand = [[(-0.78, -0.3), (-0.66, -0.1), (-0.62, 0.1)]]+ w = 0.045 * self._unit(X)+ for c in cand[:strands]:+ j = np.asarray(c) + r_.normal(0, 0.025, (len(c), 2))+ self.cut(X(j), w, taper=(0.35, 0.45), tip=0.1, wobble=0.2, clip=P)+ return P++ @staticmethod+ def _unit(X):+ a, b = X([(0, 0), (1, 0)])+ return float(np.hypot(*(b - a)))++ def neck(self, top, bottom, w, skin='paper', line='ink', facing=1):+ """a white neck between the jaw and the collar, a thin line down its front"""+ top, bottom = np.asarray(top, np.float64), np.asarray(bottom, np.float64)+ skin_rgb = self.paper_rgb if skin == 'paper' else hexc(skin)+ P = self.shape(self.tube([top, bottom], w, 'flat', smooth=False), skin_rgb, wobble=0.4, rough=0.4)+ d = bottom - top+ n = np.array([d[1], -d[0]]) / (np.hypot(*d) + 1e-9) * facing+ a = top + n * w * 0.42 * -1+ self.line([a + d * 0.05, a + d * 0.4], 1.8 * self.k, line, taper=0.4, wobble=0.15)+ return P++ def hand(self, x, y, angle=0.0, size=40.0, pose='grip', facing=1, finger='red_line', skin='paper', line='ink',+ seed=None):+ """a white mitten-like hand with a thin outline and finger lines. (x, y) is the wrist; `angle` the direction+ the hand points (degrees, 0 = right); `pose`: 'grip' (closed round something, back of the hand seen),+ 'open' (flat, fingers together, thumb out), 'fist', 'flat' (palm down, resting), 'cup' (palm up). The+ finger lines are in the accent red by default (pass finger='ink' for dark)."""+ a = np.deg2rad(angle)+ ca, sa = np.cos(a), np.sin(a)+ s = size++ def X(pts):+ p = np.asarray(pts, np.float64) * s+ px, py = p[:, 0], p[:, 1] * facing+ return np.stack([x + px * ca - py * sa, y + px * sa + py * ca], 1)++ skin_rgb = self.paper_rgb if skin == 'paper' else hexc(skin)+ lw = max(1.6 * self.k, 0.055 * s)+ if pose in ('grip', 'fist'):+ # the back of a hand closed round something: four finger bumps along the front edge, red lines between+ front = []+ for i, yc in enumerate((-0.24, -0.08, 0.08, 0.24)):+ for t in np.linspace(-np.pi / 2, np.pi / 2, 5):+ front.append((0.8 + 0.07 * np.cos(t) - 0.03 * i * (pose == 'fist'), yc + 0.08 * np.sin(t)))+ body = [(-0.04, -0.27), (0.4, -0.33)] + front + [(0.45, 0.33), (0.0, 0.28)]+ P = self.shape(X(body), skin_rgb, wobble=0.25, rough=0.3)+ self.line(X([(0.3, -0.33)] + front + [(0.5, 0.33)]), lw, line, taper=(0.15, 0.3), wobble=0.1)+ for yy in (-0.16, 0.0, 0.16):+ self.line(X([(0.84, yy), (0.7, yy), (0.58, yy + 0.01)]), lw * 0.95, finger, taper=(0.1, 0.4), tip=0.3,+ wobble=0.05, clip=P)+ self.line(X([(0.12, -0.28), (0.36, -0.2), (0.56, -0.24)]), lw * 0.9, line, taper=0.3, wobble=0.1)+ elif pose == 'open':+ body = [(-0.05, -0.25), (0.4, -0.3), (0.9, -0.24), (1.08, -0.06), (1.06, 0.1), (0.82, 0.24), (0.4, 0.28),+ (0.0, 0.25)]+ thumb = [(0.18, -0.2), (0.42, -0.52), (0.55, -0.56), (0.55, -0.4), (0.42, -0.18)]+ T = self.shape(X(closed_spline(thumb, 5)), skin_rgb, wobble=0.3, rough=0.4)+ P = self.shape(X(closed_spline(body, 6)), skin_rgb, wobble=0.4, rough=0.4)+ self.line(X(open_spline([(0.25, -0.3), (0.45, -0.52), (0.56, -0.48), (0.48, -0.3)], 6)), lw, line, taper=0.3, wobble=0.1)+ self.line(X(open_spline([(0.5, -0.3), (0.9, -0.24), (1.08, -0.06), (1.06, 0.1), (0.82, 0.24), (0.45, 0.28)], 6)),+ lw, line, taper=(0.2, 0.3), wobble=0.15)+ for yy in (-0.12, 0.06):+ self.line(X([(0.62, yy - 0.01), (0.82, yy), (0.98, yy + 0.01)]), lw, finger, taper=0.35, wobble=0.1, clip=P)+ P = self.union(P, T)+ elif pose == 'flat':+ body = [(-0.05, -0.2), (0.4, -0.24), (0.95, -0.14), (1.08, 0.02), (0.95, 0.16), (0.4, 0.2), (0.0, 0.2)]+ P = self.shape(X(closed_spline(body, 6)), skin_rgb, wobble=0.4, rough=0.4)+ self.line(X(open_spline([(0.4, -0.24), (0.95, -0.14), (1.08, 0.02), (0.95, 0.16), (0.5, 0.2)], 6)), lw, line,+ taper=(0.2, 0.3), wobble=0.15)+ for yy in (-0.07, 0.07):+ self.line(X([(0.66, yy), (0.84, yy), (0.98, yy * 0.8)]), lw, finger, taper=0.35, wobble=0.1, clip=P)+ else: # 'cup': palm up, fingers curled up a little+ body = [(-0.05, -0.2), (0.4, -0.22), (0.8, -0.2), (1.0, -0.38), (1.06, -0.22), (0.96, 0.1), (0.6, 0.26),+ (0.1, 0.24)]+ P = self.shape(X(closed_spline(body, 6)), skin_rgb, wobble=0.4, rough=0.4)+ self.line(X(open_spline([(0.8, -0.2), (1.0, -0.38), (1.06, -0.22), (0.96, 0.1), (0.6, 0.26), (0.2, 0.25)], 6)),+ lw, line, taper=(0.2, 0.3), wobble=0.15)+ self.line(X([(0.7, -0.1), (0.86, -0.12), (0.96, -0.24)]), lw, finger, taper=0.35, wobble=0.1, clip=P)+ return P++ def shoe(self, x, y, angle=0.0, size=60.0, colour='paper', facing=1, sole='grey_mid', line='grey_dark', laces=True):+ """a sneaker: (x, y) the ankle, `size` the length heel to toe, `angle` the tilt of the sole (degrees)"""+ a = np.deg2rad(angle * facing)+ ca, sa = np.cos(a), np.sin(a)++ def X(pts):+ p = np.asarray(pts, np.float64) * size+ px, py = p[:, 0] * facing, p[:, 1]+ return np.stack([x + px * ca - py * sa, y + px * sa + py * ca], 1)++ body = [(-0.32, -0.12), (-0.08, -0.2), (0.12, -0.12), (0.38, 0.0), (0.66, 0.07), (0.72, 0.2), (0.66, 0.3),+ (-0.3, 0.3), (-0.38, 0.12)]+ if line is None: # a stocking foot: slimmer, the toe rounder, no sole+ body = [(-0.22, -0.16), (0.0, -0.14), (0.3, 0.0), (0.62, 0.06), (0.7, 0.16), (0.6, 0.24), (-0.22, 0.2),+ (-0.3, 0.04)]+ col = self.paper_rgb if colour == 'paper' else hexc(colour)+ P = self.shape(X(closed_spline(body, 6)), col, wobble=0.5, rough=0.5)+ if line is None: return P+ self.line(X(open_spline(body + [body[0]], 6)), max(1.5 * self.k, 0.04 * size), line, taper=0.05, wobble=0.15)+ self.line(X([(-0.34, 0.22), (0.2, 0.25), (0.7, 0.22)]), max(1.6 * self.k, 0.05 * size), sole, taper=0.2, wobble=0.1)+ if laces:+ for t in (0.0, 0.14):+ self.line(X([(0.08 + t, -0.06 + t * 0.4), (0.16 + t, 0.06 + t * 0.4)]), max(1.4 * self.k, 0.035 * size),+ line, taper=0.3, wobble=0.1)+ return P++ # ------------------------------------------------------------------ people: poses+ POSES = {+ # joints in head-heights (u), origin on the ground between the feet, facing right; y grows downward+ 'stand': dict(head=(0.14, -5.2), neck=(0.04, -4.74), sh_b=(-0.42, -4.48), sh_f=(0.42, -4.5), hem_b=(-0.5, -2.6),+ hem_f=(0.5, -2.62), hip_n=(-0.08, -2.75), hip_f=(0.16, -2.75), knee_n=(-0.04, -1.45),+ knee_f=(0.18, -1.45), ankle_n=(-0.06, -0.24), ankle_f=(0.22, -0.24), elbow_n=(-0.2, -3.45),+ wrist_n=(0.3, -3.0), elbow_f=(0.5, -3.5), wrist_f=(0.8, -3.1)),+ 'walk': dict(head=(0.26, -5.18), neck=(0.14, -4.72), sh_b=(-0.32, -4.46), sh_f=(0.5, -4.48), hem_b=(-0.42, -2.6),+ hem_f=(0.55, -2.62), hip_n=(0.0, -2.75), hip_f=(0.2, -2.75), knee_n=(0.5, -1.5), knee_f=(-0.12, -1.42),+ ankle_n=(0.7, -0.26), ankle_f=(-0.55, -0.34), elbow_n=(-0.28, -3.5), wrist_n=(-0.46, -2.7),+ elbow_f=(0.62, -3.55), wrist_f=(0.82, -2.8)),+ 'sit': dict(head=(0.2, -4.62), neck=(0.08, -4.16), sh_b=(-0.4, -3.92), sh_f=(0.42, -3.95), hem_b=(-0.52, -2.18),+ hem_f=(0.52, -2.2), hip_n=(-0.05, -2.05), hip_f=(0.1, -2.05), knee_n=(1.15, -2.15), knee_f=(1.2, -2.12),+ ankle_n=(1.12, -0.24), ankle_f=(1.28, -0.24), elbow_n=(0.0, -2.9), wrist_n=(0.68, -2.75),+ elbow_f=(0.5, -3.0), wrist_f=(0.95, -2.85)),+ 'crouch': dict(head=(0.78, -3.12), neck=(0.42, -2.72), sh_b=(-0.12, -2.72), sh_f=(0.62, -2.42), hem_b=(-0.6, -0.95),+ hem_f=(0.12, -0.9), hip_n=(-0.3, -0.85), hip_f=(-0.12, -0.85), knee_n=(0.55, -1.5), knee_f=(0.72, -1.4),+ ankle_n=(0.12, -0.22), ankle_f=(0.34, -0.2), elbow_n=(0.72, -1.82), wrist_n=(1.2, -1.05),+ elbow_f=(0.95, -2.05), wrist_f=(1.05, -1.5)),+ 'reach': dict(head=(0.2, -5.18), neck=(0.08, -4.74), sh_b=(-0.38, -4.48), sh_f=(0.45, -4.5), hem_b=(-0.48, -2.6),+ hem_f=(0.52, -2.62), hip_n=(-0.06, -2.75), hip_f=(0.16, -2.75), knee_n=(-0.02, -1.45),+ knee_f=(0.2, -1.45), ankle_n=(-0.05, -0.24), ankle_f=(0.26, -0.24), elbow_n=(0.2, -3.35),+ wrist_n=(0.95, -3.25), elbow_f=(0.7, -3.4), wrist_f=(1.3, -3.4)),+ }+ ORDER = {'crouch': ('leg_far', 'arm_far', 'hand_far', 'torso', 'leg_near', 'head', 'arm_near', 'hand_near'),+ 'default': ('leg_far', 'arm_far', 'hand_far', 'leg_near', 'torso', 'head', 'arm_near', 'hand_near')}++ def pose(self, name, x, y, u, facing=1, rot=0.0, rel=None, **joints):+ """joint positions (canvas px) for a preset pose, mirrored by `facing` and turned by `rot` degrees about+ (x, y); `rel` overrides joints in head units in the preset's own frame, keyword joints in canvas px"""+ P = dict(self.POSES[name])+ P.update(rel or {})+ c, s_ = np.cos(np.deg2rad(rot)), np.sin(np.deg2rad(rot))+ J = {}+ for k, (jx, jy) in P.items():+ dx, dy = jx * u * facing, jy * u+ J[k] = np.array([x + dx * c - dy * s_, y + dx * s_ + dy * c])+ for k, v in joints.items():+ if v is not None and k in J: J[k] = np.asarray(v, np.float64)+ return J++ def person(self, x, y, u, facing=1, pose='stand', outfit=None, hooks=None, rel=None, rot=0.0, J=None, order=None,+ folds=True, **joints):+ """a whole figure from a pose preset. `u` = one head height in px; `rot` turns the whole figure (degrees,+ -90 lays a right-facing figure on its back, head to the left); `rel` overrides joints in head units (the+ preset's frame), keyword joints in canvas px. `outfit` keys: top, bottom, hair, hair_style, shoes, sole,+ laces, socks, eye, turn, tilt, skin, hood, sleeve (if not the top's colour), apron, hand_n / hand_f (a+ hand pose, (pose, angle) or None to hide it), strands, fringe, coat (hem lower). `hooks` maps a layer name+ ('leg_far', 'arm_far', 'hand_far', 'leg_near', 'torso', 'head', 'arm_near', 'hand_near', 'end') to a+ function called *before* that layer -- slip props in between. `order` overrides the layer order. Returns+ the joints and the patches."""+ o = dict(top='mustard', bottom='navy', hair='black', hair_style='bob', shoes='paper', sole='grey_mid',+ laces=True, socks=None, eye='dot', turn=0.5, tilt=0.0, skin='paper', hood=False, sleeve=None,+ apron=None, hand_n='grip', hand_f='grip', strands=2, fringe=1.0, hat='mustard')+ o.update(outfit or {})+ hooks = hooks or {}+ J = J if J is not None else self.pose(pose, x, y, u, facing, rot, rel, **joints)+ f = facing+ cr, sr = np.cos(np.deg2rad(rot)), np.sin(np.deg2rad(rot))+ out = dict(J=J)+ top_c = o['top']; slv = o['sleeve'] or top_c+ legw = [0.62 * u, 0.56 * u, 0.5 * u]+ armw = [0.5 * u, 0.54 * u, 0.42 * u]+ order = order or self.ORDER.get(pose, self.ORDER['default'])++ def V(dx, dy):+ """an offset in the figure's frame (x forward, y down, head units) -> canvas px"""+ dx, dy = dx * u * f, dy * u+ return np.array([dx * cr - dy * sr, dx * sr + dy * cr])++ def unit(v):+ return v / (np.hypot(*v) + 1e-9)++ def leg(n):+ hip, knee, ank = J['hip_' + n], J['knee_' + n], J['ankle_' + n]+ d = unit(ank - knee)+ if o['socks']:+ self.limb([ank - d * 0.3 * u, ank + d * 0.06 * u], [0.28 * u, 0.28 * u], o['socks'], cap='flat')+ P = self.limb([hip, knee, ank - d * (0.2 if o['socks'] else 0.02) * u], legw, o['bottom'], cap=('round', 'flat'),+ gap=3.0 * self.k if n == 'n' else 0.0, gap_keep=0.85)+ if folds:+ t = unit(knee - hip); nn = np.array([-d[1], d[0]])+ fwd = V(1, 0) / u+ side = 1 if np.dot(nn, fwd) > 0 else -1+ self.fold([knee + d * 0.25 * u + nn * side * 0.06 * u, knee + d * 0.7 * u + nn * side * 0.1 * u,+ ank - d * 0.4 * u + nn * side * 0.08 * u], 2.4 * self.k, clip=P, taper=(0.3, 0.4))+ if np.hypot(*(knee - hip)) > 0.8 * u and np.dot(t, V(0, -1) / u) < 0.35:+ tn = np.array([-t[1], t[0]])+ self.fold([hip + t * 0.45 * u - tn * 0.1 * u, knee - t * 0.12 * u - tn * 0.04 * u], 2.2 * self.k, clip=P,+ taper=(0.35, 0.3))+ ang = 0.0+ if pose == 'walk': ang = 6 if n == 'n' else -16+ if pose == 'crouch': ang = 6 if n == 'n' else 2+ sp = ank + V(0.02, 0.07)+ if o['shoes'] is None: # stocking feet: the sock carries on into a foot+ self.shoe(sp[0], sp[1], ang + rot * f, 0.44 * u, o['socks'] or 'grey_light', f, line=None)+ else:+ self.shoe(sp[0], sp[1], ang + rot * f, 0.56 * u, o['shoes'], f, o['sole'], laces=o['laces'])+ return P++ def arm(n):+ sh = J['sh_b'] + V(0.14, 0.22) if n == 'n' else J['sh_f'] + V(-0.1, 0.2)+ e, w = J['elbow_' + n], J['wrist_' + n]+ P = self.limb([sh, e, w], armw, slv, cap=('round', 'flat'), gap=3.2 * self.k if n == 'n' else 0.0,+ gap_keep=0.92)+ if folds:+ a1, b1 = unit(e - sh), unit(w - e)+ cr_ = a1[0] * b1[1] - a1[1] * b1[0]+ nin = np.array([-a1[1], a1[0]]) * (1 if cr_ > 0 else -1)+ if abs(cr_) > 0.25:+ self.fold([e + nin * 0.24 * u - a1 * 0.1 * u, e + nin * 0.06 * u + (b1 - a1) * 0.02 * u,+ e - nin * 0.08 * u + b1 * 0.1 * u], 2.3 * self.k, clip=P, taper=(0.35, 0.45))+ self.fold([e + nin * 0.22 * u + b1 * 0.12 * u, e + nin * 0.08 * u + b1 * 0.22 * u], 2.0 * self.k, clip=P,+ taper=0.4)+ pb = np.array([-b1[1], b1[0]])+ self.fold([w - b1 * 0.2 * u + pb * 0.15 * u, w - b1 * 0.17 * u - pb * 0.12 * u], 2.0 * self.k, clip=P,+ taper=0.3)+ return P++ def hand(n):+ hp = o['hand_' + n]+ if hp is None: return None+ pose_, ang = (hp if isinstance(hp, tuple) else (hp, None))+ w, e = J['wrist_' + n], J['elbow_' + n]+ d = w - e+ if ang is None: ang = np.rad2deg(np.arctan2(d[1], d[0]))+ dd = unit(d)+ return self.hand(w[0] - dd[0] * 0.08 * u, w[1] - dd[1] * 0.08 * u, ang, 0.36 * u, pose_, f)++ def torso():+ hd = J['head']+ nt = hd + V(0.09, 0.25)+ self.neck(nt, J['neck'] + V(0.04, 0.14), 0.25 * u, facing=f)+ P = self.torso(J['sh_b'], J['sh_f'], J['hem_b'], J['hem_f'], top_c, f, collar=J['neck'], hood=o['hood'])+ if folds:+ hb, hf = J['hem_b'], J['hem_f']+ up = unit((J['sh_b'] + J['sh_f']) / 2 - (hb + hf) / 2)+ acr = np.array([-up[1], up[0]])+ c = hb + (hf - hb) * 0.3 + up * 0.12 * u+ self.fold([c, c + up * 0.32 * u + acr * 0.05 * u], 2.2 * self.k, clip=P, taper=0.35)+ if o['apron']:+ hb, hf = J['hem_b'], J['hem_f']+ top_l = J['neck'] + V(-0.08, 0.32); top_r = J['neck'] + V(0.36, 0.3)+ bot_l = (hb + hf) / 2 + V(-0.2, 0.95); bot_r = hf + V(0.14, 1.0)+ out['apron'] = self.shape([top_l, top_r, (top_r + bot_r) / 2 + V(0.14, 0), bot_r, bot_l,+ (top_l + bot_l) / 2 + V(-0.04, 0)], o['apron'], wobble=1.2)+ self.line([top_l, J['neck'] + V(-0.22, 0.04)], 2.4 * self.k, o['apron'], taper=0.0)+ return P++ def head():+ hd = J['head']+ return self.head(hd[0], hd[1], 0.5 * u, f, o['turn'], o['tilt'] + rot, o['hair_style'], o['hair'], o['eye'],+ strands=o['strands'], skin=o['skin'], fringe=o['fringe'], hat=o['hat'])++ parts = dict(leg_far=lambda: leg('f'), arm_far=lambda: arm('f'), hand_far=lambda: hand('f'),+ leg_near=lambda: leg('n'), torso=torso, head=head, arm_near=lambda: arm('n'),+ hand_near=lambda: hand('n'))+ for name in order:+ if name in hooks: hooks[name]()+ out[name] = parts[name]()+ if 'end' in hooks: hooks['end']()+ return out++ # ------------------------------------------------------------------ props+ def mug(self, x, y, h, colour='red', facing=1, handle=True, inner=None):+ """a mug standing on (x, y) (bottom centre), height h, the handle on the `facing` side, a darker rim+ ellipse (or `inner`)"""+ w = h * 0.86+ body = [(x - w / 2, y - h), (x + w / 2, y - h), (x + w / 2 * 0.97, y - h * 0.1), (x + w / 2 * 0.88, y),+ (x - w / 2 * 0.88, y), (x - w / 2 * 0.97, y - h * 0.1)]+ if handle:+ hx = x + facing * w / 2+ ring = self.tube([(hx - facing * 2, y - h * 0.78), (hx + facing * h * 0.32, y - h * 0.72),+ (hx + facing * h * 0.34, y - h * 0.38), (hx - facing * 2, y - h * 0.3)], h * 0.13, 'round')+ self.shape(ring, colour, wobble=0.5)+ P = self.shape(body, colour, wobble=0.6)+ self.shape(self.ellipse(x, y - h, w / 2 * 0.97, h * 0.1), inner or mix(colour, 'ink', 0.25), wobble=0.4, clip=P)+ return P++ def bowl(self, x, y, w, h=None, colour='red', inner='pale', fill=None):+ """a bowl sitting on (x, y) (bottom centre), width w; the rim shows a pale inside ('pale' = the colour mixed+ with paper) and `fill` paints what's in it"""+ h = w * 0.45 if h is None else h+ rim = self.ellipse(x, y - h, w / 2, w * 0.1)+ body = [(x - w / 2, y - h), (x + w / 2, y - h), (x + w * 0.4, y - h * 0.35), (x + w * 0.22, y - h * 0.03),+ (x - w * 0.22, y - h * 0.03), (x - w * 0.4, y - h * 0.35)]+ P = self.shape(closed_spline(body, 6), colour, wobble=0.7)+ self.shape(rim, mix(colour, 'paper', 0.7) if inner == 'pale' else inner, wobble=0.5)+ if fill:+ self.shape(self.ellipse(x, y - h + w * 0.02, w / 2 * 0.86, w * 0.07), fill, wobble=0.5)+ self.shape([(x - w * 0.2, y - h * 0.08), (x + w * 0.2, y - h * 0.08), (x + w * 0.22, y + 1), (x - w * 0.22, y + 1)],+ colour, wobble=0.4)+ return P++ def pot(self, x, y, w, colour='red', lid=True):+ """an enamel cooking pot on (x, y) (bottom centre), width w; two side handles, a lid with a dark knob"""+ h = w * 0.62+ P = self.shape(self.rrect(x - w / 2, y - h, x + w / 2, y, w * 0.08), colour, wobble=0.8)+ self.shape(self.rrect(x + w / 2 - 2, y - h * 0.82, x + w / 2 + w * 0.13, y - h * 0.7, w * 0.03), colour, wobble=0.4)+ self.shape(self.rrect(x - w / 2 - w * 0.13, y - h * 0.84, x - w / 2 + 2, y - h * 0.7, w * 0.03), colour, wobble=0.4)+ if lid:+ self.shape(self.ellipse(x, y - h, w * 0.52, w * 0.07), mix(colour, 'ink', 0.2), wobble=0.5)+ self.shape(self.ellipse(x, y - h - w * 0.06, w * 0.07, w * 0.04), 'ink', wobble=0.3)+ self.fold([(x - w * 0.36, y - h * 0.18), (x + w * 0.36, y - h * 0.18)], 2.0 * self.k, clip=P)+ return P++ def bag(self, x, y, w, h=None, colour='red', handles=True):+ """a tote bag, (x, y) its bottom centre, width w, height h; two strap loops on top"""+ h = w * 1.0 if h is None else h+ if handles:+ for dx in (-0.22, 0.22):+ self.line([(x + (dx - 0.1) * w, y - h * 0.95), (x + dx * w, y - h * 1.45), (x + (dx + 0.1) * w, y - h * 0.95)],+ w * 0.07, colour, taper=0.0, wobble=0.4)+ body = [(x - w * 0.46, y - h), (x + w * 0.46, y - h), (x + w * 0.5, y - h * 0.5), (x + w * 0.52, y),+ (x - w * 0.52, y), (x - w * 0.5, y - h * 0.5)]+ return self.shape(body, colour, smooth=False, wobble=1.0)++ def umbrella(self, x, y, r, angle=0.0, colour='red', handle_len=None, line='ink'):+ """an open umbrella: (x, y) the top of the shaft, r the canopy radius, `angle` its tilt (deg, + leans the top+ to the right), `handle_len` the shaft length in canopy radii (default 1.75), a crook at the end"""+ a = np.deg2rad(angle)+ ca, sa = np.cos(a), np.sin(a)++ def X(pts):+ p = np.asarray(pts, np.float64) * r+ return np.stack([x + p[:, 0] * ca - p[:, 1] * sa, y + p[:, 0] * sa + p[:, 1] * ca], 1)++ L = 1.75 if handle_len is None else handle_len+ self.line(X([(0, 0.02), (0, L)]), max(2.2 * self.k, 0.045 * r), line, taper=0.0, wobble=0.15, smooth=False)+ self.line(X([(0, L - 0.02), (0.0, L + 0.12), (0.1, L + 0.2), (0.2, L + 0.12)]), max(2.4 * self.k, 0.05 * r), line,+ taper=(0, 0.3), wobble=0.1)+ t = np.linspace(np.pi, 2 * np.pi, 40)+ dome = list(zip(np.cos(t) * 1.0, np.sin(t) * 0.72 + 0.36))+ sc = []+ for i in range(4):+ x0_, x1_ = 1.0 - i * 0.5, 1.0 - (i + 1) * 0.5+ for tt in np.linspace(0, 1, 8)[1:]:+ xx = x0_ + (x1_ - x0_) * tt+ sc.append((xx, 0.36 - 0.1 * np.sin(np.pi * tt)))+ P = self.shape(X(dome + sc), colour, wobble=1.0)+ for xx in (-0.5, 0.0, 0.5):+ self.cut(X([(0, -0.34), (xx * 0.6, -0.1), (xx, 0.27)]), 2.2 * self.k, taper=(0.1, 0.3), clip=P, wobble=0.2)+ self.shape(X(self.ellipse(0, -0.4, 0.04, 0.05) / 1.0), line, wobble=0.2)+ return P++ def bench(self, x0, x1, y, h, colour='grey_light', legs='ink', back=True):+ """a park bench seen from the front: floor at y, seat height h (seat top at y - h), a back rail above it"""+ t = h * 0.13+ if back:+ self.shape(self.rrect(x0 + h * 0.1, y - h * 1.78, x1 - h * 0.1, y - h * 1.6, 3 * self.k), colour, wobble=0.8)+ for xx in (x0 + h * 0.3, x1 - h * 0.3):+ self.line([(xx, y - h * 1.62), (xx, y - h)], 3.0 * self.k, legs, taper=(0, 0.1), wobble=0.3)+ for xx in (x0 + h * 0.18, x0 + h * 0.36, x1 - h * 0.36, x1 - h * 0.18):+ self.line([(xx, y - h + t * 0.5), (xx + (xx - (x0 + x1) / 2) * 0.03, y)], 3.2 * self.k, legs, taper=(0, 0.1),+ wobble=0.3)+ return self.shape(self.rrect(x0, y - h - t * 0.5, x1, y - h + t * 0.6, 3 * self.k), colour, wobble=0.8)++ def chair(self, x, y, h, facing=1, colour='wood', legs='ink'):+ """a simple chair in profile, seat at (x, y) (seat front-back centre), seat height h"""+ f = facing+ d = h * 0.5+ for xx in (x - f * d * 0.42, x + f * d * 0.42):+ self.line([(xx, y), (xx, y + h)], 3.0 * self.k, legs, taper=(0, 0.1), wobble=0.3)+ self.line([(x - f * d * 0.48, y), (x - f * d * 0.56, y - h * 1.0)], 3.0 * self.k, legs, taper=(0, 0.1), wobble=0.3)+ self.shape(self.rrect(x - f * d * 0.62 - 1, y - h * 1.0, x - f * d * 0.42, y - h * 0.62, 3 * self.k) if f > 0 else+ self.rrect(x + d * 0.42, y - h * 1.0, x + d * 0.62, y - h * 0.62, 3 * self.k), colour, wobble=0.7)+ return self.shape(self.rrect(x - d * 0.55, y - h * 0.05, x + d * 0.55, y + h * 0.07, 3 * self.k), colour, wobble=0.7)++ def armchair(self, x, y, w, h, facing=1, colour='olive', legs='ink'):+ """a soft armchair in profile: (x, y) the floor under its middle, width w, height h (top of the back).+ Draws the legs, back and seat; returns a dict with 'arm' -- call it after the sitter's legs and body to lay+ the near armrest over them."""+ f = facing+ for xx in (x - f * w * 0.4, x + f * w * 0.4):+ self.line([(xx, y - h * 0.12), (xx + (xx - x) * 0.05, y)], 3.4 * self.k, legs, taper=(0, 0.1), wobble=0.3)+ back = [(x - f * w * 0.52, y - h * 0.9), (x - f * w * 0.44, y - h), (x - f * w * 0.26, y - h * 0.99),+ (x - f * w * 0.18, y - h * 0.9), (x - f * w * 0.22, y - h * 0.5), (x - f * w * 0.3, y - h * 0.3),+ (x - f * w * 0.52, y - h * 0.3), (x - f * w * 0.56, y - h * 0.6)]+ B = self.shape(back, colour, smooth=True, wobble=1.0)+ seat = [(x - f * w * 0.38, y - h * 0.44), (x + f * w * 0.44, y - h * 0.45), (x + f * w * 0.5, y - h * 0.39),+ (x + f * w * 0.5, y - h * 0.3), (x - f * w * 0.48, y - h * 0.3)]+ S = self.shape(seat, colour, smooth=False, wobble=1.0, gap=2.6 * self.k)+ base = self.shape(self.rrect(x - w * 0.54, y - h * 0.31, x + w * 0.54, y - h * 0.12, h * 0.04), colour, wobble=0.8,+ gap=2.6 * self.k)++ def arm():+ pts = [(x - f * w * 0.3, y - h * 0.55), (x + f * w * 0.3, y - h * 0.565), (x + f * w * 0.4, y - h * 0.52),+ (x + f * w * 0.38, y - h * 0.31), (x - f * w * 0.3, y - h * 0.31)]+ A = self.shape(pts, colour, smooth=True, wobble=1.0, gap=2.8 * self.k)+ self.fold([(x + f * w * 0.3, y - h * 0.5), (x + f * w * 0.32, y - h * 0.36)], 2.2 * self.k, clip=A)+ return A+ return dict(back=B, seat=S, base=base, arm=arm)++ def sofa(self, x0, x1, y, h, colour='grey_light', legs='ink', arm_colour=None):+ """a low sofa from the front: floor at y, height h"""+ w = x1 - x0+ for xx in (x0 + w * 0.06, x1 - w * 0.06):+ self.line([(xx, y - h * 0.12), (xx, y)], 3.2 * self.k, legs, taper=(0, 0.1), wobble=0.3)+ B = self.shape(self.rrect(x0 + w * 0.05, y - h, x1 - w * 0.05, y - h * 0.4, h * 0.14), colour, wobble=1.0)+ S = self.shape(self.rrect(x0 + w * 0.04, y - h * 0.5, x1 - w * 0.04, y - h * 0.12, h * 0.08), colour, wobble=1.0,+ gap=2.4 * self.k)+ ac = arm_colour or colour+ A1 = self.shape(self.rrect(x0, y - h * 0.72, x0 + w * 0.09, y - h * 0.12, h * 0.1), ac, wobble=1.0, gap=2.4 * self.k)+ A2 = self.shape(self.rrect(x1 - w * 0.09, y - h * 0.72, x1, y - h * 0.12, h * 0.1), ac, wobble=1.0, gap=2.4 * self.k)+ return dict(back=B, seat=S, arms=(A1, A2))++ def stool(self, x, y, w, h, colour='wood', legs='ink'):+ """a small side stool: top at (x, y - h) ... floor at y"""+ for dx in (-0.36, 0.36):+ self.line([(x + dx * w, y - h), (x + dx * w * 1.15, y)], 3.0 * self.k, legs, taper=(0, 0.1), wobble=0.3)+ return self.shape(self.rrect(x - w / 2, y - h - w * 0.08, x + w / 2, y - h + w * 0.02, 3 * self.k), colour, wobble=0.6)++ def table(self, x0, x1, y, h, colour='wood_light', legs='ink'):+ for xx in (x0 + (x1 - x0) * 0.08, x1 - (x1 - x0) * 0.08):+ self.line([(xx, y - h), (xx, y)], 3.2 * self.k, legs, taper=(0, 0.1), wobble=0.3)+ return self.shape(self.rrect(x0, y - h - 6 * self.k, x1, y - h + 6 * self.k, 3 * self.k), colour, wobble=0.6)++ def stove(self, x0, x1, y, h, colour='grey_light', knobs='ink', top='wood_light'):+ """a kitchen counter / stove block: worktop at y - h, floor at y; a door seam and a row of small knobs"""+ P = self.shape(self.rrect(x0, y - h, x1, y, 4 * self.k), colour, wobble=0.8)+ self.shape(self.rrect(x0 - 6 * self.k, y - h - 7 * self.k, x1 + 6 * self.k, y - h + 9 * self.k, 3 * self.k), top,+ wobble=0.6)+ w = x1 - x0+ self.fold([(x0 + w * 0.5, y - h * 0.8), (x0 + w * 0.5, y - h * 0.06)], 2.2 * self.k, clip=P)+ self.fold([(x0 + w * 0.08, y - h * 0.8), (x1 - w * 0.08, y - h * 0.8)], 2.2 * self.k, clip=P)+ for i in range(3):+ self.dot(x0 + w * (0.25 + 0.25 * i), y - h * 0.9, max(2.5, h * 0.025), knobs)+ for xx in (x0 + w * 0.42, x0 + w * 0.58):+ self.line([(xx, y - h * 0.52), (xx, y - h * 0.38)], 2.6 * self.k, knobs, taper=0.1, wobble=0.1)+ return P++ def plant(self, x, y, h, pot='red', leaf='green', leaves=7, seed=None):+ """a potted plant on (x, y): a small pot and long flat leaves"""+ r = self._r(seed)+ w = h * 0.42+ for i in range(leaves):+ a = np.deg2rad(-90 + (i - (leaves - 1) / 2) * (110 / max(leaves - 1, 1)) + r.normal(0, 6))+ L = h * (0.75 + 0.35 * r.random())+ base = np.array([x + (i - (leaves - 1) / 2) * w * 0.06, y - w * 0.7])+ tip = base + np.array([np.cos(a), np.sin(a)]) * L+ mid = (base + tip) / 2 + np.array([-np.sin(a), np.cos(a)]) * L * 0.12 * (1 if i % 2 else -1)+ pts = self.tube([base, mid, tip], [w * 0.2, w * 0.26, w * 0.02], ('round', 'round'))+ P = self.shape(pts, leaf if i % 3 else mix(leaf, 'ink', 0.18), wobble=0.6)+ self.fold([base + (tip - base) * 0.15, mid, base + (tip - base) * 0.85], 1.6 * self.k, clip=P)+ return self.shape([(x - w / 2, y - w * 0.8), (x + w / 2, y - w * 0.8), (x + w * 0.38, y), (x - w * 0.38, y)], pot,+ wobble=0.7)++ def book(self, x, y, w, angle=0.0, colour='blue', pages='paper', open_=True, line='ink'):+ """a book held open (x, y centre, width w across both pages) or closed"""+ a = np.deg2rad(angle)+ ca, sa = np.cos(a), np.sin(a)++ def X(pts):+ p = np.asarray(pts, np.float64) * w+ return np.stack([x + p[:, 0] * ca - p[:, 1] * sa, y + p[:, 0] * sa + p[:, 1] * ca], 1)++ if open_ == 'tent':+ # lying open, face down: the back cover is a low solid tent, the page edges a pale strip at its foot+ C = self.shape(X(closed_spline([(-0.52, 0.02), (-0.2, -0.24), (0.0, -0.36), (0.2, -0.24), (0.52, 0.02)], 5)),+ colour, wobble=0.6)+ self.shape(X([(-0.46, -0.02), (0.46, -0.02), (0.44, 0.06), (-0.44, 0.06)]), pages, wobble=0.4)+ self.cut(X([(0.0, -0.34), (0.03, -0.14), (0.04, 0.0)]), 2.2 * self.k, taper=0.3, clip=C)+ return C+ if open_:+ C = self.shape(X([(-0.52, -0.3), (0.0, -0.26), (0.52, -0.3), (0.53, 0.32), (0.0, 0.36), (-0.53, 0.32)]), colour,+ wobble=0.6)+ Pg = self.shape(X([(-0.47, -0.36), (-0.2, -0.38), (0.0, -0.3), (0.2, -0.38), (0.47, -0.36), (0.48, 0.26),+ (0.2, 0.24), (0.0, 0.3), (-0.2, 0.24), (-0.48, 0.26)]), pages, smooth=False, wobble=0.5)+ self.line(X([(0.0, -0.3), (0.0, 0.3)]), 1.8 * self.k, line, taper=0.2, wobble=0.1)+ for yy in (-0.18, -0.06, 0.06):+ for s_ in (-1, 1):+ self.line(X([(s_ * 0.1, yy), (s_ * 0.38, yy - 0.01)]), 1.4 * self.k, 'grey', taper=0.2, wobble=0.1)+ return self.union(C, Pg)+ C = self.shape(X(self.rrect(-0.5, -0.36, 0.5, 0.36, 0.03)), colour, wobble=0.6)+ self.fold(X([(-0.38, -0.36), (-0.38, 0.36)]), 2.0 * self.k, clip=C, smooth=False)+ return C++ def cat_sit(self, x, y, h, facing=1, colour='black', head_down=0.0, eye='dot', tail=True, seed=None):+ """a sitting cat on (x, y) (between its front paws), height h; head_down 0..1 lowers the head (eating)"""+ f = facing+ u = h++ def X(pts):+ p = np.asarray(pts, np.float64) * u+ return np.stack([x + p[:, 0] * f, y + p[:, 1]], 1)++ if tail:+ self.limb(X([(-0.42, -0.06), (-0.75, -0.02), (-0.86, -0.18)]), [0.1 * u, 0.09 * u, 0.07 * u], colour,+ cap='round')+ body = [(0.12, -0.62 + 0.2 * head_down), (0.22, -0.3), (0.22, -0.02), (-0.1, 0.0), (-0.48, -0.02), (-0.56, -0.24),+ (-0.38, -0.5), (-0.1, -0.64 + 0.15 * head_down)]+ B = self.shape(X(closed_spline(body, 6)), colour, wobble=1.0)+ hx, hy = 0.2 + 0.18 * head_down, -0.72 + 0.5 * head_down+ Hd = self.shape(X(closed_spline([(hx - 0.2, hy - 0.04), (hx - 0.16, hy - 0.2), (hx - 0.08, hy - 0.34),+ (hx, hy - 0.2), (hx + 0.1, hy - 0.22), (hx + 0.16, hy - 0.36), (hx + 0.22, hy - 0.16),+ (hx + 0.24, hy + 0.04), (hx + 0.06, hy + 0.14), (hx - 0.14, hy + 0.12)], 5)),+ colour, wobble=0.8)+ self.fold(X([(0.02, -0.12), (0.06, -0.01)]), 1.8 * self.k, clip=B)+ self.fold(X([(-0.26, -0.36), (-0.36, -0.2), (-0.32, -0.06)]), 1.8 * self.k, clip=B)+ if eye == 'dot':+ self.dot(*X([(hx + 0.12, hy - 0.02)])[0], 0.025 * u, 'paper')+ elif eye == 'closed':+ self.cut(X([(hx + 0.06, hy - 0.0), (hx + 0.11, hy + 0.025), (hx + 0.16, hy + 0.0)]), 1.8 * self.k, taper=0.3)+ return self.union(B, Hd)++ def cat_curl(self, x, y, w, colour='black', facing=1):+ """a cat curled up asleep, (x, y) the bottom centre, width w"""+ f = facing++ def X(pts):+ p = np.asarray(pts, np.float64) * w+ return np.stack([x + p[:, 0] * f, y + p[:, 1]], 1)++ B = self.shape(X(closed_spline([(-0.5, -0.02), (-0.46, -0.24), (-0.18, -0.4), (0.18, -0.38), (0.44, -0.22),+ (0.5, 0.0)], 6)), colour, wobble=1.0)+ Hd = self.shape(X(closed_spline([(0.12, -0.02), (0.14, -0.22), (0.22, -0.36), (0.3, -0.24), (0.42, -0.26),+ (0.48, -0.36), (0.52, -0.16), (0.5, 0.0)], 5)), colour, wobble=0.7, gap=2.0 * self.k)+ self.cut(X([(0.33, -0.12), (0.37, -0.1), (0.41, -0.12)]), 1.6 * self.k, taper=0.3)+ self.cut(X([(-0.42, -0.06), (-0.2, -0.12), (0.06, -0.08)]), 1.8 * self.k, taper=0.3, clip=B)+ return self.union(B, Hd)++ def window(self, x0, y0, x1, y1, frame='ink', rain=True, seed=None):+ """a window frame drawn in thin lines, a few rain streaks behind the glass"""+ lw = 2.4 * self.k+ self.line([(x0, y0), (x1, y0), (x1, y1), (x0, y1), (x0, y0)], lw, frame, taper=0.0, wobble=0.4, smooth=False)+ self.line([((x0 + x1) / 2, y0), ((x0 + x1) / 2, y1)], lw, frame, taper=0.0, wobble=0.3, smooth=False)+ self.line([(x0, (y0 + y1) / 2), (x1, (y0 + y1) / 2)], lw, frame, taper=0.0, wobble=0.3, smooth=False)+ if rain:+ self.rain(x0 + 10 * self.k, y0 + 10 * self.k, x1 - 10 * self.k, y1 - 10 * self.k, n=14, colour='powder',+ slant=0.0, seed=seed)++ def bicycle(self, x, y, size, facing=1, frame='red', wheels='ink', basket=True, saddle='ink'):+ """a city bicycle on the ground at (x, y) (between the wheels), wheelbase `size`"""+ f = facing+ R = size * 0.36+ rw = (x - f * size / 2, y - R); fw = (x + f * size / 2, y - R)+ for cx, cy in (rw, fw):+ self.line(self.ellipse(cx, cy, R, R, n=80), 3.4 * self.k, wheels, taper=0.0, wobble=0.4, closed=True)+ for a in np.linspace(0, 2 * np.pi, 9)[:-1] + 0.3:+ self.line([(cx + np.cos(a) * R * 0.45, cy + np.sin(a) * R * 0.45), (cx + np.cos(a) * R * 0.7, cy + np.sin(a) * R * 0.7)],+ 1.8 * self.k, wheels, taper=0.2, wobble=0.1, smooth=False)+ self.dot(cx, cy, 3.5 * self.k, frame)+ crank = (x - f * size * 0.05, y - R * 0.95)+ seat = (x - f * size * 0.18, y - R * 2.25)+ head = (x + f * size * 0.32, y - R * 2.2)+ fw_ = np.array(fw)+ w = 4.2 * self.k+ for a_, b_ in ((rw, crank), (crank, seat), (rw, seat), (crank, head), (seat, head), (head, fw_)):+ self.line([a_, b_], w, frame, taper=0.0, wobble=0.3, smooth=False)+ self.line([seat, (seat[0] - f * size * 0.02, seat[1] - R * 0.25)], w, frame, taper=0.0, smooth=False)+ self.shape(self.rrect(seat[0] - f * size * 0.1 - size * 0.02, seat[1] - R * 0.34, seat[0] + f * size * 0.06 + size * 0.02,+ seat[1] - R * 0.22, R * 0.06), saddle, wobble=0.5)+ hb = (head[0] - f * size * 0.04, head[1] - R * 0.3)+ self.line([head, hb, (hb[0] - f * size * 0.12, hb[1] - R * 0.04)], w * 0.9, wheels, taper=0.0, wobble=0.3)+ self.dot(crank[0], crank[1], 6 * self.k, wheels)+ if basket:+ bx = fw[0] + f * size * 0.02+ pts = [(bx - size * 0.13, head[1] - R * 0.05), (bx + size * 0.13, head[1] - R * 0.05),+ (bx + size * 0.11, head[1] + R * 0.5), (bx - size * 0.11, head[1] + R * 0.5)]+ self.line(pts + [pts[0]], 2.0 * self.k, 'grey_mid', taper=0.0, wobble=0.3, smooth=False)+ for t in (0.33, 0.66):+ self.line([(pts[0][0] + (pts[1][0] - pts[0][0]) * t, pts[0][1]), (pts[3][0] + (pts[2][0] - pts[3][0]) * t, pts[3][1])],+ 1.6 * self.k, 'grey_mid', taper=0.0, smooth=False)+ self.line([(pts[0][0], (pts[0][1] + pts[3][1]) / 2), (pts[1][0], (pts[1][1] + pts[2][1]) / 2)], 1.6 * self.k,+ 'grey_mid', taper=0.0, smooth=False)+ return dict(rear=rw, front=fw, seat=seat, bars=(hb[0] - f * size * 0.12, hb[1] - R * 0.04), crank=crank)++ # ------------------------------------------------------------------ marks+ def steam(self, x, y, h, n=2, colour='red_line', width=None, seed=None):+ """steam: n thin S-squiggles rising from (x, y)"""+ r = self._r(seed)+ width = 2.6 * self.k if width is None else width+ for i in range(n):+ x0 = x + (i - (n - 1) / 2) * h * 0.32 + r.normal(0, h * 0.03)+ t = np.linspace(0, 1, 18)+ ph = r.random() * np.pi+ xs = x0 + np.sin(t * 2.6 * np.pi + ph) * h * 0.1 * (0.6 + t)+ ys = y - t * h * (0.85 + 0.25 * r.random())+ self.line(np.stack([xs, ys], 1), width, colour, taper=(0.2, 0.35), tip=0.3, wobble=0.2)++ def bang(self, x, y, r, angle=-90.0, colour='red_line', n=3, width=None):+ """three short dashes fanning out from a point (surprise, a sound): drawn around (x, y) at radius r"""+ width = 2.8 * self.k if width is None else width+ for i in range(n):+ a = np.deg2rad(angle + (i - (n - 1) / 2) * 32)+ p0 = (x + np.cos(a) * r, y + np.sin(a) * r)+ L = r * (0.75 if i != (n - 1) // 2 else 0.95)+ p1 = (x + np.cos(a) * (r + L), y + np.sin(a) * (r + L))+ self.line([p0, p1], width, colour, taper=(0.1, 0.3), wobble=0.1, smooth=False)++ def zzz(self, x, y, size, colour='navy', n=2, width=None):+ """small z's rising up and to the right from (x, y)"""+ width = 2.6 * self.k if width is None else width+ for i in range(n):+ sz = size * (1 - 0.3 * i)+ zx, zy = x + i * size * 1.25, y - i * size * 1.05+ self.line([(zx, zy), (zx + sz, zy + sz * 0.04), (zx + sz * 0.08, zy + sz), (zx + sz * 1.02, zy + sz * 0.96)],+ width, colour, taper=0.05, wobble=0.15, smooth=False)++ def rain(self, x0, y0, x1, y1, n=20, colour='powder', slant=0.25, length=None, width=None, seed=None, avoid=None):+ """short slanted rain dashes scattered in a box"""+ r = self._r(seed)+ length = 26 * self.k if length is None else length+ width = 2.4 * self.k if width is None else width+ for _ in range(n):+ px, py = r.uniform(x0, x1), r.uniform(y0, y1)+ L = length * r.uniform(0.6, 1.3)+ self.line([(px, py), (px - slant * L, py + L)], width, colour, taper=0.3, wobble=0.1, smooth=False, avoid=avoid)++ def ticks(self, x, y, r, angle=180.0, n=3, colour='red_line', spread=26.0, width=None):+ """motion ticks: short parallel dashes behind something moving (angle = direction they point)"""+ width = 2.6 * self.k if width is None else width+ a = np.deg2rad(angle)+ d = np.array([np.cos(a), np.sin(a)]); nrm = np.array([-d[1], d[0]])+ for i in range(n):+ o = (i - (n - 1) / 2) * spread * self.k+ p0 = np.array([x, y]) + nrm * o + d * abs(o) * 0.3+ self.line([p0, p0 + d * r * (0.8 if i != (n - 1) // 2 else 1.0)], width, colour, taper=0.2, wobble=0.1, smooth=False)++ def shadow(self, cx, cy, rx, ry=None, colour='grey_light'):+ """a sliver of shadow under something"""+ ry = rx * 0.08 if ry is None else ry+ return self.shape(self.ellipse(cx, cy, rx, ry), colour, wobble=0.8)++ # ------------------------------------------------------------------ output+ def render(self):+ C = self.C+ f = self.fin+ if not f: return np.clip(C, 0, 1)+ out = C.copy()+ ink = np.clip(np.abs(C - self.paper_rgb).max(-1) / 0.06, 0, 1)+ g = f['grain']+ if g:+ # a print's grain: a soft mottle and a fine tooth in the ink, the faintest tooth on the bare paper+ k = (0.028 * (self.mid - 0.5) + 0.05 * (self.fine - 0.5)) * g+ out *= (1 + k * ink + 0.012 * g * (self.fine - 0.5) * (1 - ink))[..., None]+ sp = f['speckle']+ if sp:+ s = smoothstep(0.78, 0.95, self.fine) * smoothstep(0.35, 0.75, self.mid) * 0.16 * sp * ink+ out += (self.paper_rgb - out) * s[..., None]+ if f['soft']:+ for c in range(3): out[..., c] = out[..., c] * (1 - f['soft']) + blur(out[..., c], 0.55) * f['soft']+ return np.clip(out, 0, 1)++ def composite(self):+ out = self.render() * 255 + 0.5+ return Image.fromarray(out.astype(np.uint8))++ def stage(self, name):+ if not self.keep_stages: return+ im = self.composite()+ if self.stages_dir:+ os.makedirs(self.stages_dir, exist_ok=True)+ im.save(f'{self.stages_dir}/{self._n_stages:02d}_{name}.png', compress_level=1)+ else:+ b = io.BytesIO(); im.save(b, 'PNG', compress_level=1)+ self.stages.append((name, b.getvalue()))+ self._n_stages += 1++ def save(self, path, stages_dir=None, quality=92):+ img = self.composite()+ if str(path).lower().endswith(('.jpg', '.jpeg')): img.save(path, quality=quality, subsampling=0)+ else: img.save(path)+ sd = stages_dir or self.stages_dir+ if sd and self.keep_stages and self.stages:+ os.makedirs(sd, exist_ok=True)+ for i, (name, b) in enumerate(self.stages):+ with open(f'{sd}/{i:02d}_{name}.png', 'wb') as fh: fh.write(b)