local_proto.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. #ifndef __LOCAL_PROTO_H__
  2. #define __LOCAL_PHOTO_H__
  3. #include <grass/raster.h>
  4. /* raster_ptr.c: From Huidae Cho ... */
  5. union RASTER_PTR
  6. {
  7. void *v;
  8. CELL *c;
  9. FCELL *f;
  10. DCELL *d;
  11. };
  12. struct RASTER_MAP_PTR
  13. {
  14. RASTER_MAP_TYPE type;
  15. union RASTER_PTR data;
  16. };
  17. int is_null_value(struct RASTER_MAP_PTR buf, int col);
  18. /* End from Huidae Cho */
  19. /* Put all the state infomation into a struct */
  20. struct rr_state
  21. {
  22. char *inraster, *inrcover, *outraster, *outvector;
  23. int use_nulls, docover, fd_old, fd_cold, fd_new;
  24. long nCells, nNulls, nRand, cnCells, cnNulls;
  25. struct RASTER_MAP_PTR nulls, cnulls, buf, cover, min, max, cmin, cmax;
  26. FILE *fsites;
  27. int z_geometry;
  28. int notopol;
  29. };
  30. /* count.c */
  31. void get_stats(struct rr_state *);
  32. /* creat_rand.c */
  33. long make_rand(void);
  34. void init_rand(void);
  35. long make_rand(void);
  36. void init_rand(void);
  37. /* random.c */
  38. int execute_random(struct rr_state *);
  39. /* support.c */
  40. int make_support(struct rr_state *, int, double);
  41. #endif /* __LOCAL_PROTO_H__ */
  42. /* vim: set softtabstop=4 shiftwidth=4 expandtab: */