The Documentation Hub

First, some frequently asked questions. Not a place to start, but a place to go if you are coming back to this page lost and confused.

Found something broken? Email field-development if you are not sure; file a bug report if you are more sure. Whatever you do, don't do nothing — that helps nobody.

Basic interface elements

The three most important plug-in windows in Field are these:

  • TextEditor — where you write code, usually in Python.
  • Canvas — where you create the elements that contain the code and can arrange these elements into a visual interface.
  • The Palette — where you access the functionality of Field's many plug-ins. Including the Plugin Manager where you can tell Field where your own classfiles and source live.

Even if you've been using Field for a while, you should keep an eye on:

Places to start

Field is many things to many people and emphasizes flexibility and openness over simplicity and compactness. Where to start? Well, it depends on where you are coming from and where you want to go:

"Show me the tutorials"

We just recently added a big page of tutorials — well documented field files that you can download and poke at. It goes from Hello World all the way through to complex graphics.

"I know Processing"

Know Processing? Great. Come on over. Field doesn't want to be another thing you learn, another library, another "empire". Field wants you to use your own code, and your own favorite libraries.

Some Processing/Field in action:

"I'm a programmer"

Some live coding in Field:

"I'm a Max/MSP artist"

  • The Max/MSP Plugin — If you are a Max/MSP user, you should definitely examine Field's Max support. This will let you embed live Python code in your Max patches.
  • The OSC Plugin — like so many outward-looking digital art tools, Field speaks the OSC Protocol.

"I want to draw, manipulate images and visualize data"

  • BasicDrawing — an introduction to the 2d drawing facilities inside Field, ideally suited for procedural visualizations and printmaking. (Don't miss the image manipulation extensions: CoreGraphicsExtensions.) For those coming over from Processing (and perhaps NodeBox) there's a walkthrough for 2d graphics and a list of observations about the differences between these environments. For those interested in 3d work in the canvas, read ThreeDFLines and Freehand 3d drawing (see the video at the bottom as well).
  • NodeBox looks interesting — it sure does. That's why we've been keeping an eye on a NodeBox/Field bridge.
  • BasicDrawingdescribes all the methods in Plines, the central class for 2d drawing in Field. This general discussion is augmented by two further pages: DrawingFLinesProperties, which talks about changing how Plines are rendered, and DrawingFLinesEditing, which describes how to manipulate the line geometry you've created. Some line drawing oriented tutorials: ColorMatchingTutorial describes building an idiosyncratic color-matching system in Field and a walkthrough for people coming from other environments. SnapToGrid includes information about how to make your own 'snap to' functionality inside Field. Finally, ThreeDFLines describes the extensions to the mainly 2d FLines system to let it draw in 3d. FLines can also be placed in the main renderer.

"I want to do some serious 3d graphics"

Key features

Field secretly thinks that all of the above topics actually come down to the same problem — how to write, edit, execute and manipulate code. So there's a lot of functionality that's common to all the kinds of things that might want to end up doing in Field.

  • VisualElementLifecycles — Since Field is all about running the code you are writing, it comes with a great many ways to run code — VisualElementLifecycles has the complete list, and TopologyAndControlFlow an example of what you can do with it.
  • Field tracks changes to your work — the .field 'file' is slightly more interesting than you'd expect.
  • Embedding GUI elements directly in code — one of the most obviously "cool" features of Field's TextEditor is that it allows GUI elements (sliders, color wells, point-pickers and buttons) to be embedded directly into otherwise textual code. Some widgets are beginning to get their own pages, starting with StatsBoxWidget. There are also many features that make Field very customizable to whatever it is you are working on right now — see AdHocUi.
  • Completion and Inspection — If you are interacting with a large Java codebase, you need some tricks to help you drill down into it. Field's autocomplete and inspection facilities have been made with this in mind.
  • Integration with other Apps — asked if Field could be used to talk to Maya, we responded (in fact anything you can talk to over telnet, OSC or AppleScript is fair game).
  • SwingIntegration — For rapidly making little interfaces, sometimes a little Swing is ideal.
  • TemplatingAndCopying — how to access what you've done before, and how to repeat yourself without getting bogged down.
  • Other languages — while the focus is very much on Python as our language of choice, we're not religious about it — we're working on Groovy, JavaScript and (on demand compiled) Java. We've been experimenting with mixing Scala and Python simultaneously as well.

Standard library

Examples of features that Field has made out of Python, to help the "improvising" code-writer and to encourage rapid, experimental programming:

  • GeneratorExamples — Python has a concept of a generator which turn out to be wonderfully useful for "animations" of all sorts. These are sophisticated ways of running code during animation cycles.
  • KeyframingInCode — with its line drawing and time sliders, Field is ideally placed to have a unique take on the common Keyframe. Don't miss SubTimeSliders as well, if you start creating complex sequences in the canvas.
  • LazyFunctionalHelpers — the beginnings of some documentation of some of the magic Python glue that helps the Field programmer along, and some hopefully inspiring examples of how far Python's object model can be manipulated.
  • SelfAndProperties — Advanced users of Field — people who are really crafting the environment to support their own practice — know all about Properties and what the _self variable does. They can use Field's internal delegation structure to customize how elements get painted, and how the interact with code and mouse alike. You can add custom menus items to code boxes. The can 'extend Field' from within Field itself — ExtendingFieldInField. They are also aware of the ImportantPlugins — and familiar with the properties that they export.
  • ScopingInField — Q: how does Python's module structure map onto Field's boxes? A: it doesn't!. Don't miss some important information about how Field responds to global variables.
  • SimpleLinearAlgebra — Making computer graphics always means dealing with a little bit of linear algebra. Field's Python bridged Vector library is easy to use.
  • Auto-run — how to 'finish' an artwork in Field, hide windows, make thing "go" automatically.
  • Recording what you do — Field's new recording plugin lets you build visual scripts out of what you do with code.
  • Want a command line? — Field's "Typing plugin" let's you bash out quick one-liners. Of course, because Field also lets you write code that these one liners reference, this can get pretty powerful.

Reference