Changeset 3259

Show
Ignore:
Timestamp:
06/04/08 14:50:34 (7 months ago)
Author:
ksprotte
Message:

adapted contract-tree to play well with sat-images with respect to lod and draw-order

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/bos-trunk-sat/projects/bos/web/contract-tree.lisp

    r3163 r3259  
    9898 
    9999;;; kml handler 
    100 (defmethod network-link-lod-min ((node contract-node)) 
    101   (if (zerop (depth node)) 
    102       16 
    103       512)) 
    104  
    105 (defmethod network-link-lod-max ((node contract-node)) 
    106   -1) 
    107  
    108100(defclass contract-tree-kml-handler (page-handler) 
    109101  () 
     
    138130        (setf (hunchentoot:header-out :last-modified) 
    139131              (hunchentoot:rfc-1123-date (timestamp node))) 
    140         (let* ((lod `(:min ,(network-link-lod-min node) :max ,(network-link-lod-max node))) 
     132        (let* ((lod (node-lod node)) 
    141133               (box (geo-box node)) 
    142134               (rect (geo-box-rectangle box)) 
     
    155147            (kml-overlay (format nil "http://~a/contract-tree-image?path=~{~d~}" (website-host) path) 
    156148                         rect 
    157                          :draw-order (+ 1000 (depth node)) 
     149                         :draw-order (compute-draw-order node (1- +max-num-of-local-draw-order-levels+)) 
    158150                         ;; :absolute 0 
    159151                         ;; GroundOverlay specific LOD 
    160                          :lod `(:min ,(network-link-lod-min node) 
    161                                      :max ,(if (node-has-children-p node) 
    162                                                (* 6 (network-link-lod-min (any-child node))) 
    163                                                -1))) 
     152                         :lod lod) 
    164153            ;; placemark-contracts 
    165154            (let ((placemark-contracts 
     
    202191                       (format nil "http://~A/contract-tree-kml?path=~{~D~}~D" (website-host) path i)) 
    203192                   :rect (geo-box-rectangle (geo-box child)) 
    204                    :lod `(:min ,(network-link-lod-min child) :max ,(network-link-lod-max child)))))))))))) 
     193                   :lod (node-lod child))))))))))) 
    205194 
    206195