Skip to content

Commit 49ff3d1

Browse files
authored
Merge pull request #32 from jackyarndley/development
Development
2 parents cb064a2 + 41e3d09 commit 49ff3d1

13 files changed

+275
-293
lines changed

Cargo.lock

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "rust_fractal"
3-
version = "0.9.1"
3+
version = "0.10.0"
44
authors = ["jackyarndley <34801340+jackyarndley@users.noreply.github.com>"]
55
description = "Fast, efficient mandelbrot set renderer."
66
edition = "2018"

default.toml

+12-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@ frame_offset = 0
88
zoom_scale = 2.0
99
display_glitches = false
1010
auto_adjust_iterations = true
11-
probe_sampling = 3
1211
remove_centre = true
13-
export = "png"
12+
export = "png"
13+
14+
glitch_tolerance = 1.4e-6
15+
16+
probe_sampling = 3
17+
18+
data_storage_interval = 10
19+
20+
valid_iteration_frame_multiplier = 0.25
21+
valid_iteration_probe_multiplier = 0.02
22+
23+
experimental = false

high.toml

+12-5
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,23 @@
11
image_width = 1920
22
image_height = 1080
33
rotate = 0
4-
approximation_order = 48
4+
approximation_order = 64
55
glitch_percentage = 0.001
6-
frames = 5
6+
frames = 1
77
frame_offset = 0
88
zoom_scale = 2.0
99
display_glitches = false
1010
auto_adjust_iterations = true
11-
probe_sampling = 3
1211
remove_centre = true
1312
export = "png"
1413

15-
# By default this is squared tolerance. 1e-6 works normally, 1.4e-6 is low tolerance.
16-
glitch_tolerance = 1.4e-6
14+
glitch_tolerance = 1.4e-6
15+
16+
probe_sampling = 15
17+
18+
data_storage_interval = 10
19+
20+
valid_iteration_frame_multiplier = 0.05
21+
valid_iteration_probe_multiplier = 0.005
22+
23+
experimental = false

high_experimental.toml

-25
This file was deleted.

locations/dinosaur_fossils.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
real = "-0.045543734336104922997753573953362987952549530292977965266292112797459589792231033578387324341928465086153893360107821481913555372483770632133971888332631822912236818408840452953040519155137399849701223018058413800044053431990435966350410010573741463215232477964394074861926088627519202745343677408902348562270720292029128964817850028455173141607574274533183047065704723494925373151809520213220844956483079344222961455491879886243117850095752773527957699546532333280900334180870137695293387945654736115037817652760017025891787541126725581692296144140325726214597321992051716234213168202290782457095112299262693161570525878235439678140992693249495205789720166483781939926553209863523646697933871258605601557231633409530001196840016852181985220199064456119926114467233072765203286533936786963498664977772017424409163162542676952457987430028127319173821059507800986265426038376634812657122611979112449744143363632525320910476859216"
22
imag = "0.9866390088941988645150586209098181638200792146329707957369597572089601961252684358219210571844059356391404918293663658689671936968530305499316926124336179373238260149834067036000594669454332226484603210734117864774839510431532750563672691024507409580272827378950592345898346798717534030494374279536980374355416747263183831235698083443270193212119753814556220380181679807891988554440177150978755290306824054574165130141279753460537187861866358437357076847426167626036007556115559873142337004435392812057544278541991003339585715168359016367741460792587043775226624873309589966713198542867085804755529124924713805777196039651149363319529711545613480663190670878453958246775284572788031962257561770109847356957435156175131706885171380109469977424599946647141330774785077270644518587235659388247437290773748440333712187723778390938636024534081787054809675374022598805727843911265546491872725733956159738812931570074259860927965800499999999999999999959"
3-
zoom = "2.90e501"
4-
iterations = 17632751
3+
zoom = "2.90e201"
4+
iterations = 5000000

