/*
- * Sixth - System for data storage, computation, exploration and interaction.
- * Copyright ©2012-2016, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu
- *
+ * Sixth 3D engine. Copyright ©2012-2018, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 3 of the GNU Lesser General Public License
* or later as published by the Free Software Foundation.
+ *
*/
package eu.svjatoslav.sixth.e3d.renderer.octree.raytracer;
-import eu.svjatoslav.sixth.e3d.gui.View;
+import eu.svjatoslav.sixth.e3d.gui.ViewPanel;
import eu.svjatoslav.sixth.e3d.renderer.octree.OctreeVolume;
import eu.svjatoslav.sixth.e3d.renderer.raster.Color;
import eu.svjatoslav.sixth.e3d.renderer.raster.texture.Texture;
private static final int PROGRESS_UPDATE_FREQUENCY_MILLIS = 1000;
private final Camera camera;
private final Texture texture;
- private final View view;
+ private final ViewPanel viewPanel;
private OctreeVolume octreeVolume;
private Vector<LightSource> lights;
private int computedLights;
public RayTracer(final Texture texture, final OctreeVolume octreeVolume,
final Vector<LightSource> lights, final Camera camera,
- final View view) {
+ final ViewPanel viewPanel) {
this.texture = texture;
this.octreeVolume = octreeVolume;
this.lights = lights;
this.camera = camera;
- this.view = view;
+ this.viewPanel = viewPanel;
}
@Override
nextBitmapUpdate = System.currentTimeMillis()
+ PROGRESS_UPDATE_FREQUENCY_MILLIS;
texture.resetResampledBitmapCache();
- view.repaintDuringNextViewUpdate();
+ viewPanel.repaintDuringNextViewUpdate();
}
}
texture.resetResampledBitmapCache();
- view.repaintDuringNextViewUpdate();
+ viewPanel.repaintDuringNextViewUpdate();
// System.out.println("Raytracing done.");
// System.out.println("New lights computed:" + computedLights);
}