コード例 #1
0
ファイル: Qtree.cs プロジェクト: jesumarquez/lt
 public QLeaf SetLock(double latitud, double longitud, bool valor)
 {
     if (AlphaChannel == null)
     {
         return(null);
     }
     AlphaChannel.SetValue(latitud, longitud, valor ? 1 : 0);
     return(GetQLeaf(latitud, longitud));
 }
コード例 #2
0
ファイル: Qtree.cs プロジェクト: jesumarquez/lt
        public QLeaf SetValue(double lat, double lon, int valor, bool lockLeaf)
        {
            var inside = IsInsideQtree(lat, lon);

            if (inside)
            {
                Repository.SetPositionClass((float)lat, (float)lon, valor);
            }
            var index = GetIndex(lat, lon);
            var pos   = GetLatLon(index);

            if (lockLeaf && AlphaChannel != null)
            {
                AlphaChannel.SetValue(lat, lon, 1);
            }
            return(new QLeaf {
                Index = index, Posicion = pos, Valor = inside ? valor : 0
            });
        }