X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=include%2Fclass-reference.html;fp=include%2Fclass-reference.html;h=6d324b8cb7dc2dd6133ea8bf209ad8fa1dd2404e;hb=88d6f39b5f8b0f791b6833bb1512aa774b59d4f8;hp=a68ce82ae18e3938698fd0fd2b998d382ada5304;hpb=06f5e6d354e5859de8bb37a57e2d71d956c1086c;p=ardour-manual diff --git a/include/class-reference.html b/include/class-reference.html index a68ce82..6d324b8 100644 --- a/include/class-reference.html +++ b/include/class-reference.html @@ -32,10 +32,10 @@ Operations are performed on objects. One gets a reference to an object and then e.g obj = Session:route_by_name("Audio") obj:set_name("Guitar").

-Lua automatically follows C++ class inheritance. e.g one can directly call all SessionObject and Route methods on Track object. However lua does not automatically promote objects. A Route object which just happens to be a Track needs to be explicily cast to a Track. Methods for casts are provided with each class. Note that the cast may fail and return a nil reference. +Lua automatically follows C++ class inheritance. e.g one can directly call all SessionObject and Route methods on Track object. However lua does not automatically promote objects. A Route object which just happens to be a Track needs to be explicitly cast to a Track. Methods for casts are provided with each class. Note that the cast may fail and return a nil reference.

-Likewise multiple inheritance is a non-trivial issue in lua. To avoid performance penalties involved with lookups, explicit casts are required in this case. One example is ARDOUR:SessionObject which is-a StatefulDestructible which inhertis from both Stateful and Destructible. +Likewise multiple inheritance is a non-trivial issue in lua. To avoid performance penalties involved with lookups, explicit casts are required in this case. One example is ARDOUR:SessionObject which is-a StatefulDestructible which inherits from both Stateful and Destructible.

Object lifetimes are managed by the Session. Most Objects cannot be directly created, but one asks the Session to create or destroy them. This is mainly due to realtime constrains: @@ -95,7 +95,7 @@ print (rv, ref[1], ref[2])

Pointer Classes

Libardour makes extensive use of reference counted boost::shared_ptr to manage lifetimes. -The Lua bindings provide a complete abstration of this. There are no pointers in lua. +The Lua bindings provide a complete abstraction of this. There are no pointers in lua. For example a ARDOUR:Route is a pointer in C++, but lua functions operate on it like it was a class instance.

@@ -115,7 +115,7 @@ This is not unlike a = nil a:test() which results in en error "

From the lua side of things there is no distinction between weak and shared pointers. They behave identically. -Below they're inidicated in orange and have an arrow to indicate the pointer type. +Below they're indicated in orange and have an arrow to indicate the pointer type. Pointer Classes cannot be created in lua scripts. It always requires a call to C++ to create the Object and obtain a reference to it.

@@ -568,7 +568,7 @@ Pointer Classes cannot be created in lua scripts. It always requires a call to C

enable custom plugin-insert configuration

proc
Processor to customize
count
number of plugin instances to use (if zero, reset to default)
outs
output port customization
sinks
input pins for variable-I/O plugins

Returns true if successful

IOinput () Deliverymain_outs () -

the signal processorat at end of the processing chain which produces output

+

the signal processor at at end of the processing chain which produces output

boolmuted () ChanCountn_inputs () ChanCountn_outputs () @@ -580,12 +580,12 @@ Pointer Classes cannot be created in lua scripts. It always requires a call to C PeakMeterpeak_meter ()

************************************************************* Pure interface begins here*************************************************************

intremove_processor (Processor, ProcessorStreams, bool) -

remove plugin/processor

proc
processor to remove
err
error report (index where removal vailed, channel-count why it failed) may be nil
need_process_lock
if locking is required (set to true, unless called from RT context with lock)

Returns 0 on success

+

remove plugin/processor

proc
processor to remove
err
error report (index where removal failed, channel-count why it failed) may be nil
need_process_lock
if locking is required (set to true, unless called from RT context with lock)

Returns 0 on success

intremove_processors (ProcessorList, ProcessorStreams) boolremove_sidechain (Processor) intreorder_processors (ProcessorList, ProcessorStreams) intreplace_processor (Processor, Processor, ProcessorStreams) -

replace plugin/processor with another

old
processor to remove
sub
processor to substitute the old one with
err
error report (index where removal vailed, channel-count why it failed) may be nil

Returns 0 on success

+

replace plugin/processor with another

old
processor to remove
sub
processor to substitute the old one with
err
error report (index where removal failed, channel-count why it failed) may be nil

Returns 0 on success

boolreset_plugin_insert (Processor)

reset plugin-insert configuration to default, disable customizations.

This is equivalent to calling

 customize_plugin_insert (proc, 0, unused)
proc
Processor to reset

Returns true if successful

voidset_active (bool, void*) @@ -814,7 +814,7 @@ Pointer Classes cannot be created in lua scripts. It always requires a call to C

 ARDOUR:BufferSet

C‡: ARDOUR::BufferSet

-

A set of buffers of various types.

These are mainly accessed from Session and passed around as scratch buffers (eg as parameters to run() methods) to do in-place signal processing.

There are two types of counts associated with a BufferSet - available, and the 'use count'. Available is the actual number of allocated buffers (and so is the maximum acceptable value for the use counts).

The use counts are how things determine the form of their input and inform others the form of their output (eg what they did to the BufferSet). Setting the use counts is realtime safe.

+

A set of buffers of various types.

These are mainly accessed from Session and passed around as scratch buffers (e.g. as parameters to run() methods) to do in-place signal processing.

There are two types of counts associated with a BufferSet - available, and the 'use count'. Available is the actual number of allocated buffers (and so is the maximum acceptable value for the use counts).

The use counts are how things determine the form of their input and inform others the form of their output (e.g. what they did to the BufferSet). Setting the use counts is realtime safe.

@@ -1222,7 +1222,7 @@ Pointer Classes cannot be created in lua scripts. It always requires a call to C

C‡: boost::shared_ptr< ARDOUR::IO >, boost::weak_ptr< ARDOUR::IO >

is-a: ARDOUR:SessionObjectPtr

-

A collection of ports (all input or all output) with connections.

An IO can contain ports of varying types, making routes/inserts/etc with varied combinations of types (eg MIDI and audio) possible.

+

A collection of ports (all input or all output) with connections.

An IO can contain ports of varying types, making routes/inserts/etc with varied combinations of types (e.g. MIDI and audio) possible.

Methods
ChanCountcount ()
@@ -1567,7 +1567,7 @@ Pointer Classes cannot be created in lua scripts. It always requires a call to C - +
Methods
boolactive ()
voidresize (unsigned long)

Reallocate the buffer used internally to handle at least size_t units of data.

The buffer is not silent after this operation. the capacity argument passed to the constructor must have been non-zero.

voidsilence (long, long)

Clear (eg zero, or empty) buffer

Clear (e.g. zero, or empty) buffer

unsigned longsize ()
...table (--lua--)