locations/seahorse.toml

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
real = "-1.7498441034048860332429896254986461454981375596212873423364695238384220660214435499438188172810227266667721990643588184378129273491688001456131733853016110755380465117345491577267928528922509796142123590339991792529770000047571290486607089919747608950151759067279704849300628467983059517708888859444700392202393785787616793102188288937472363282054788159802547153015231695937927310513470263475291975825600320853492837262601019580042606504749354862734425114892313010595182045630683210920394989000265841943591045165345177031459914939506231134377085839613973734087045454736234997518358082761016630846052906829270711718755590356545783091020968928854243323951424216849150261046250107972947892684716215071645767033819936893678439957714795693665591161137512982309563404946673667093118237910969684191185258598355587326587555077835018013323826206346230523809082927753203533521172155424344252162363778693045421367421119951131833819995542229067556138935939902750859737764900495992777992287041688189329995313633667454958622420932731335729405469370973791380838354664818392459627746914488610199442125155303488733535538947355984219469049723484741056233002692266869251114166571315788387694947666101374106929402297390903156877310162550106871507658604236354883801856472939572739167383497360301118924284391431993484649582695912321008048038103208011091265836785741711198382705211161920632418677506455489518178543801153700"
2+
imag = "-0.0000000000460125286107025139163407718468883755324002547592942194722264219201790488853455740647567199318406306868335491364311432945167676851686069907112186769604084692781631392615530706242378513644888824721432352705434876029333687093730278134335540654003290550370130430505695775689107798309788868480874567967349245240924659835601947408217886408205036115937284964575087176037202818129171448643517544693516248725320414704527568111905277001581940159134062567130044628543900024118853721519399742234801496166575739738374047774847818143002944495716750661204598090282486096971927127089053080493651961175786475040954245382775738632605697024399727565074828417680473676871461267909544733251360868102527517113415504209233367832216578423105499501802493131082878758767584093510606651059546017608777160847081765023236144174934441000432652288110922097122405331026956415383722948133827465025932241908272435226701440841420127433189813692171836473305997847567522083749458485018803015072589820890890055131395438340103327588750259301541619620355849043579773413048636336128755122887191991673908087035737172301841315976870128167938152776835274372718812311771773450363748456120981532658633904050912777044955384197973324471094361635231643436430567751204197332708259591572868242082794187145983468392613774532005575699886292494262726259735465454791642819335360888288887165312806271245722897552945264894956489166326272342365000"
3+
iterations = 10000000000
4+
zoom = "7.8685178941898205790628188309939E1392"

locations/x.toml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
real = "-1.479796270901760024425279934770411525645551054432599517909807632824286254403907594526888466099962805022975196472549771681831234491695559852583955204986197762293872769474806903995564259040667568599770094383157857518790853771783314763231302599999999999999999999999998"
22
imag = "-0.001199443952813447746281973233374468444560314114132538362037569205657422216739564521471119107626453330996365067987088146663639996715939831819152248618042255824652268918299630897525386638029428706473919823922522752497780934312003352081931299999999999999999999999998"
33
iterations = 50000
4-
zoom = "4.27799999998E235"
4+
zoom = "4.27799999998E235"
5+
rotate = 45.0

low.toml

+12-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@ frame_offset = 0
88
zoom_scale = 2.0
99
display_glitches = false
1010
auto_adjust_iterations = true
11-
probe_sampling = 2
1211
remove_centre = true
13-
export = "png"
12+
export = "png"
13+
14+
glitch_tolerance = 1.4e-6
15+
16+
probe_sampling = 3
17+
18+
data_storage_interval = 10
19+
20+
valid_iteration_frame_multiplier = 0.25
21+
valid_iteration_probe_multiplier = 0.02
22+
23+
experimental = false

run_tests.sh

+18-18
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
1-
./target/release/main -o high_experimental.toml locations/glitch_test_1.toml
2-
./target/release/main -o high_experimental.toml locations/glitch_test_2.toml
3-
./target/release/main -o high_experimental.toml locations/glitch_test_3.toml
4-
./target/release/main -o high_experimental.toml locations/glitch_test_4.toml
5-
./target/release/main -o high_experimental.toml locations/glitch_test_5.toml
6-
./target/release/main -o high_experimental.toml locations/glitch_test_6.toml
1+
./target/release/main -o high.toml locations/glitch_test_1.toml
2+
./target/release/main -o high.toml locations/glitch_test_2.toml
3+
./target/release/main -o high.toml locations/glitch_test_3.toml
4+
./target/release/main -o high.toml locations/glitch_test_4.toml
5+
./target/release/main -o high.toml locations/glitch_test_5.toml
6+
./target/release/main -o high.toml locations/glitch_test_6.toml
77

