After the introduction of radiation simulation tools such as Geant4 or EGS in nuclear and high energy physics, the j use in applied fields like nuclear medicine becomes increasingly important and a number of extensions have been introduced wkh particular focus on modeling PET and SPECT systems. Despite die very successful developments there are still a few fields where a different approach is needed: an efficient program that is easily configured in a windows environment allowing a detailed study of the essential properties of gamma ray detection with the emphasis on high flexibility for assessing a new detector design as well as techn^ues for improvement of position resolution, including depth of interaction determination or efficiency optimization. The presented software package GamSim is conceived to fulfill these requirements. In addition it is designed to test new imaging concepts such as the Compton Camera or detection of Cherenkov cones for gamma ray detection. For the latter task to be discussed in more detail, it can be shown that pattern recognition of the Cherenkov ring detection using a Hough transform can be easily implemented. The ease to optimize parameters leads to the conclusion that the concept could allow a depth of interaction measurement of 2 MeV gamma rays with a precision better than 5 mm.