usbdmx.com Home of the opto isolated, bus powered, DMX512 interface with both in and out universes. Cheap and simple to build. USBDMX logo

LOFixtureAttribute Class Reference

A fixture can have many different atttributes assocauted with it, such as intensity, or gobo. More...

#import <LOFixtureAttribute.h>

Inheritance diagram for LOFixtureAttribute:

LOPaletteFixtureAttribute LOProportionalFixtureAttribute LOColorMixFixtureAttribute LOMovementFixtureAttribute

Public Member Functions

(id) - initWithName:andType:
 Initilise the object with a name and a type.
(id) - initWithXML:withinFixture:
 Initilise the attribute from an XML definition.
(NSXMLElement *) - XML
 Get the defintion of this attribute an an XML element.
(NSString *) - name
 Get the attribute name.
(void) - setName:
 Set the attribute name.
(LOFixtureAttributeType) - type
 Get the attribute type.
(LOFixtureAttributeIndex) - fixtureAttributeIndex
 Get the fixture attribute index of this attribute with the fixture.
(void) - setFixtureAttributeIndex:
 Set the fixture attribute index of this attribute with the fixture.
(void) - setFixture:
 Set the fixture that this attribute is a part of.
(void) - setDepends:
 An attribute can have a dependancy on a specific range.
(BOOL) - updateOutputWithObject:
 Update the attribute output with data from an object, this could be a simple NSNumber, or for a colour mix attribute it may be an NSColor object.
(BOOL) - updateOutputToValue:
 Update the attribute output with a specific value.

Static Public Member Functions

(id) + attributeFromXML:withinFixture:
 Get the attribute object from an XML element.

Protected Attributes

NSString * name
LOFixtureAttributeType type
LOFixtureAttributeIndex fixtureAttributeIndex
LOFixturefixture
 The fixture that this attribute belongs to.
LOFixtureRangedependantRange
 A dependancy for this attribute to work means a value in this range must be present.

Detailed Description

A fixture can have many different atttributes assocauted with it, such as intensity, or gobo.

In its simplest form an Attribute is just a value set on one or more channels.

This should be though of as an abstract class as its not really any use by itsself, you should always use one of its children.


Member Function Documentation

+ (id) attributeFromXML: (NSXMLElement *)  XMLElement
withinFixture: (LOFixture *)  theFixture 

Get the attribute object from an XML element.

- (LOFixtureAttributeIndex) fixtureAttributeIndex  

Get the fixture attribute index of this attribute with the fixture.

Returns:
The index or LOFixtureAttributeIndexUnknown if not set
See also:
- setFixtureAttributeIndex:

- (id) initWithXML: (NSXMLElement *)  XMLElement
withinFixture: (LOFixture *)  theFixture 

Initilise the attribute from an XML definition.

- (NSString *) name  

Get the attribute name.

See also:
- setName:

- initWithName:andType:

- (void) setDepends: (LOFixtureRange *)  theDependantRange  

An attribute can have a dependancy on a specific range.

This might for instance be that gobo rotation will only work when a gobo control attribute is set to a specific range of values.

- (void) setFixture: (LOFixture *)  aFixture  

Set the fixture that this attribute is a part of.

- (void) setFixtureAttributeIndex: (LOFixtureAttributeIndex)  anIndex  

Set the fixture attribute index of this attribute with the fixture.

Parameters:
anIndex The fixture attribute index
See also:
fixtureAttributeIndex

- (void) setName: (NSString *)  aName  

Set the attribute name.

See also:
name:

- (LOFixtureAttributeType) type  

Get the attribute type.

See also:
- initWithName:andType:

- (BOOL) updateOutputToValue: (unsigned)  theValue  

Update the attribute output with a specific value.

This has the same effect as updating the output with an object of NSNumber containing an int

Parameters:
theValue The value to update with
See also:
- updateOutputWithObject:

Reimplemented in LOColorMixFixtureAttribute.

- (BOOL) updateOutputWithObject: (id)  anObject  

Update the attribute output with data from an object, this could be a simple NSNumber, or for a colour mix attribute it may be an NSColor object.

The object will be spcific to the attribute, and the incorrect object will result in no update.

Reimplemented in LOColorMixFixtureAttribute, and LOProportionalFixtureAttribute.

- (NSXMLElement *) XML  

Get the defintion of this attribute an an XML element.


The documentation for this class was generated from the following files: