sphore 0.0.1
SPH openGL rendering engine

src/data-column-int-dl.c File Reference

Code for managing data that is to be rendered with column integration. More...

#include "data-column-int.h"
#include "settings.h"
#include <GL/gl.h>
#include <stdlib.h>

Data Structures

struct  _data_column_int
 The internal storage for data to be rendered with column integration. More...

Defines

#define ROOT_3   1.73205f
#define ROOT_3_ON_2   0.866025404f

Functions

data_column_int_tdata_column_int_create (unsigned int n, float *x, float *y, float *z, float *h, float *weight, float *data, float data_min, float data_max)
 Creates a new data object.
void data_column_int_destroy (data_column_int_t *data)
 Frees the memory associated with the given data_column_int_t.
void data_column_int_render (data_column_int_t *ds)
 Renders the given particles.

Detailed Description

Code for managing data that is to be rendered with column integration.

Uses disply lists. Vertex buffer objects may be faster.


Define Documentation

#define ROOT_3   1.73205f
#define ROOT_3_ON_2   0.866025404f

Function Documentation

data_column_int_t* data_column_int_create ( unsigned int  n,
float *  x,
float *  y,
float *  z,
float *  h,
float *  weight,
float *  data,
float  data_min,
float  data_max 
)

Creates a new data object.

Parameters:
[in]nThe number of points.
[in]xThe x coordinantes of the points.
[in]yThe y coordinantes of the points.
[in]zThe z coordinantes of the points.
[in]hThe smoothing length of the particles.
[in]weightThe weight of each particle.
[in]dataThe value of the quantity being integrated at each particle.
[in]data_minThe value of data that will be assigned to the lowest colour in the table.
[in]data_maxThe value of data that will be assigned to the highest colour in the table.
Returns:
A pointer to the new data object.
void data_column_int_destroy ( data_column_int_t ds)

Frees the memory associated with the given data_column_int_t.

Parameters:
[in]dsthe data to be destroyed.
void data_column_int_render ( data_column_int_t ds)

Renders the given particles.

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines