Пример #1
0
        public static void Main(String[] argv, ILog ilog)
        {
            logger = ilog;
            RayTracer rt = new RayTracer();

            rt.size   = 0;
            rt.width  = rt.datasizes [rt.size];
            rt.height = rt.datasizes [rt.size];

            // create the objects to be rendered
            rt.scene = rt.createScene();

            // get lights, objects etc. from scene.
            rt.setScene(rt.scene);

            rt.numobjects = rt.scene.Objects.Count;

            // Set interval to be rendered to the whole picture
            // (overkill, but will be useful to retain this for parallel versions)
            Interval interval = new Interval(0, rt.width, rt.height, 0, rt.height, 1);

            // Do the business!
            rt.render(interval);

            rt.validate();
        }
Пример #2
0
		public static void Main (String[] argv, ILog ilog)
		{
			logger = ilog;
			RayTracer rt = new RayTracer ();

			rt.size = 0;
			rt.width = rt.datasizes [rt.size];
			rt.height = rt.datasizes [rt.size];

			// create the objects to be rendered 
			rt.scene = rt.createScene ();

			// get lights, objects etc. from scene. 
			rt.setScene (rt.scene);

			rt.numobjects = rt.scene.Objects.Count;

			// Set interval to be rendered to the whole picture 
			// (overkill, but will be useful to retain this for parallel versions)
			Interval interval = new Interval (0, rt.width, rt.height, 0, rt.height, 1);

			// Do the business!
			rt.render (interval);

			rt.validate ();
		}