console.log(w);
console.log(t);
p = mat_to_png(get_matrix(s,w,t));
- document.getElementById("img_zone").innerHTML = '<img src="data:image/png;base64,'+p.getBase64()+'" style="transform: scale('+scl+'); margin-top: '+20+'px;">';
+ document.getElementById("img_zone").innerHTML = '<img src="data:image/png;base64,'+p.getBase64()+'" style="transform: scale('+scl+'); margin-top: '+scl*p.height/2+'px;">';
//d = document.createElement('div');
//d.innerHTML =
//document.getElementById("img_zone").appendChild(d);