Further optimizations on SISD

This commit is contained in:
Nikola
2026-07-03 17:58:54 +02:00
parent 259b54e4bb
commit 5c5b11bece
+2 -2
View File
@@ -24,6 +24,7 @@ void tricorn_V2(float complex start, size_t width, ssize_t height, float res, un
float c_start_imag = cimag(start); float c_start_imag = cimag(start);
float c_imag = c_start_imag; float c_imag = c_start_imag;
float vertical_step = imag_step * res;
size_t position = 0; size_t position = 0;
@@ -33,7 +34,6 @@ void tricorn_V2(float complex start, size_t width, ssize_t height, float res, un
// Calculate imaginary part on each row as it stays the same // Calculate imaginary part on each row as it stays the same
float c_real = c_start_real; float c_real = c_start_real;
for(size_t x = 0; x < width; x++){ for(size_t x = 0; x < width; x++){
unsigned value = converge(c_real,c_imag,n); unsigned value = converge(c_real,c_imag,n);
@@ -52,7 +52,7 @@ void tricorn_V2(float complex start, size_t width, ssize_t height, float res, un
c_real += res; c_real += res;
} }
c_imag -= imag_step * res; c_imag -= vertical_step;
} }
} }