This file is indexed.

/usr/include/osgEarthAnnotation/LocalizedNode is in libosgearth-dev 2.4.0+dfsg-6.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
/* -*-c++-*- */
/* osgEarth - Dynamic map generation toolkit for OpenSceneGraph
* Copyright 2008-2013 Pelican Mapping
* http://osgearth.org
*
* osgEarth is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program.  If not, see <http://www.gnu.org/licenses/>
*/
#ifndef OSGEARTH_ANNO_LOCALIZED_NODE_H
#define OSGEARTH_ANNO_LOCALIZED_NODE_H 1

#include <osgEarthAnnotation/AnnotationNode>
#include <osgEarth/OverlayNode>
#include <osgEarth/GeoData>
#include <osg/MatrixTransform>

namespace osgEarth { namespace Annotation
{	
    using namespace osgEarth;

    /**
     * Base class for node that is localized at a specific geographic point.
     *
     * Don't use this class *directly*. If you are trying to add your own 
     * osg::Node as an Annotation, use the LocalizedGeometryNode instead.
     */
    class OSGEARTHANNO_EXPORT LocalizedNode : public PositionedAnnotationNode
    {
    public:
        META_AnnotationNodeAbstract(osgEarthAnnotation, LocalizedNode);

        /**
         * Constructs a new LocalizedNode.
         * @param mapSRS  Spatial reference for position info
         * @param pos     Initial position of the node (map coords)
         */
        LocalizedNode( 
            MapNode*          mapNode,
            const GeoPoint&   pos      =GeoPoint::INVALID );

        LocalizedNode(
            MapNode*          mapNode,
            const Config&     conf );


    public: // PositionedAnnotationNode

        /** Sets the node position */
        virtual bool setPosition( const GeoPoint& p );

        /** Gets the node position (in map coords) */
        virtual GeoPoint getPosition() const;


    public: // MapNodeObserver

        virtual void setMapNode( MapNode* mapNode );

    public:
        /**
         * Sets a "local offset" position - for an ECEF map, this is an offset in 
         * the local tangent plane of the node that is applied to the geometry.
         */
        void setLocalOffset( const osg::Vec3d& offset );

        /**
         * Gets the local tangent plane -space offset.
         */
        const osg::Vec3d& getLocalOffset() const;

        /**
         * Sets a local rotation - a rotation relative to the local tangent plane
         * of the geometry.
         */
        void setLocalRotation( const osg::Quat& rotation );

        /**
         * Gets the local tangent plane -space rotation.
         */
        const osg::Quat& getLocalRotation() const;

        /**
         * Local scale factor.
         */
        void setScale( const osg::Vec3f& scale );
        const osg::Vec3f& getScale() const { return _scale; }

        /**
         * Enables or disable automatic horizon culling
         */
        void setHorizonCulling( bool value );
        bool getHorizonCulling() const;


    public: // osg::Node

        virtual osg::BoundingSphere computeBound() const;


    protected:

        /**
         * The matrix transform that controls this node's position
         */
        virtual osg::MatrixTransform* getTransform() =0;


    protected:
        bool                               _initComplete;
        bool                               _horizonCulling;
        GeoPoint                           _mapPosition;
        osg::Vec3f                         _scale;
        osg::Vec3d                         _localOffset;
        osg::Quat                          _localRotation;
        osg::ref_ptr<osg::NodeCallback>    _cullByHorizonCB;

        friend class Decoration;
        
        // re-clamped the vert mesh based on a new terrain tile coming in
        virtual void reclamp( const TileKey& key, osg::Node* tile, const Terrain* terrain );

        // refreshed the main transform with data from an asbolute point
        bool updateTransform(const GeoPoint& absPt, osg::Node* patch =0L);

        // checks for overlay requirements, and if needed, installs a decorator node above
        // the passed-in node to facilitate the clamping/draping. The proper usage pattern
        // is:  node = applyAltitudePolicy(node, style)
        osg::Node* applyAltitudePolicy( osg::Node* node, const Style& style );

        // hidden copy constructor
        LocalizedNode() { }
        LocalizedNode(const LocalizedNode& rhs, const osg::CopyOp& op=osg::CopyOp::DEEP_COPY_ALL) { }
        virtual ~LocalizedNode() { }


    private:

        void init();
    };

} } // namespace osgEarth::Annotation

#endif // OSGEARTH_ANNO_LOCALIZED_NODE_H