public GenImage ( Settings settings, double t = 0.0 ) : void | ||
settings | Settings | |
t | double | An optional time parameter, for use in animations. /// This value should be between 0 and 1, inclusive. |
Résultat | void |
public static void OneImage( HoneycombDef imageData, double t = 0.0 ) { //string filename = "batch/" + imageData.FormatFilename(); string filename = imageData.FormatFilename(); //if( File.Exists( filename ) ) // return; int p = imageData.P, q = imageData.Q, r = imageData.R; Geometry gCell = Geometry2D.GetGeometry( p, q ); Geometry gVertex = Geometry2D.GetGeometry( q, r ); //if( !( gCell == Geometry.Hyperbolic || gVertex == Geometry.Hyperbolic ) ) //if( !( gVertex == Geometry.Hyperbolic ) ) // return; Sphere[] mirrors = SimplexCalcs.Mirrors( p, q, r ); //double bounds = gCell == Geometry.Spherical ? 9 : 1.1; double bounds = 1.1; bounds = 1; //bounds = 5; //bounds = 7; //bounds = 4.4; //bounds = 10; CoxeterImages imageCalculator = new CoxeterImages(); int size = 200; CoxeterImages.Settings settings = new CoxeterImages.Settings() { Honeycomb = imageData, Width = size, Height = size, Bounds = bounds, Mirrors = mirrors, FileName = imageData.FormatFilename(), }; imageCalculator.AutoCalcScale( settings ); //settings.ColorScaling = 45.1; // 437 //settings.ColorScaling = 60; // 35.58; // 438, 637 cathedral //settings.ColorScaling = 20; // 373 //settings.ColorScaling = 15; //464 if( settings.ColorScaling < 1 ) settings.ColorScaling = 15; settings.ColorScaling = 39; //size = 4320; size = 2500; //settings.Width = size * 4 / 3; settings.Width = size * 2; settings.Width = size; settings.Height = size; //settings.FileName = imageData.FormatFilename( "jpg" ); settings.FileName = filename; imageCalculator.GenImage( settings, t ); }
private static void OneAnimationFrame( HoneycombDef imageData, string filename, double colorScaling, double t = 0.0 ) { int p = imageData.P, q = imageData.Q, r = imageData.R; Sphere[] mirrors = SimplexCalcs.Mirrors( p, q, r ); int size = 750; size = 1024; CoxeterImages.Settings settings = new CoxeterImages.Settings() { Honeycomb = imageData, Width = size*2, Height = size, Bounds = 1.0, Mirrors = mirrors, FileName = filename, }; CoxeterImages imageCalculator = new CoxeterImages(); settings.ColorScaling = colorScaling; imageCalculator.GenImage( settings, t ); }