mightymandel v16

GPU-based Mandelbrot set explorer

ref_set.c File Reference

(v16)

Collection of reference coordinates. More...

#include <stdlib.h>
#include "logging.h"
#include "ref_set.h"
+ Include dependency graph for ref_set.c:

Go to the source code of this file.

Functions

struct ref_setref_set_new ()
 Create a new reference set.
void ref_set_delete (struct ref_set *s)
 Create a new reference set.
void ref_set_insert (struct ref_set *s, const mpfr_t x, const mpfr_t y)
 Insert a point into a reference set.
bool ref_set_contains (const struct ref_set *s, const mpfr_t x, const mpfr_t y)
 Check if a point is in a reference set.

Detailed Description

Collection of reference coordinates.

Definition in file ref_set.c.

Function Documentation

bool ref_set_contains ( const struct ref_set s,
const mpfr_t  x,
const mpfr_t  y 
)

Check if a point is in a reference set.

Parameters
sThe reference set.
xThe real coordinate of the reference.
yThe imaginary coordinate of the reference.
Returns
true when the set contains the reference, false otherwise.

Definition at line 73 of file ref_set.c.

References ref_set_node::next, ref_set::set, ref_set_node::x, and ref_set_node::y.

Referenced by find_ref(), and fpxx_start().

+ Here is the caller graph for this function:

void ref_set_delete ( struct ref_set s)

Create a new reference set.

Parameters
sThe reference set to delete.

Definition at line 31 of file ref_set.c.

References debug_message, ref_set_node::next, ref_set::set, ref_set_node::x, and ref_set_node::y.

Referenced by render_calculate().

+ Here is the caller graph for this function:

void ref_set_insert ( struct ref_set s,
const mpfr_t  x,
const mpfr_t  y 
)

Insert a point into a reference set.

You should check membership before insertion to avoid duplicates.

Parameters
sThe reference set.
xThe real coordinate of the reference.
yThe imaginary coordinate of the reference.

Definition at line 53 of file ref_set.c.

References debug_message, ref_set_node::next, ref_set::set, ref_set_node::x, and ref_set_node::y.

Referenced by find_ref(), and fpxx_start().

+ Here is the caller graph for this function:

struct ref_set* ref_set_new ( )
read

Create a new reference set.

Returns
A new reference set.

Definition at line 20 of file ref_set.c.

References debug_message.

Referenced by fpxx_start().

+ Here is the caller graph for this function: