Documentation ¶
Index ¶
- func Interpret(program parser.Program, bitmap BitmapContext) error
- func PrintFunctions() string
- type BitmapContext
- type Boolean
- func (b Boolean) Add(other Value) (Value, error)
- func (b Boolean) At(bitmap BitmapContext) (Value, error)
- func (b Boolean) Compare(other Value) (Value, error)
- func (b Boolean) Concat(val Value) (Value, error)
- func (b Boolean) Div(other Value) (Value, error)
- func (b Boolean) In(other Value) (Value, error)
- func (b Boolean) Index(index Value) (Value, error)
- func (b Boolean) IndexAssign(index Value, val Value) error
- func (b Boolean) IndexRange(lower, upper Value) (Value, error)
- func (b Boolean) Iterate(visit func(Value) error) error
- func (b Boolean) Mod(other Value) (Value, error)
- func (b Boolean) Mul(other Value) (Value, error)
- func (b Boolean) Neg() (Value, error)
- func (b Boolean) Not() (Value, error)
- func (b Boolean) PrintStr() string
- func (b Boolean) Property(ident string) (Value, error)
- func (b Boolean) RuntimeTypeName() string
- func (b Boolean) Sub(other Value) (Value, error)
- type Circle
- func (c Circle) Add(other Value) (Value, error)
- func (c Circle) At(bitmap BitmapContext) (Value, error)
- func (c Circle) Compare(other Value) (Value, error)
- func (c Circle) Concat(val Value) (Value, error)
- func (c Circle) Div(other Value) (Value, error)
- func (c Circle) In(other Value) (Value, error)
- func (c Circle) Index(index Value) (Value, error)
- func (c Circle) IndexAssign(index Value, val Value) error
- func (c Circle) IndexRange(lower, upper Value) (Value, error)
- func (c Circle) Iterate(visit func(Value) error) error
- func (c Circle) Mod(other Value) (Value, error)
- func (c Circle) Mul(other Value) (Value, error)
- func (c Circle) Neg() (Value, error)
- func (c Circle) Not() (Value, error)
- func (c Circle) PrintStr() string
- func (c Circle) Property(ident string) (Value, error)
- func (c Circle) RuntimeTypeName() string
- func (c Circle) Sub(other Value) (Value, error)
- type Color
- func (c Color) Add(other Value) (Value, error)
- func (c Color) At(bitmap BitmapContext) (Value, error)
- func (c Color) Compare(other Value) (Value, error)
- func (c Color) Concat(val Value) (Value, error)
- func (c Color) Div(other Value) (Value, error)
- func (c Color) In(other Value) (Value, error)
- func (c Color) Index(index Value) (Value, error)
- func (c Color) IndexAssign(index Value, val Value) error
- func (c Color) IndexRange(lower, upper Value) (Value, error)
- func (c Color) Iterate(visit func(Value) error) error
- func (c Color) Mod(other Value) (Value, error)
- func (c Color) Mul(other Value) (Value, error)
- func (c Color) Neg() (Value, error)
- func (c Color) Not() (Value, error)
- func (c Color) PrintStr() string
- func (c Color) Property(ident string) (Value, error)
- func (c Color) RuntimeTypeName() string
- func (c Color) Sub(other Value) (Value, error)
- type ColorHsv
- func (hsv ColorHsv) Add(other Value) (Value, error)
- func (hsv ColorHsv) At(bitmap BitmapContext) (Value, error)
- func (hsv ColorHsv) Compare(other Value) (Value, error)
- func (hsv ColorHsv) Concat(val Value) (Value, error)
- func (hsv ColorHsv) Div(other Value) (Value, error)
- func (hsv ColorHsv) In(other Value) (Value, error)
- func (hsv ColorHsv) Index(index Value) (Value, error)
- func (hsv ColorHsv) IndexAssign(index Value, val Value) error
- func (hsv ColorHsv) IndexRange(lower, upper Value) (Value, error)
- func (hsv ColorHsv) Iterate(visit func(Value) error) error
- func (hsv ColorHsv) Mod(other Value) (Value, error)
- func (hsv ColorHsv) Mul(other Value) (Value, error)
- func (hsv ColorHsv) Neg() (Value, error)
- func (hsv ColorHsv) Not() (Value, error)
- func (hsv ColorHsv) PrintStr() string
- func (hsv ColorHsv) Property(ident string) (Value, error)
- func (hsv ColorHsv) RuntimeTypeName() string
- func (hsv ColorHsv) Sub(other Value) (Value, error)
- type Function
- func (f Function) Add(other Value) (Value, error)
- func (f Function) At(bitmap BitmapContext) (Value, error)
- func (f Function) Compare(other Value) (Value, error)
- func (f Function) Concat(val Value) (Value, error)
- func (f Function) Div(other Value) (Value, error)
- func (f Function) In(other Value) (Value, error)
- func (f Function) Index(index Value) (Value, error)
- func (f Function) IndexAssign(index Value, val Value) error
- func (f Function) IndexRange(lower, upper Value) (Value, error)
- func (f Function) Iterate(visit func(Value) error) error
- func (f Function) Mod(other Value) (Value, error)
- func (f Function) Mul(other Value) (Value, error)
- func (f Function) Neg() (Value, error)
- func (f Function) Not() (Value, error)
- func (f Function) PrintStr() string
- func (f Function) Property(ident string) (Value, error)
- func (f Function) RuntimeTypeName() string
- func (f Function) Sub(other Value) (Value, error)
- type FunctionDecl
- type HashMap
- func (h HashMap) Add(other Value) (Value, error)
- func (h HashMap) At(bitmap BitmapContext) (Value, error)
- func (h HashMap) Compare(other Value) (Value, error)
- func (h HashMap) Concat(val Value) (Value, error)
- func (h HashMap) Div(other Value) (Value, error)
- func (h HashMap) In(other Value) (Value, error)
- func (h HashMap) Index(index Value) (Value, error)
- func (h HashMap) IndexAssign(index Value, val Value) error
- func (h HashMap) IndexRange(lower, upper Value) (Value, error)
- func (h HashMap) Iterate(visit func(Value) error) error
- func (h HashMap) Mod(other Value) (Value, error)
- func (h HashMap) Mul(other Value) (Value, error)
- func (h HashMap) Neg() (Value, error)
- func (h HashMap) Not() (Value, error)
- func (h HashMap) PrintStr() string
- func (h HashMap) Property(ident string) (Value, error)
- func (h HashMap) RuntimeTypeName() string
- func (h HashMap) Sub(other Value) (Value, error)
- type Kernel
- func (k Kernel) Add(other Value) (Value, error)
- func (k Kernel) At(bitmap BitmapContext) (Value, error)
- func (k Kernel) Compare(other Value) (Value, error)
- func (k Kernel) Concat(val Value) (Value, error)
- func (k Kernel) Div(other Value) (Value, error)
- func (k Kernel) In(other Value) (Value, error)
- func (k Kernel) Index(index Value) (Value, error)
- func (k Kernel) IndexAssign(index Value, val Value) error
- func (k Kernel) IndexRange(lower, upper Value) (Value, error)
- func (k Kernel) Iterate(visit func(Value) error) error
- func (k Kernel) Mod(other Value) (Value, error)
- func (k Kernel) Mul(other Value) (Value, error)
- func (k Kernel) Neg() (Value, error)
- func (k Kernel) Not() (Value, error)
- func (k Kernel) PrintStr() string
- func (k Kernel) Property(ident string) (Value, error)
- func (k Kernel) RuntimeTypeName() string
- func (k Kernel) Sub(other Value) (Value, error)
- type Line
- func (l Line) Add(other Value) (Value, error)
- func (l Line) At(bitmap BitmapContext) (Value, error)
- func (l Line) Compare(other Value) (Value, error)
- func (l Line) Concat(val Value) (Value, error)
- func (l Line) Div(other Value) (Value, error)
- func (l Line) In(other Value) (Value, error)
- func (l Line) Index(index Value) (Value, error)
- func (l Line) IndexAssign(index Value, val Value) error
- func (l Line) IndexRange(lower, upper Value) (Value, error)
- func (l Line) Iterate(visit func(Value) error) error
- func (l Line) Mod(other Value) (Value, error)
- func (l Line) Mul(other Value) (Value, error)
- func (l Line) Neg() (Value, error)
- func (l Line) Not() (Value, error)
- func (l Line) PrintStr() string
- func (l Line) Property(ident string) (Value, error)
- func (l Line) RuntimeTypeName() string
- func (l Line) Sub(other Value) (Value, error)
- type List
- func (l List) Add(other Value) (Value, error)
- func (l List) At(bitmap BitmapContext) (Value, error)
- func (l List) Compare(other Value) (Value, error)
- func (l List) Concat(val Value) (Value, error)
- func (l List) Div(other Value) (Value, error)
- func (l List) In(other Value) (Value, error)
- func (l List) Index(index Value) (Value, error)
- func (l List) IndexAssign(index Value, val Value) error
- func (l List) IndexRange(lower, upper Value) (Value, error)
- func (l List) Iterate(visit func(Value) error) error
- func (l List) Mod(other Value) (Value, error)
- func (l List) Mul(other Value) (Value, error)
- func (l List) Neg() (Value, error)
- func (l List) Not() (Value, error)
- func (l List) PrintStr() string
- func (l List) Property(ident string) (Value, error)
- func (l List) RuntimeTypeName() string
- func (l List) Sub(other Value) (Value, error)
- type Nilval
- func (n Nilval) Add(other Value) (Value, error)
- func (n Nilval) At(bitmap BitmapContext) (Value, error)
- func (n Nilval) Compare(other Value) (Value, error)
- func (n Nilval) Concat(val Value) (Value, error)
- func (n Nilval) Div(other Value) (Value, error)
- func (n Nilval) In(other Value) (Value, error)
- func (n Nilval) Index(index Value) (Value, error)
- func (n Nilval) IndexAssign(index Value, val Value) error
- func (n Nilval) IndexRange(lower, upper Value) (Value, error)
- func (n Nilval) Iterate(visit func(Value) error) error
- func (n Nilval) Mod(other Value) (Value, error)
- func (n Nilval) Mul(other Value) (Value, error)
- func (n Nilval) Neg() (Value, error)
- func (n Nilval) Not() (Value, error)
- func (n Nilval) PrintStr() string
- func (n Nilval) Property(ident string) (Value, error)
- func (n Nilval) RuntimeTypeName() string
- func (n Nilval) Sub(other Value) (Value, error)
- type Number
- func (n Number) Add(other Value) (Value, error)
- func (n Number) At(bitmap BitmapContext) (Value, error)
- func (n Number) Compare(other Value) (Value, error)
- func (n Number) Concat(val Value) (Value, error)
- func (n Number) Div(other Value) (Value, error)
- func (n Number) In(other Value) (Value, error)
- func (n Number) Index(index Value) (Value, error)
- func (n Number) IndexAssign(index Value, val Value) error
- func (n Number) IndexRange(lower, upper Value) (Value, error)
- func (n Number) Iterate(visit func(Value) error) error
- func (n Number) Mod(other Value) (Value, error)
- func (n Number) Mul(other Value) (Value, error)
- func (n Number) Neg() (Value, error)
- func (n Number) Not() (Value, error)
- func (n Number) PrintStr() string
- func (n Number) Property(ident string) (Value, error)
- func (n Number) RuntimeTypeName() string
- func (n Number) Sub(other Value) (Value, error)
- type Point
- func (p Point) Add(other Value) (Value, error)
- func (p Point) At(bitmap BitmapContext) (Value, error)
- func (p Point) Compare(other Value) (Value, error)
- func (p Point) Concat(val Value) (Value, error)
- func (p Point) Div(other Value) (Value, error)
- func (p Point) In(other Value) (Value, error)
- func (p Point) Index(index Value) (Value, error)
- func (p Point) IndexAssign(index Value, val Value) error
- func (p Point) IndexRange(lower, upper Value) (Value, error)
- func (p Point) Iterate(visit func(Value) error) error
- func (p Point) Mod(other Value) (Value, error)
- func (p Point) Mul(other Value) (Value, error)
- func (p Point) Neg() (Value, error)
- func (p Point) Not() (Value, error)
- func (p Point) PrintStr() string
- func (p Point) Property(ident string) (Value, error)
- func (p Point) RuntimeTypeName() string
- func (p Point) Sub(other Value) (Value, error)
- type Polygon
- func (p Polygon) Add(other Value) (Value, error)
- func (p Polygon) At(bitmap BitmapContext) (Value, error)
- func (p Polygon) Compare(other Value) (Value, error)
- func (p Polygon) Concat(val Value) (Value, error)
- func (p Polygon) Div(other Value) (Value, error)
- func (p Polygon) In(other Value) (Value, error)
- func (p Polygon) Index(index Value) (Value, error)
- func (p Polygon) IndexAssign(index Value, val Value) error
- func (p Polygon) IndexRange(lower, upper Value) (Value, error)
- func (p Polygon) Iterate(visit func(Value) error) error
- func (p Polygon) Mod(other Value) (Value, error)
- func (p Polygon) Mul(other Value) (Value, error)
- func (p Polygon) Neg() (Value, error)
- func (p Polygon) Not() (Value, error)
- func (p Polygon) PrintStr() string
- func (p Polygon) Property(ident string) (Value, error)
- func (p Polygon) RuntimeTypeName() string
- func (p Polygon) Sub(other Value) (Value, error)
- type Rect
- func (rc Rect) Add(other Value) (Value, error)
- func (rc Rect) At(bitmap BitmapContext) (Value, error)
- func (rc Rect) Compare(other Value) (Value, error)
- func (rc Rect) Concat(val Value) (Value, error)
- func (rc Rect) Div(other Value) (Value, error)
- func (rc Rect) In(other Value) (Value, error)
- func (rc Rect) Index(index Value) (Value, error)
- func (rc Rect) IndexAssign(index Value, val Value) error
- func (rc Rect) IndexRange(lower, upper Value) (Value, error)
- func (rc Rect) Iterate(visit func(Value) error) error
- func (rc Rect) Mod(other Value) (Value, error)
- func (rc Rect) Mul(other Value) (Value, error)
- func (rc Rect) Neg() (Value, error)
- func (rc Rect) Not() (Value, error)
- func (rc Rect) PrintStr() string
- func (rc Rect) Property(ident string) (Value, error)
- func (rc Rect) RuntimeTypeName() string
- func (rc Rect) Sub(other Value) (Value, error)
- type Str
- func (s Str) Add(other Value) (Value, error)
- func (s Str) At(bitmap BitmapContext) (Value, error)
- func (s Str) Compare(other Value) (Value, error)
- func (s Str) Concat(val Value) (Value, error)
- func (s Str) Div(other Value) (Value, error)
- func (s Str) In(other Value) (Value, error)
- func (s Str) Index(index Value) (Value, error)
- func (s Str) IndexAssign(index Value, val Value) error
- func (s Str) IndexRange(lower, upper Value) (Value, error)
- func (s Str) Iterate(visit func(Value) error) error
- func (s Str) Mod(other Value) (Value, error)
- func (s Str) Mul(other Value) (Value, error)
- func (s Str) Neg() (Value, error)
- func (s Str) Not() (Value, error)
- func (s Str) PrintStr() string
- func (s Str) Property(ident string) (Value, error)
- func (s Str) RuntimeTypeName() string
- func (s Str) Sub(other Value) (Value, error)
- type Value
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PrintFunctions ¶
func PrintFunctions() string
Types ¶
type BitmapContext ¶
type BitmapContext interface { GetPixel(x int, y int) lang.Color SetPixel(x int, y int, color lang.Color) SourceWidth() int SourceHeight() int TargetWidth() int TargetHeight() int Convolute(x, y, width, height int, kernel []lang.Number) lang.Color MapRed(x, y, width, height int, kernel []lang.Number) []lang.Number MapGreen(x, y, width, height int, kernel []lang.Number) []lang.Number MapBlue(x, y, width, height int, kernel []lang.Number) []lang.Number MapAlpha(x, y, width, height int, kernel []lang.Number) []lang.Number Blt(x, y, width, height int) ResizeTarget(width, height int) Flip() int // return imageID for Recall() Recall(imageID int) error SetClipRect(rect image.Rectangle) ClipRect() image.Rectangle Log(message string) InterpolatePixel(x float32, y float32) *lang.Color }
BitmapContext is the surface the ylang interpreter works on.
type Boolean ¶
func (Boolean) RuntimeTypeName ¶
type Circle ¶
func (Circle) RuntimeTypeName ¶
type Color ¶
func (Color) RuntimeTypeName ¶
type ColorHsv ¶
func (ColorHsv) RuntimeTypeName ¶
type Function ¶
type Function struct { ParameterNames []string Body []parser.Statement // contains filtered or unexported fields }
func (Function) RuntimeTypeName ¶
type FunctionDecl ¶
type FunctionDecl struct {
// contains filtered or unexported fields
}
type HashMap ¶
func (HashMap) RuntimeTypeName ¶
type Kernel ¶
func (Kernel) RuntimeTypeName ¶
type Line ¶
func (Line) RuntimeTypeName ¶
type Nilval ¶
func (Nilval) RuntimeTypeName ¶
type Number ¶
func (Number) RuntimeTypeName ¶
type Point ¶
func (Point) RuntimeTypeName ¶
type Rect ¶
func (Rect) RuntimeTypeName ¶
type Str ¶
func (Str) RuntimeTypeName ¶
type Value ¶
type Value interface { Compare(other Value) (Value, error) Add(other Value) (Value, error) Sub(other Value) (Value, error) Mul(other Value) (Value, error) Div(other Value) (Value, error) Mod(other Value) (Value, error) In(other Value) (Value, error) Neg() (Value, error) Not() (Value, error) At(bitmap BitmapContext) (Value, error) Property(ident string) (Value, error) PrintStr() string Iterate(visit func(Value) error) error Index(index Value) (Value, error) IndexRange(lower, upper Value) (Value, error) IndexAssign(index Value, val Value) error RuntimeTypeName() string Concat(val Value) (Value, error) }
Value represents a ylang value at runtime
Click to show internal directories.
Click to hide internal directories.