예제 #1
0
        /// <summary>
        ///   Initializes a new instance of the <see cref="ScaleInvariantFeatureTranformKeypointDescriptor"/> class.
        /// </summary>
        ///
        internal ScaleInvariantFeatureTranformKeypointDescriptor(UnmanagedImage image,
                                                                 IntegralImage integral, ScaleInvariantFeatureTranformKeypointPattern pattern)
        {
            this.Extended            = false;
            this.IsOrientationNormal = true;
            this.IsScaleNormal       = true;
            this.Image    = image;
            this.Integral = integral;

            this._pattern = pattern;
        }
        public ScaleInvariantFeatureTranformKeypointDescriptor GetDescriptor()
        {
            if (_descriptor == null || _pattern == null)
            {
                if (_pattern == null)
                {
                    _pattern = new ScaleInvariantFeatureTranformKeypointPattern(_octaves, _scale);
                }

                _descriptor          = new ScaleInvariantFeatureTranformKeypointDescriptor(_grayImage, _integral, _pattern);
                _descriptor.Extended = _featureType == ScaleInvariantFeatureTranformKeypointDescriptorType.Extended;
            }

            return(_descriptor);
        }