
smallSizes = new Array(77,77);
mediumSizes = new Array(200,170);
pageName = 'portfolio.htm';
scriptName = 'portfolio.js';
countX = 4;
countY = 2;

// sections: name, small images path, medium images path, big images path
// images: name, src, big width, big height
var arImages = new Array(
  new Array('Stone Walls, Steps, and Patios','images/portfolio/small/','images/portfolio/medium/','images/portfolio/big/',
     new Array(
      new Array('Photo 1','100_0566.jpg',534,400),
      new Array('Photo 2','after.jpg',534,400),
      new Array('Photo 3','amazing fireplace waterfall pool stamped concrete.jpg',534,400),
      new Array('Photo 4','b4milton1.jpg',534,400),
      new Array('Photo 5','beforeafter_09_a2.jpg',301,400),
      new Array('Photo 6','Blue and Green Plum Pennsylvania  Flag Stone Irregular Pattern Poollg.jpg',629,401),
      new Array('Photo 7','Blue and Green Plum Pennsylvania Flag Stone Irregular Pattern Patio.jpg',538,400),
      new Array('Photo 8','burghundy lateral diagonal pavers.jpg',560,376),
      new Array('Photo 9','Chocolate Gray Steps800.jpg',534,400),
      new Array('Photo 10','dandridgepatio.jpg',534,400),
      new Array('Photo 11','DSCN4078.jpg',535,400),
      new Array('Photo 12','DSCN4079.jpg',535,400),
      new Array('Photo 13','DSCN4625.jpg',535,400),
      new Array('Photo 14','DSCN4631.jpg',535,400),
      new Array('Photo 15','DSCN4670.jpg',535,400),
      new Array('Photo 16','DSCN4831.jpg',535,400),
      new Array('Photo 17','DSCN4832.jpg',535,400),
      new Array('Photo 18','DSCN4910.jpg',535,400),
      new Array('Photo 19','DSCN5152.jpg',535,400),
      new Array('Photo 20','DSCN5153.jpg',535,400),
      new Array('Photo 21','DSCN5155.jpg',535,400),
      new Array('Photo 22','DSCN5156.jpg',535,400),
      new Array('Photo 23','DSCN5157.jpg',535,400),
      new Array('Photo 24','DSCN5158.jpg',535,400),
      new Array('Photo 25','DSCN5268.jpg',535,400),
      new Array('Photo 26','DSCN5271.jpg',535,400),
      new Array('Photo 27','DSCN5277 - Copy.jpg',535,400),
      new Array('Photo 28','DSCN5595.jpg',535,400),
      new Array('Photo 29','DSCN5606.jpg',535,400),
      new Array('Photo 30','DSCN5607.jpg',535,400),
      new Array('Photo 31','DSCN5608.jpg',535,400),
      new Array('Photo 32','DSCN5609.jpg',535,400),
      new Array('Photo 33','DSCN5610.jpg',535,400),
      new Array('Photo 34','DSCN5648.jpg',535,400),
      new Array('Photo 35','field ston walk.jpg',300,400),
      new Array('Photo 36','field stone steps.jpg',410,308),
      new Array('Photo 37','Granny M1s 89th B-day 021.jpg',384,288),
      new Array('Photo 38','Harry Duncan job 010.jpg',240,320),
      new Array('Photo 39','IMG_1493.jpg',534,400),
      new Array('Photo 40','IMG_1494.jpg',534,400),
      new Array('Photo 41','IMG_1534_1.jpg',534,400),
      new Array('Photo 42','IMG_2665.jpg',600,400),
      new Array('Photo 43','kirk-3 frnt.jpg',534,400),
      new Array('Photo 44','Lewis+Head steps.jpg',534,400),
      new Array('Photo 45','Lintner3.jpg',534,400),
      new Array('Photo 46','LW_060718_OWENS_334.jpg',595,400),
      new Array('Photo 47','mixed media large small standard grey and burghandy.jpg',268,401),
      new Array('Photo 48','Newcombe After Best 600 pix.jpg',534,400),
      new Array('Photo 49','roshko steps.jpg',534,400),
      new Array('Photo 50','Stone pics website 064.jpg',384,288),
      new Array('Photo 51','Tennessee Field Stone Steps.jpg',534,400),
      new Array('Photo 52','Untitled-1.jpg',575,393),
      new Array('Photo 53','Untitled-10.jpg',578,397),
      new Array('Photo 54','Untitled-5.jpg',574,393),
      new Array('Photo 55','Untitled-6.jpg',255,400)
    )
  )
)


section = getParameter(self.document.location.href, 'section');
if (isNaN(section) || (section=='') || (section<0) || (section>arImages.length))
  section = 0; 

ind = getParameter(self.document.location.href, 'ind');
if (isNaN(ind) || (ind=='') || (ind<0) || (ind>arImages[section][4].length))
  ind = 0; 

var arPreloadImages = new Array();
function preload() {
  if (arImages[section][2]!='') {
    for (i=ind;(i<(Number(ind)+Number(countX*countY))) && (i<arImages[section][4].length);i++) {
      arPreloadImages[i] = new Image(mediumSizes[0],mediumSizes[1]);
      arPreloadImages[i].src = arImages[section][2]+arImages[section][4][i][1];
    }
  }
}
  
function showImageMedium(number) {
  showImage('imagemedium',arImages[section][2]+arImages[section][4][number][1]);
  showMessage('imagemediumname',arImages[section][4][number][0]);
}

function showImageBig(number) {
  showImagePopup(scriptName,section,number,arImages[section][4][number][2],
   arImages[section][4][number][3]);
}
