From 051ae891cc6d06a440a2c96098835a9d5299cbf4 Mon Sep 17 00:00:00 2001 From: Refik Hadzialic Date: Wed, 10 Aug 2011 21:14:14 +0200 Subject: new icons added, the output result image extended. --- .../pChart2.1.2/examples/example.writeBounds.php | 107 ++++++++++++++++++--- .../examples/newIcons/BTSNOK3little.png | Bin 0 -> 1273 bytes .../pChart2.1.2/examples/newIcons/BTSOK3little.png | Bin 0 -> 1341 bytes .../pChart2.1.2/examples/newIcons/Help.png | Bin 0 -> 4497 bytes .../pChart2.1.2/examples/newIcons/Help1.png | Bin 0 -> 3789 bytes .../pChart2.1.2/examples/newIcons/NOKlittle.png | Bin 0 -> 1980 bytes .../pChart2.1.2/examples/newIcons/OKlittle.png | Bin 0 -> 2109 bytes .../pChart2.1.2/examples/newIcons/SIPEXT.png | Bin 0 -> 17163 bytes .../pChart2.1.2/examples/newIcons/SIPLOC.png | Bin 0 -> 15220 bytes 9 files changed, 92 insertions(+), 15 deletions(-) create mode 100644 notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK3little.png create mode 100644 notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK3little.png create mode 100644 notFinishedCode/pChart2.1.2/examples/newIcons/Help.png create mode 100644 notFinishedCode/pChart2.1.2/examples/newIcons/Help1.png create mode 100644 notFinishedCode/pChart2.1.2/examples/newIcons/NOKlittle.png create mode 100644 notFinishedCode/pChart2.1.2/examples/newIcons/OKlittle.png create mode 100644 notFinishedCode/pChart2.1.2/examples/newIcons/SIPEXT.png create mode 100644 notFinishedCode/pChart2.1.2/examples/newIcons/SIPLOC.png (limited to 'notFinishedCode/pChart2.1.2/examples') diff --git a/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php b/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php index 7e0af80..55bd22d 100644 --- a/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php +++ b/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php @@ -6,17 +6,17 @@ include("../class/pImage.class.php"); /* Create the pChart object */ - $myPicture = new pImage(800,630); //result image size - $myPicture->drawGradientArea(0,0,800,630,DIRECTION_VERTICAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));//make gradient - $myPicture->drawGradientArea(0,0,800,630,DIRECTION_HORIZONTAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>20));//make gradient - $myPicture->drawGradientArea(0,0,60,630,DIRECTION_HORIZONTAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));//black gradient field on left + $myPicture = new pImage(800,700); //result image size + $myPicture->drawGradientArea(0,0,800,700,DIRECTION_VERTICAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));//make gradient + $myPicture->drawGradientArea(0,0,800,700,DIRECTION_HORIZONTAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>20));//make gradient + $myPicture->drawGradientArea(0,0,60,700,DIRECTION_HORIZONTAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));//black gradient field on left /* Do some cosmetics, add the black outlining and the name of the picture on left side*/ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10)); $myPicture->drawLine(60,0,60,230,array("R"=>70,"G"=>70,"B"=>70)); - $myPicture->drawRectangle(0,0,799,629,array("R"=>0,"G"=>0,"B"=>0)); + $myPicture->drawRectangle(0,0,799,699,array("R"=>0,"G"=>0,"B"=>0)); $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11)); - $myPicture->drawText(30,400,"Network test results - UNIVERSITY OF FREIBURG",array("R"=>255,"G"=>255,"B"=>255,"FontSize"=>20,"Angle"=>90,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE)); + $myPicture->drawText(30,500,"Network test results - UNIVERSITY OF FREIBURG",array("R"=>255,"G"=>255,"B"=>255,"FontSize"=>20,"Angle"=>90,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE)); @@ -36,7 +36,7 @@ //BTS2 - $myPicture->drawLine(220, 320, 420,350,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1)); + $myPicture->drawLine(220, 320, 420,320,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1)); $myPicture->drawFromPNG(180,280,"BTSCont.png"); $myPicture->drawFromPNG(60,230,"newIcons/BTSNOK3.png"); @@ -71,31 +71,108 @@ - //external system outlining! + + //external GSM system outlining! $RectangleSettings = array("R"=>124,"G"=>229,"B"=>129,"Alpha"=>20); $myPicture->drawFilledRectangle(320,10,540,160,$RectangleSettings); - //external cell network + //external GSM network $myPicture->drawLine(430, 60,430,300,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1)); $myPicture->drawFromPNG(390,30,"newIcons/externalCells.png"); + + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>6)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(324,30,"EXTERNAL GSM NETWORK: OK",$TextSettings); + + + + //external SIP system outlining! + $RectangleSettings = array("R"=>124,"G"=>229,"B"=>129,"Alpha"=>20); + $myPicture->drawFilledRectangle(580,10,795,160,$RectangleSettings); + //external SIP network + $myPicture->drawLine(695, 90,480,300,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1)); + $myPicture->drawFromPNG(650,45,"newIcons/SIPEXT.png"); + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>6)); $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); - $myPicture->drawText(324,40,"GSM EXTERNAL NETWORK: OK",$TextSettings); + $myPicture->drawText(585,30,"EXTERNAL SIP NETWORK: OK",$TextSettings); + + //local SIP system outlining! + $RectangleSettings = array("R"=>137,"G"=>202,"B"=>230,"Alpha"=>20); + $myPicture->drawFilledRectangle(580,250,795,400,$RectangleSettings); + //local SIP network + $myPicture->drawLine(695, 330,480,330,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1)); + $myPicture->drawFromPNG(650,280,"newIcons/SIPLOC.png"); - $myPicture->drawFromPNG(380,280,"server.png"); - //$myPicture->writeLabel("Testing",0); + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>6)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(585,270,"LOCAL SIP NETWORK: OK",$TextSettings); + // add server picture + $myPicture->drawFromPNG(380,280,"server.png"); - //are the subsystems completely OK +//are the subsystems completely OK //GSM External modem - $myPicture->drawFromPNG(513,135,"newIcons/OK.png"); + $myPicture->drawFromPNG(300,135,"newIcons/OK.png"); //landline system $myPicture->drawFromPNG(505,580,"newIcons/OK.png"); //GSM Local network $myPicture->drawFromPNG(220,560,"newIcons/NOK.png"); + //SIP external network + $myPicture->drawFromPNG(558,135,"newIcons/OK.png"); + //SIP local network + $myPicture->drawFromPNG(558,375,"newIcons/OK.png"); - + /* Write a legend box */ + $RectangleSettings = array("R"=>255,"G"=>255,"B"=>255,"Ticks"=>2, "Alpha"=>99); + $myPicture->drawRectangle(61,630,799,698,$RectangleSettings); + //make the legend title + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>10)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>12); + $myPicture->drawText(65,645,"LEGEND:",$TextSettings); +// $myPicture->drawFromPNG(65,637,"newIcons/Help1.png"); + $myPicture->drawLine(70,660,90,660,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1)); + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>8)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(97,668,"Physical connection OK",$TextSettings); + + + $myPicture->drawLine(70,680,90,680,array("R"=>255,"G"=>0,"B"=>0,"Ticks"=>8,"Weight"=>1)); + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>8)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(97,688,"Physical connection NOT OK",$TextSettings); + + + $myPicture->drawFromPNG(310,642,"newIcons/OKlittle.png"); + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>8)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(337,661,"Subsytem is OK",$TextSettings); + + $myPicture->drawFromPNG(310,670,"newIcons/NOKlittle.png"); + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>8)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(337,689,"Subsytem is NOT OK",$TextSettings); + + + $myPicture->drawFromPNG(490,642,"newIcons/BTSOK3little.png"); + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>8)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(517,661,"BTS is OK",$TextSettings); + + $myPicture->drawFromPNG(490,670,"newIcons/BTSNOK3little.png"); + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>8)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(517,689,"BTS is NOT OK",$TextSettings); + + + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>8)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(637,661,"White labels are OK",$TextSettings); + + $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>8)); + $TextSettings = array("DrawBox"=>FALSE,"R"=>255,"G"=>0,"B"=>0,"Angle"=>0,"FontSize"=>10); + $myPicture->drawText(637,689,"Red labels are NOT OK",$TextSettings); /* Render the picture (choose the best way) */ $myPicture->autoOutput("pictures/example.writeBounds.png"); diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK3little.png b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK3little.png new file mode 100644 index 0000000..9e0277f Binary files /dev/null and b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK3little.png differ diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK3little.png b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK3little.png new file mode 100644 index 0000000..0a09af1 Binary files /dev/null and b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK3little.png differ diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/Help.png b/notFinishedCode/pChart2.1.2/examples/newIcons/Help.png new file mode 100644 index 0000000..6664032 Binary files /dev/null and b/notFinishedCode/pChart2.1.2/examples/newIcons/Help.png differ diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/Help1.png b/notFinishedCode/pChart2.1.2/examples/newIcons/Help1.png new file mode 100644 index 0000000..53a48d0 Binary files /dev/null and b/notFinishedCode/pChart2.1.2/examples/newIcons/Help1.png differ diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/NOKlittle.png b/notFinishedCode/pChart2.1.2/examples/newIcons/NOKlittle.png new file mode 100644 index 0000000..7214de3 Binary files /dev/null and b/notFinishedCode/pChart2.1.2/examples/newIcons/NOKlittle.png differ diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/OKlittle.png b/notFinishedCode/pChart2.1.2/examples/newIcons/OKlittle.png new file mode 100644 index 0000000..6191dc8 Binary files /dev/null and b/notFinishedCode/pChart2.1.2/examples/newIcons/OKlittle.png differ diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/SIPEXT.png b/notFinishedCode/pChart2.1.2/examples/newIcons/SIPEXT.png new file mode 100644 index 0000000..ca0d290 Binary files /dev/null and b/notFinishedCode/pChart2.1.2/examples/newIcons/SIPEXT.png differ diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/SIPLOC.png b/notFinishedCode/pChart2.1.2/examples/newIcons/SIPLOC.png new file mode 100644 index 0000000..a494cc7 Binary files /dev/null and b/notFinishedCode/pChart2.1.2/examples/newIcons/SIPLOC.png differ -- cgit v1.2.3-55-g7522