~ubuntu-branches/debian/lenny/fpc/lenny

« back to all changes in this revision

Viewing changes to fpcsrc/packages/extra/gtk2/glib/grand.inc

  • Committer: Bazaar Package Importer
  • Author(s): Mazen Neifer, Torsten Werner, Mazen Neifer
  • Date: 2008-05-17 17:12:11 UTC
  • mfrom: (3.1.9 intrepid)
  • Revision ID: james.westby@ubuntu.com-20080517171211-9qi33xhd9evfa0kg
Tags: 2.2.0-dfsg1-9
[ Torsten Werner ]
* Add Mazen Neifer to Uploaders field.

[ Mazen Neifer ]
* Moved FPC sources into a version dependent directory from /usr/share/fpcsrc
  to /usr/share/fpcsrc/${FPCVERSION}. This allow installing more than on FPC
  release.
* Fixed far call issue in compiler preventing building huge binearies.
  (closes: #477743)
* Updated building dependencies, recomennded and suggested packages.
* Moved fppkg to fp-utils as it is just a helper tool and is not required by
  compiler.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
{*
 
2
 * grand.inc
 
3
 *
 
4
 * depends on gtypes.inc
 
5
 *}
 
6
 
 
7
 
 
8
 
 
9
  type
 
10
    PGRand = pointer;   // check please
 
11
 
 
12
  { GRand - a good and fast random number generator: Mersenne Twister
 
13
     see http://www.math.keio.ac.jp/~matumoto/emt.html for more info.
 
14
     The range functions return a value in the intervall [begin, end).
 
15
     int          -> [0..2^32-1]
 
16
     int_range    -> [begin..end-1]
 
17
     double       -> [0..1)
 
18
     double_range -> [begin..end)
 
19
    }
 
20
 
 
21
  function  g_rand_new_with_seed(seed:guint32):PGRand;cdecl;external gliblib name 'g_rand_new_with_seed';
 
22
 
 
23
  function  g_rand_new:PGRand;cdecl;external gliblib name 'g_rand_new';
 
24
 
 
25
  procedure g_rand_free(rand:PGRand);cdecl;external gliblib name 'g_rand_free';
 
26
 
 
27
  procedure g_rand_set_seed(rand:PGRand; seed:guint32);cdecl;external gliblib name 'g_rand_set_seed';
 
28
 
 
29
  function  g_rand_boolean(rand : PGRand) : gboolean;
 
30
 
 
31
  function  g_rand_int(rand:PGRand):guint32;cdecl;external gliblib name 'g_rand_int';
 
32
 
 
33
  function  g_rand_int_range(rand:PGRand; _begin:gint32; _end:gint32):gint32;cdecl;external gliblib name 'g_rand_int_range';
 
34
 
 
35
  function  g_rand_double(rand:PGRand):gdouble;cdecl;external gliblib name 'g_rand_double';
 
36
 
 
37
  function  g_rand_double_range(rand:PGRand; _begin:gdouble; _end:gdouble):gdouble;cdecl;external gliblib name 'g_rand_double_range';
 
38
 
 
39
  procedure g_random_set_seed(seed:guint32);cdecl;external gliblib name 'g_random_set_seed';
 
40
 
 
41
  function g_random_boolean : gboolean;
 
42
 
 
43
  function g_random_int:guint32;cdecl;external gliblib name 'g_random_int';
 
44
 
 
45
  function g_random_int_range(_begin:gint32; _end:gint32):gint32;cdecl;external gliblib name 'g_random_int_range';
 
46
 
 
47
  function g_random_double:gdouble;cdecl;external gliblib name 'g_random_double';
 
48
 
 
49
  function g_random_double_range(_begin:gdouble; _end:gdouble):gdouble;cdecl;external gliblib name 'g_random_double_range';
 
50