void QCSXCAD::ExportGeometry_Povray() { QString filename = QFileDialog::getSaveFileName( this, tr("Save Povray file"), QString(), tr("Povray files (*.pov)") ); if (filename.isEmpty()) return; export_pov pov( this ); pov.save( filename ); // start povray? int ans = QMessageBox::question( 0, "Start Povray", "Should the file directly be rendered?", "Yes", "No", "", 0, 1 ); if (ans == 1) return; // start povray QStringList args; args << filename; args << "-W640"; args << "-H480"; args << "+A"; //only valid for povray >3.7.0 args << "+WT4"; QProcess::startDetached( "povray", args, QFileInfo(filename).absolutePath() ); return; // // Instead of letting renderer to render the scene, we use // // an exportor to save it to a file. // vtkPOVExporter *povexp = vtkPOVExporter::New(); // povexp->SetRenderWindow( ((QVTKWidget*)(StructureVTK->GetVTKWidget()))->GetRenderWindow() ); // povexp->SetFileName("/tmp/TestPOVExporter.pov"); // cout << "Writing file TestPOVExporter.pov..." << endl; // // povexp->Write(); // cout << "Done writing file TestPOVExporter.pov..." << endl; // // povexp->Delete(); }
__interrupt void Port_1(void) { _delay_ms(500); pov(0,0); pov(240,0); pov(240,0); pov(192,0); pov(199,0); pov(198,3); pov(198,7); pov(255,255); pov(255,255); pov(198,7); pov(198,3); pov(199,0); pov(192,0); pov(240,0); pov(240,0); pov(0,0); pov(15,240); pov(16,8); pov(32,4); pov(64,2); pov(135,129); pov(136,65); pov(136,65); pov(136,65); pov(132,129); pov(131,193); pov(64,66); pov(32,132); pov(19,8); pov(12,48); pov(0,0); pov(128,129); pov(128,129); pov(255,255); pov(128,129); pov(128,129); pov(0,0); pov(255,255); pov(145,96); pov(145,24); pov(145,6); pov(145,255); pov(0,0); pov(195,98); pov(36,145); pov(24,145); pov(36,145); pov(195,78); pov(0,0); pov(63,128); pov(72,128); pov(136,255); pov(72,128); pov(63,128); pov(0,0); pov(98,255); pov(145,136); pov(145,140); pov(145,138); pov(78,113); pov(0,0); pov(0,254); pov(0,1); pov(0,1); pov(0,1); pov(0,254); pov(0,0); pov(0,255); pov(0,64); pov(0,48); pov(0,64); pov(0,255); pov(0,0); pov(0,255); pov(0,145); pov(0,145); pov(0,145); pov(0,145); pov(0,0); pov(0,255); pov(0,96); pov(0,24); pov(0,6); pov(0,255); pov(0,0); pov(0,128); pov(0,128); pov(0,255); pov(0,128); pov(0,128); pov(0,0); pov(0,98); pov(0,145); pov(0,145); pov(0,145); pov(0,78); pov(0,0); //timer_A_delay_set_reset(); P1IFG &= ~BIT3; // P1.x IFG cleared }