aboutsummaryrefslogtreecommitdiff
path: root/algorithms
diff options
context:
space:
mode:
authorDavid Phillips <dbphillipsnz@gmail.com>2016-05-19 14:51:50 +1200
committerDavid Phillips <dbphillipsnz@gmail.com>2016-05-19 14:51:50 +1200
commit3fde94e7b3fc9c79c79a5e08bf2e73ef55ecb8a5 (patch)
tree95de70aa5f42dbefa2518d37de3e225514d4ab17 /algorithms
parent16ce67e0e043557cec44209db53c8c50635065fa (diff)
downloadfractal-gen-3fde94e7b3fc9c79c79a5e08bf2e73ef55ecb8a5.tar.xz
Style change
Diffstat (limited to 'algorithms')
-rw-r--r--algorithms/burning-ship-lattice.c12
-rw-r--r--algorithms/burning-ship.c12
-rw-r--r--algorithms/mandelbrot.c12
3 files changed, 15 insertions, 21 deletions
diff --git a/algorithms/burning-ship-lattice.c b/algorithms/burning-ship-lattice.c
index cb3e268..6a7241e 100644
--- a/algorithms/burning-ship-lattice.c
+++ b/algorithms/burning-ship-lattice.c
@@ -27,7 +27,8 @@
#include "common.h"
-void *generate_burning_ship_lattice_section(void *section)
+void
+*generate_burning_ship_lattice_section(void *section)
{
data_section *d = (data_section*)section;
unsigned int x = 0;
@@ -44,15 +45,12 @@ void *generate_burning_ship_lattice_section(void *section)
/* FIXME document this */
b = clust_id*(size_units/size)+top; /* FIXME document this */
- for (y = clust_id; y < size; y+=clust_total)
- {
+ for (y = clust_id; y < size; y+=clust_total) {
a = d->core*(size_units/size)+left;
- for (x = d->core; x < size; x += cores)
- {
+ for (x = d->core; x < size; x += cores) {
z = 0;
c = a+I*b;
- for (i = 0; i < iterat; i++)
- {
+ for (i = 0; i < iterat; i++) {
if (cabs(z) >= 2)
break;
diff --git a/algorithms/burning-ship.c b/algorithms/burning-ship.c
index 6aea927..56323ac 100644
--- a/algorithms/burning-ship.c
+++ b/algorithms/burning-ship.c
@@ -27,7 +27,8 @@
#include "common.h"
-void *generate_burning_ship_section(void *section)
+void
+*generate_burning_ship_section(void *section)
{
data_section *d = (data_section*)section;
unsigned int x,y,i;
@@ -40,15 +41,12 @@ void *generate_burning_ship_section(void *section)
/* FIXME document this */
b = clust_id*(size_units/size)+top; /* FIXME document this */
- for (y = clust_id; y < size; y += clust_total)
- {
+ for (y = clust_id; y < size; y += clust_total) {
a = d->core*(size_units/size)+left;
- for (x = d->core; x < size; x += cores)
- {
+ for (x = d->core; x < size; x += cores) {
z = 0;
c = a+I*b;
- for (i = 0; i < iterat; i++)
- {
+ for (i = 0; i < iterat; i++) {
if (cabs(z) >= 2)
break;
diff --git a/algorithms/mandelbrot.c b/algorithms/mandelbrot.c
index 2d0a2b4..67da2c6 100644
--- a/algorithms/mandelbrot.c
+++ b/algorithms/mandelbrot.c
@@ -27,7 +27,8 @@
#include "common.h"
-void *generate_mandelbrot_section(void *section)
+void
+*generate_mandelbrot_section(void *section)
{
data_section *d = (data_section*)section;
unsigned int x,y,i;
@@ -41,15 +42,12 @@ void *generate_mandelbrot_section(void *section)
/* FIXME document this */
b = clust_id*(size_units/size)+top; /* FIXME document this */
- for (y = clust_id; y < size; y += clust_total)
- {
+ for (y = clust_id; y < size; y += clust_total) {
a = d->core*(size_units/size)+left;
- for (x = d->core; x < size; x += cores)
- {
+ for (x = d->core; x < size; x += cores) {
z = 0;
c = a + I*b;
- for (i = 0; i < iterat; i++)
- {
+ for (i = 0; i < iterat; i++) {
if (cabs(z) >= 2)
break;