Projet

Général

Profil

Révision ed5e83c5

Ajouté par Marc Souviron il y a plus de 10 ans

Amélioration du système de navigation assisté par OSM ou google
Correction d'un bug de non-linéarité sur les panoramas rebouclés (360°)
simplification du style

Voir les différences:

js/pano.js
122 122
	}
123 123
    }
124 124
    drawDecorations(ox, oy);
125
    var cap_ele = zm.get_cap_ele(last.x, last.y);
126
    angle_control.value = cap_ele.cap.toFixed(2);
127
    elvtn_control.value = cap_ele.ele.toFixed(2);
125 128
}
126 129

  
127 130
function draw_tile_del(ref, idx, tx, ty, ox, oy, twidth, theight) {
......
162 165
	}
163 166
    }
164 167

  
165
    //cntext.font = "20pt Arial";
166
    //cntext.fillRect(0, 0, 200, 20);
167
    //cntext.fillStyle = "rgb(255,0,0)";
168
    //cntext.fillText(od.toFixed(2), 5, 20);
169
    //for (i=0; i<canvas.width/wgrd; i++) {
170
	//cntext.strokeRect(i*wgrd, 0, wgrd, 20);
171
    //}
172 168
    if (twidth) {
173 169
	cntext.restore();
174 170
    }
......
464 460
		    dpix  = this.im.width - this.ref_pixels[this.ref_pixels.length-1].x + this.ref_pixels[1].x;
465 461
		    delt = this.ref_pixels[this.ref_pixels.length-1].shift_y - this.ref_pixels[1].shift_y;
466 462
		}
467
		this.ref_pixels[0].dshft_y = delt/dpix;
463
		this.ref_pixels[0].dshft_y = -delt/dpix;
468 464
		this.ref_pixels[ord_pts.length].dshft_y = this.ref_pixels[0].dshft_y;
469 465
		dpix = this.im.width - this.ref_pixels[ord_pts.length].x;
470
		this.ref_pixels[0].shift_y = this.ref_pixels[ord_pts.length].shift_y - dpix*this.ref_pixels[0].dshft_y;
466
		this.ref_pixels[0].shift_y = this.ref_pixels[ord_pts.length].shift_y + dpix*this.ref_pixels[0].dshft_y;
471 467
	    } else {
472 468
		this.ref_pixels[0].shift_y = this.ref_pixels[1].shift_y;
473 469
		this.ref_pixels[0].dshft_y = 0;

Formats disponibles : Unified diff