osgEarth 2.1.1
Public Member Functions

KML_Feature Struct Reference

Inheritance diagram for KML_Feature:
Collaboration diagram for KML_Feature:

List of all members.

Public Member Functions

virtual void scan (const Config &conf, KMLContext &cx)
virtual void scan2 (const Config &conf, KMLContext &cx)
virtual void build (const Config &conf, KMLContext &cx, osg::Node *working)

Detailed Description

Definition at line 26 of file KML_Feature.


Member Function Documentation

void KML_Feature::build ( const Config conf,
KMLContext cx,
osg::Node *  working 
) [virtual]

Reimplemented from KML_Object.

Reimplemented in KML_Container, and KML_Overlay.

Definition at line 40 of file KML_Feature.cpp.

{
    KML_Object::build(conf, cx, working);

    // subclass feature is built; now add feature level data if available
    if ( working )
    {
        // parse the visibility to show/hide the item by default:
        if ( conf.hasValue("visibility") )
            working->setNodeMask( conf.value<bool>("visibility",true) == true ? ~0 : 0 );

        // parse a "LookAt" element (stores a viewpoint)
        AnnotationData* anno = getOrCreateAnnotationData(working);
        
        anno->setName( conf.value("name") );
        anno->setDescription( conf.value("description") );

        const Config& lookat = conf.child("lookat");
        if ( !lookat.empty() )
        {
            Viewpoint vp(
                lookat.value<double>("longitude", 0.0),
                lookat.value<double>("latitude", 0.0),
                lookat.value<double>("altitude", 0.0),
                lookat.value<double>("heading", 0.0),
                -lookat.value<double>("tilt", 45.0),
                lookat.value<double>("range", 10000.0) );

            anno->setViewpoint( vp );
        }
    }
}

Here is the call graph for this function:

Here is the caller graph for this function:

void KML_Feature::scan ( const Config conf,
KMLContext cx 
) [virtual]

Reimplemented from KML_Object.

Reimplemented in KML_Container, KML_Document, KML_Folder, KML_GroundOverlay, KML_Overlay, KML_PhotoOverlay, and KML_ScreenOverlay.

Definition at line 26 of file KML_Feature.cpp.

{
    KML_Object::scan(conf, cx);
    for_many( Style, scan, conf, cx );
}

Here is the call graph for this function:

Here is the caller graph for this function:

void KML_Feature::scan2 ( const Config conf,
KMLContext cx 
) [virtual]

Reimplemented from KML_Object.

Reimplemented in KML_Container, KML_Document, and KML_Folder.

Definition at line 33 of file KML_Feature.cpp.

{
    KML_Object::scan2(conf, cx);
    for_many( Style, scan2, conf, cx );
}

Here is the call graph for this function:

Here is the caller graph for this function:


The documentation for this struct was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines