Loading...
Searching...
No Matches
c_point.c File Reference

Cluster library - Add point. More...

`#include <grass/raster.h>`
`#include <grass/cluster.h>`
Include dependency graph for c_point.c:

Go to the source code of this file.

## Functions

int | I_cluster_point (struct Cluster *C, DCELL *x)
| Adds the point x to the list of data points to be "clustered".
int | I_cluster_begin_point_set (struct Cluster *C, int n)
| Begin point set.
int | I_cluster_point_part (struct Cluster *C, DCELL x, int band, int n)
| ?
int | I_cluster_end_point_set (struct Cluster *C, int n)
| ?

## Detailed Description

Cluster library - Add point.

(C) 2001-2009 by the GRASS Development Team

This program is free software under the GNU General Public License (>=v2). Read the file COPYING that comes with GRASS for details.

Author
  Original author CERL

Definition in file c_point.c.

## Function Documentation

## I_cluster_begin_point_set()

int I_cluster_begin_point_set | ( | struct Cluster * | C,
|  | int | n )

Begin point set.

Parameters

  C | pointer to Cluster structure
  n | ?

Returns
  0 on success
  -1 on error

Definition at line 71 of file c_point.c.

## I_cluster_end_point_set()

int I_cluster_end_point_set | ( | struct Cluster * | C,
|  | int | n )

?

Parameters

  C | pointer to Cluster structure
  n | ?

Returns
  number of points

Definition at line 109 of file c_point.c.

## I_cluster_point()

int I_cluster_point | ( | struct Cluster * | C,
|  | DCELL * | x )

Adds the point x to the list of data points to be "clustered".

The dimension of x must agree with the number of bands specified in the initializing call to I_cluster_begin()

Note: if all values in x are zero, the point is rejected

Returns
  0 ok
  -1 out of memory, point not added
  1 all values are null, point not added

Definition at line 32 of file c_point.c.

References x.

## I_cluster_point_part()

int I_cluster_point_part | ( | struct Cluster * | C,
|  | DCELL | x,
|  | int | band,
|  | int | n )

?

Parameters

  C | pointer to Cluster structure
  x | cell value
  band | band number
  n | ?

Returns
  0 ok
  -1 out of memory, point not added
  1 all values are null, point not added

Definition at line 88 of file c_point.c.

References x.