8-
./target/release/main -o high_experimental.toml locations/1e14.toml
9-
./target/release/main -o high_experimental.toml locations/11_dimensions.toml
10-
./target/release/main -o high_experimental.toml locations/e10000.toml
11-
./target/release/main -o high_experimental.toml locations/flake.toml
12-
./target/release/main -o high_experimental.toml locations/floral_fantasy.toml
13-
./target/release/main -o high_experimental.toml locations/golden_spider.toml
14-
./target/release/main -o high_experimental.toml locations/long.toml
15-
./target/release/main -o high_experimental.toml locations/lya.toml
16-
./target/release/main -o high_experimental.toml locations/opus.toml
17-
./target/release/main -o high_experimental.toml locations/peanuts.toml
18-
./target/release/main -o high_experimental.toml locations/wfs.toml
19-
./target/release/main -o high_experimental.toml locations/x.toml
8+
./target/release/main -o high.toml locations/1e14.toml
9+
./target/release/main -o high.toml locations/11_dimensions.toml
10+
./target/release/main -o high.toml locations/e10000.toml
11+
./target/release/main -o high.toml locations/flake.toml
12+
./target/release/main -o high.toml locations/floral_fantasy.toml
13+
./target/release/main -o high.toml locations/golden_spider.toml
14+
./target/release/main -o high.toml locations/long.toml
15+
./target/release/main -o high.toml locations/lya.toml
16+
./target/release/main -o high.toml locations/opus.toml
17+
./target/release/main -o high.toml locations/peanuts.toml
18+
./target/release/main -o high.toml locations/wfs.toml
19+
./target/release/main -o high.toml locations/x.toml

src/math/reference.rs

+8-6
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ pub struct Reference {
1010
pub reference_data: Vec<ReferenceIteration>,
1111
// This is for every 100th iteration, when we do glitch correction the new references will be spawed from these values
1212
// Storing every iteration is memory intensive.
13-
pub high_precision_data_interval: usize,
13+
pub data_storage_interval: usize,
1414
pub high_precision_data: Vec<ComplexArbitrary>,
1515
pub glitch_tolerance: f64,
1616
}
@@ -24,15 +24,15 @@ pub struct ReferenceIteration {
2424
}
2525

2626
impl Reference {
27-
pub fn new(z: ComplexArbitrary, c: ComplexArbitrary, current_iteration: usize, maximum_iteration: usize, high_precision_data_interval: usize, glitch_tolerance: f64) -> Reference {
27+
pub fn new(z: ComplexArbitrary, c: ComplexArbitrary, current_iteration: usize, maximum_iteration: usize, data_storage_interval: usize, glitch_tolerance: f64) -> Reference {
2828
Reference {
2929
start_iteration: current_iteration,
3030
current_iteration,
3131
maximum_iteration,
3232
z,
3333
c,
3434
reference_data: Vec::with_capacity(1000),
35-
high_precision_data_interval,
35+
data_storage_interval,
3636
high_precision_data: Vec::with_capacity(1000),
3737
glitch_tolerance
3838
}
@@ -88,9 +88,11 @@ impl Reference {
8888
);
8989

9090
while self.current_iteration < self.maximum_iteration {
91-
if self.start_iteration == 1 && self.current_iteration % self.high_precision_data_interval == 1 {
92-
self.high_precision_data.push(self.z.clone());
93-
};
91+
if self.start_iteration == 1 {
92+
if self.data_storage_interval == 1 || self.current_iteration % self.data_storage_interval == 1 {
93+
self.high_precision_data.push(self.z.clone());
94+
}
95+
}
9496

9597
if !self.step() {
9698
break;

0 commit comments

Comments
 (0)