Inheritance: PovObj
コード例 #1
0
ファイル: Frame.cs プロジェクト: pitafubar/VisualPOVray
 public Frame(Camera cam, String color)
 {
     this.frameCount = 0;
     this.color = color;
     this.world = new List<PovObj>();
     this.world.Add(cam);
 }
コード例 #2
0
ファイル: Frame.cs プロジェクト: pitafubar/VisualPOVray
 public Frame(Camera cam)
 {
     this.frameCount = 0;
     this.color = "Black";
     this.world = new List<PovObj>();
     this.world.Add(cam);
 }
コード例 #3
0
 public Frame(Camera cam, String color = "Black", bool animated = false)
 {
     this.frameCount = 0;
     this.color = color;
     this.world = new List<PovObj>();
     this.events = new List<Event>();
     this.world.Add(cam);
     this.animated = animated;
 }
コード例 #4
0
ファイル: Form1.cs プロジェクト: pitafubar/VisualPOVray
 public Form1()
 {
     InitializeComponent();
     cam = new Camera(new Point3(0, 2, -3), new Point3(0, 1, 2));
     f = new Frame(cam, "Cyan");
     f.addInclude("colors.inc");
     for (int i = 0; i < 10; i++)
     {
         s = new Sphere(new Point3(i, 1, 2), 2);
         f.add(s);
     }
     l = new Light(new Point3(2, 4, -3));
     f.add(l);
 }
コード例 #5
0
 public Form1()
 {
     InitializeComponent();
     cam = new Camera(new Point3(0, 2, -3), new Point3(0, 1, 2));
     frame = new Frame(cam, "Cyan");
     frame.addInclude("colors.inc");
     l = Light.pointLight(new Point3(2, 4, -3));
     frame.add(l);
     Event e = f.event1(2, eve);
     frame.addEvent(e);
     frame.addEvent(f.event1(2, add));
     frame.add(f.sphere(f.p3(0, 1, 2, reactive: true), rrad: f.integral(f.lift0(1f), .5f), reactive: true));
     frame.start(30, 20);
 }
コード例 #6
0
 private void renderButt_Click(object sender, EventArgs e)
 {
     writer1.Add("width=" + imageWidthTB.Text);
     writer1.Add(Environment.NewLine);
     writer1.Add("height=" + imageHeightTB.Text);
     writer1.Add(Environment.NewLine);
     writer1.Add("Display_Gamma=" + imageGammaBar.Value / 100.0);
     writer1.Add(Environment.NewLine);
     writer1.Add("+Q" + quality);
     writer1.Add(Environment.NewLine);
     writer1.Add("Antialias=On");
     writer1.Add(Environment.NewLine);
     writer1.Add("Antialias_Threshold=" + alias);
     Point3 camLoc = new Point3((Convert.ToInt32(xPosTB.Text)), (Convert.ToInt32(yPosTB.Text)), (Convert.ToInt32(zPosTB.Text)));
     Point3 camLook = new Point3((Convert.ToInt32(xDirTB.Text)), (Convert.ToInt32(yDirTB.Text)), (Convert.ToInt32(zDirTB.Text)));
     camXPosLab.Text = " " + camLoc.x;
     camYPosLab.Text = " " + camLoc.y;
     camZPosLab.Text = " " + camLoc.z;
     camXDirLab.Text = " " + camLook.x;
     camXDirLab.Text = " " + camLook.y;
     camXDirLab.Text = " " + camLook.z;
     frame.remove(cam);
     cam = new Camera(location: camLoc, look_at: camLook);
     frame.add(cam);
     frame.render();
 }