Subversion Repositories Applications.papyrus

Compare Revisions

Ignore whitespace Rev 641 → Rev 642

/trunk/client/bottin/bibliotheque/lib.carto.php
29,11 → 29,11
*@version 01 juillet 2002
// +-----------------------------------------------------------------------------------------------+
//
// $Id: lib.carto.php,v 1.2 2005-11-24 16:17:52 florian Exp $
// $Id: lib.carto.php,v 1.3 2005-12-07 14:59:14 alexandre_tb Exp $
// FICHIER : $RCSfile: lib.carto.php,v $
// AUTEUR : $Author: florian $
// VERSION : $Revision: 1.2 $
// DATE : $Date: 2005-11-24 16:17:52 $
// AUTEUR : $Author: alexandre_tb $
// VERSION : $Revision: 1.3 $
// DATE : $Date: 2005-12-07 14:59:14 $
//
// +-----------------------------------------------------------------------------------------------+
// A FAIRE :
599,13 → 599,15
function _lancerColoriage ($id_image = '_00', $nom_fichier = '', $id_zone_a_reperer = '')
{
$this->image = imagecreatefrompng($this->fond);
$this->_colorierImage ($this->image, $this->_info_table_zg['nom_table_zone'], $this->_info_table_zg['nom_chp_id_zone'], $this->_info_table_zg['nom_chp_rouge'],
$this->_info_table_zg['nom_chp_vert'], $this->_info_table_zg['nom_chp_bleu'], $this->_info_table_zg['nom_chp_zone_sup'],
$this->_info_table_zg['tableau_valeurs_zone'], $id_zone_a_reperer) ;
if ($nom_fichier != '') {
imagepng(&$this->image, INS_CHEMIN_APPLI.'bibliotheque/tmp/carto/'.$nom_fichier.'.png');
echo $nom_fichier;
//$this->image = imagepng(&$this->image);
}
else {
785,7 → 787,7
//echo $this->fond.'<BR>';
$image_fond = imagecreatefrompng($this->fond);
$taille_palette = imagecolorstotal ($image_fond);
//echo $taille_palette.'<br>';
if (!$image_fond) echo 'erreur fond';
// Pour chaque couleur contenue dans l'image, nous cherchons l'objet correspondant
// dans le tableau $att, qui contient des informations sur chaque zone de l'image,
// et nous attribuons à l'objet la valeur de l'index de sa couleur dans l'image.
793,6 → 795,7
for ($i = 0; $i < $taille_palette; $i++) {
$valeurs_RVB = array();
$valeurs_RVB = imagecolorsforindex ($image_fond, $i);
for ($j = 0; $j < count ($att); $j++) {
if (($att[$j]->rouge == $valeurs_RVB['red']) && ($att[$j]->vert == $valeurs_RVB['green']) && ($att[$j]->bleu == $valeurs_RVB['blue'])) {
1183,6 → 1186,9
//-- Fin du code source ------------------------------------------------------------
/*
* $Log: not supported by cvs2svn $
* Revision 1.2 2005/11/24 16:17:52 florian
* changement template inscription + modifs carto
*
* Revision 1.1 2005/09/22 14:02:49 ddelon
* nettoyage annuaire et php5
*