1. A ray tracing system having stencil based primary ray shooting, comprising: one or more processors with memory, a data structure of a scene, based on a grid of cells, wherein stencils are generated in data filled cells prior to primary ray shooting, while during the primary ray shooting local ray segments are generated in cells for only those shooting rays that hit the cell stencils, and intersection tests are conducted between said local ray segments and between local objects, generating primary intersection points.