Esempio n. 1
0
void ImageNode::registerType()
{
    TypeDefinition def = TypeDefinition("image", "rasternode", 
            ExportedObject::buildObject<ImageNode>)
        .addArg(Arg<UTF8String>("href", "", false, offsetof(ImageNode, m_href)))
        .addArg(Arg<string>("compression", "none"));
    TypeRegistry::get()->registerType(def);
}
Esempio n. 2
0
void SoundNode::registerType()
{
    TypeDefinition def = TypeDefinition("sound", "areanode", 
            ExportedObject::buildObject<SoundNode>)
        .addArg(Arg<UTF8String>("href", "", false, offsetof(SoundNode, m_href)))
        .addArg(Arg<bool>("loop", false, false, offsetof(SoundNode, m_bLoop)))
        .addArg(Arg<float>("volume", 1.0, false, offsetof(SoundNode, m_Volume)))
        ;
    TypeRegistry::get()->registerType(def);
}
Esempio n. 3
0
void VectorNode::registerType()
{
    TypeDefinition def = TypeDefinition("vectornode", "node")
        .addArg(Arg<string>("color", "FFFFFF", false, offsetof(VectorNode, m_sColorName)))
        .addArg(Arg<float>("strokewidth", 1, false, offsetof(VectorNode, m_StrokeWidth)))
        .addArg(Arg<UTF8String>("texhref", "", false, offsetof(VectorNode, m_TexHRef)))
        .addArg(Arg<string>("blendmode", "blend", false, 
                offsetof(VectorNode, m_sBlendMode)))
        ;
    TypeRegistry::get()->registerType(def);
}
Esempio n. 4
0
void CurveNode::registerType()
{
    TypeDefinition def = TypeDefinition("curve", "vectornode", 
            ExportedObject::buildObject<CurveNode>)
        .addArg(Arg<glm::vec2>("pos1", glm::vec2(0,0)))
        .addArg(Arg<glm::vec2>("pos2", glm::vec2(0,0)))
        .addArg(Arg<glm::vec2>("pos3", glm::vec2(0,0)))
        .addArg(Arg<glm::vec2>("pos4", glm::vec2(0,0)))
        .addArg(Arg<float>("texcoord1", 0, true, offsetof(CurveNode, m_TC1)))
        .addArg(Arg<float>("texcoord2", 1, true, offsetof(CurveNode, m_TC2)));
    TypeRegistry::get()->registerType(def);
}
Esempio n. 5
0
void PolyLineNode::registerType()
{
    vector<glm::vec2> v;
    vector<float> vd;
    TypeDefinition def = TypeDefinition("polyline", "vectornode", 
            ExportedObject::buildObject<PolyLineNode>)
        .addArg(Arg<string>("linejoin", "bevel"))
        .addArg(Arg<vector<glm::vec2> >("pos", v, false, offsetof(PolyLineNode, m_Pts)))
        .addArg(Arg<vector<float> >("texcoords", vd, false,
                offsetof(PolyLineNode, m_TexCoords)))
        ;
    TypeRegistry::get()->registerType(def);
}
Esempio n. 6
0
void DivNode::registerType()
{
    string sChildArray[] = {"image", "div", "canvas", "words", "video", "camera", 
            "panoimage", "sound", "line", "rect", "curve", "polyline", "polygon",
            "circle", "mesh"};
    vector<string> sChildren = vectorFromCArray(
            sizeof(sChildArray) / sizeof(*sChildArray), sChildArray);
    TypeDefinition def = TypeDefinition("div", "areanode", 
            ExportedObject::buildObject<DivNode>)
        .addChildren(sChildren)
        .addArg(Arg<bool>("crop", false, false, offsetof(DivNode, m_bCrop)))
        .addArg(Arg<UTF8String>("mediadir", "", false, offsetof(DivNode, m_sMediaDir)));
    TypeRegistry::get()->registerType(def);
}
Esempio n. 7
0
void AreaNode::registerType()
{
    TypeDefinition def = TypeDefinition("areanode", "node")
        .addArg(Arg<float>("x", 0.0, false, offsetof(AreaNode, m_RelViewport.tl.x)))
        .addArg(Arg<float>("y", 0.0, false, offsetof(AreaNode, m_RelViewport.tl.y)))
        .addArg(Arg<glm::vec2>("pos", glm::vec2(0.0, 0.0)))
        .addArg(Arg<float>("width", 0.0, false, offsetof(AreaNode, m_UserSize.x)))
        .addArg(Arg<float>("height", 0.0, false, offsetof(AreaNode, m_UserSize.y)))
        .addArg(Arg<glm::vec2>("size", glm::vec2(0.0, 0.0)))
        .addArg(Arg<float>("angle", 0.0, false, offsetof(AreaNode, m_Angle)))
        .addArg(Arg<glm::vec2>("pivot", glm::vec2(-32767, -32767), false, 
                offsetof(AreaNode, m_Pivot)))
        .addArg(Arg<string>("elementoutlinecolor", "", false, 
                offsetof(AreaNode, m_sElementOutlineColor)));
    TypeRegistry::get()->registerType(def);
}
Esempio n. 8
0
void FilledVectorNode::registerType()
{
    TypeDefinition def = TypeDefinition("filledvectornode", "vectornode")
        .addArg(Arg<UTF8String>("filltexhref", "", false, 
                offsetof(FilledVectorNode, m_FillTexHRef)))
        .addArg(Arg<float>("fillopacity", 0, false, 
                offsetof(FilledVectorNode, m_FillOpacity)))
        .addArg(Arg<UTF8String>("fillcolor", "FFFFFF", false, 
                offsetof(FilledVectorNode, m_sFillColorName)))
        .addArg(Arg<glm::vec2>("filltexcoord1", glm::vec2(0,0), false,
                offsetof(FilledVectorNode, m_FillTexCoord1)))
        .addArg(Arg<glm::vec2>("filltexcoord2", glm::vec2(1,1), false,
                offsetof(FilledVectorNode, m_FillTexCoord2)))
        ;
    TypeRegistry::get()->registerType(def);
}
Esempio n. 9
0
void FontStyle::registerType()
{
    TypeDefinition def = TypeDefinition("fontstyle", "",
            ExportedObject::buildObject<FontStyle>)
        .addArg(Arg<UTF8String>("font", "sans", false, offsetof(FontStyle, m_sName)))
        .addArg(Arg<UTF8String>("variant", "", false, offsetof(FontStyle, m_sVariant)))
        .addArg(Arg<Color>("color", Color("FFFFFF"), false,
                offsetof(FontStyle, m_Color)))
        .addArg(Arg<float>("aagamma", 1.0f, false, offsetof(FontStyle, m_AAGamma)))
        .addArg(Arg<float>("fontsize", 15, false, offsetof(FontStyle, m_Size)))
        .addArg(Arg<int>("indent", 0, false, offsetof(FontStyle, m_Indent)))
        .addArg(Arg<float>("linespacing", 0, false, offsetof(FontStyle, m_LineSpacing)))
        .addArg(Arg<UTF8String>("alignment", "left"))
        .addArg(Arg<UTF8String>("wrapmode", "word"))
        .addArg(Arg<bool>("justify", false, false, offsetof(FontStyle, m_bJustify)))
        .addArg(Arg<float>("letterspacing", 0, false,
                offsetof(FontStyle, m_LetterSpacing)))
        .addArg(Arg<bool>("hint", true, false, offsetof(FontStyle, m_bHint)))
        .addArg(Arg<FontStylePtr>("basestyle", FontStylePtr()))
        ;
    TypeRegistry::get()->registerType(def);
}
Esempio n. 10
0
void RasterNode::registerType()
{
    TypeDefinition def = TypeDefinition("rasternode", "areanode")
        .addArg(Arg<int>("maxtilewidth", -1, false, 
                offsetof(RasterNode, m_MaxTileSize.x)))
        .addArg(Arg<int>("maxtileheight", -1, false, 
                offsetof(RasterNode, m_MaxTileSize.y)))
        .addArg(Arg<string>("blendmode", "blend", false, 
                offsetof(RasterNode, m_sBlendMode)))
        .addArg(Arg<bool>("mipmap", false))
        .addArg(Arg<UTF8String>("maskhref", "", false, offsetof(RasterNode, m_sMaskHref)))
        .addArg(Arg<glm::vec2>("maskpos", glm::vec2(0,0), false,
                offsetof(RasterNode, m_MaskPos)))
        .addArg(Arg<glm::vec2>("masksize", glm::vec2(0,0), false,
                offsetof(RasterNode, m_MaskSize)))
        .addArg(Arg<glm::vec3>("gamma", glm::vec3(1.0f,1.0f,1.0f), false,
                offsetof(RasterNode, m_Gamma)))
        .addArg(Arg<glm::vec3>("contrast", glm::vec3(1.0f,1.0f,1.0f), false,
                offsetof(RasterNode, m_Contrast)))
        .addArg(Arg<glm::vec3>("intensity", glm::vec3(1.0f,1.0f,1.0f), false,
                offsetof(RasterNode, m_Intensity)));
    TypeRegistry::get()->registerType(def);
}
Esempio n. 11
0
void CanvasNode::registerType()
{
    TypeDefinition def = TypeDefinition("canvasbase", "div", 
            ExportedObject::buildObject<CanvasNode>);
    TypeRegistry::get()->registerType(def);
}
Esempio n. 12
0
void AVGNode::registerType()
{
    TypeDefinition def = TypeDefinition("avg", "canvasbase", 
            ExportedObject::buildObject<AVGNode>);
    TypeRegistry::get()->registerType(def);
}