CONTEXTFREE(1)

πŸ“¦
version 3.4.2 Β· 2 versions
  • 3.4.2 Β· debian bookworm, debian trixie, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking (latest)
  • 3.3 Β· ubuntu jammy
, in debian bookworm, debian trixie, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– CONTEXTFREE(1) β€” the Context Free era πŸ’–

okay bestie, sit down, hydrate, because we're about to talk about Context Free and its little command-line icon cfdg. she's giving generative art, she's giving grammar queen, she's lowkey the blueprint. πŸ¦‹


✨ NAME ✨

cfdg β€” image generator based on context-free grammars. periodt. 🌸


🌈 SYNOPSIS 🌈

cfdg [options] input.cfdg [output.png/svg/mov]

that's it. that's the whole vibe. πŸ’…


πŸŽ€ DESCRIPTION πŸŽ€

so Context Free is a whole system that makes images out of context-free grammars. it's giving math but make it art. and cfdg is the command-line program that actually generates the images (in PNG or SVG format, bestie) from that input.cfdg file where the grammars live. no cap.

and not me telling you that .cfdg files can also be animated?? they can!! the output can either be PNG files of individual frames or a QuickTime .mov file. your choice, main character.

if you put - instead of an input file, the grammar gets read from standard input. very demure, very mindful. πŸ™ˆ

the output filename can just be ✨left out✨ if you're using the -o/--outputtemplate option or the -C/--check option. and if you specify --display and there's no output file, the output gets saved in a temporary file instead.

⚠️ okay real talk, this is the important one: the output mode (PNG, SVG, or MOV) is NOT detected from the file extension you give it. it is not doing that. you have to explicitly set it with -V/--svg or -Q/--quicktime. do not come for me when your .svg comes out as a PNG, bestie, I warned you. πŸ’€

πŸ‘‘ OPTIONS πŸ‘‘

every command-line option is a single letter with an optional argument, and longer "GNU-style" options exist too. here's the full summary of what cfdg supports, no skips, no cuts. 🫢

  • -w WIDTH, --width=WIDTH β€” sets the width of the output image, in pixels for PNG or millimeters for SVG. default is 500. 🌸
  • -h HEIGHT, --height=HEIGHT β€” sets the height of the output image, in pixels for PNG or millimeters for SVG. default is 500. 🌸
  • -s SIZE, --size=SIZE β€” sets both width and height of the output image to the same value, in pixels for PNG or millimeters for SVG. one number, two dimensions, iconic. ✨
  • -s WIDTHxHEIGHT, --size=WIDTHxHEIGHT β€” sets both width and height of the output image, in pixels for PNG or millimeters for SVG. ✨
  • -T SIZE, --tile=SIZE β€” multiplies both width and height of the tiled output image by the same amount. 🧚
  • -T WIDTHxHEIGHT, --tile=WIDTHxHEIGHT β€” multiplies both width and height of the tiled output image by the given amounts. 🧚
  • -m MAXSHAPES, --maxshapes=MAXSHAPES β€” sets the maximum number of shapes rendered. default is no maximum, so like… be careful out there. 😭
  • -x MINIMUMSIZE, --minimumsize=MINIMUMSIZE β€” sets the minimum size for a shape to be rendered, in pixels/mm. default is 0.3. πŸ“
  • -b BORDERSIZE, --bordersize=BORDERSIZE β€” sets the border size. the values are: -1 for a -8 pixel border, 0 for no border, 1 for an 8 pixel border, or 2 for a variable-sized border. pick your fighter. πŸ’…
  • -v VARIATION, --variation=VARIATION β€” sets the variation code. default is random. this code is literally what determines what the final image looks like when your input has non-deterministic rules. it's the ✨destiny✨ field.
  • -DNAME=VALUE β€” declares a variable, configuration, or function. any declaration you could make at global scope can be entered at the command line with this option, fr fr. command line declarations override any global-scope declarations in the .cfdg file with the same name. πŸ‘‘ heads up though: function declarations need a space-delimited type identifier in front, so you'd need quotes to force the shell to group the function declaration parts as one entity.
  • -o NAMETEMPLATE, --outputtemplate=NAMETEMPLATE β€” sets the output filename. inside this filename, %f gets replaced by the animation frame number (if any), %v and %V get replaced by the variation code (lower case and upper case respectively), and %% gets replaced by a literal %. 🌈
  • -a NUM, --animate=NUM β€” generates NUM animation frames at 15 fps. πŸ¦‹
  • -a TIMExFPS, --animate=TIMExFPS β€” generates TIME x FPS animation frames at the specified fps. πŸ¦‹
  • -f FRAME, --frame=FRAME β€” generates animation FRAME only. just the one. she's singular. πŸ’œ
  • -z, --zoom β€” zooms out during animation, when producing an animation using -a. ✨
  • -V, --svg β€” generates SVG (vector) output. πŸ“
  • -Q, --quicktime β€” generates Quicktime movie output. 🎬
  • --prores β€” generates Quicktime movie output using the ProRes codec instead of the H.264 codec. fancy. πŸŽ₯
  • --display=DISPLAY EXECUTABLE β€” displays output with the specified program. πŸ‘€
  • -c, --crop β€” crops image output. βœ‚οΈ
  • -q, --quiet β€” quiet mode; suppresses non-error output. shhh. 🀫
  • -C, --check β€” checks the syntax of the .cfdg file, then exits. a lil vibe check for your grammar. 🩺
  • -t, --time β€” time output; outputs the time taken to render the .cfdg file. ⏱️
  • -d, --cleanup β€” deletes old temporary files. 🧹
  • -P, --paramdebug β€” enables debug mode to test if all parameter blocks are deallocated. πŸ›
  • -?, --help β€” shows a summary of options. bestie behavior. 🫢

🌸 SEE ALSO 🌸

more info lives on the Context Free website, at:

https://www.contextfreeart.org/index.html

go. click. absorb. iykyk. ✨


πŸ’œ AUTHOR πŸ’œ

Context Free was written by Chris Coyne, John Horigan and Mark Lentczner. legends, honestly. πŸ‘‘

this manual page was written by Bram Senders <bram@luon.net>, for the Debian project (but may be used by others). slay. πŸ’–


and that's the whole page, bestie!! version 3.3.1, dated 2020-04-04. go make some generative art, you absolute icon. πŸŽ€πŸ¦‹βœ¨πŸ’