~ubuntu-branches/ubuntu/karmic/scilab/karmic

« back to all changes in this revision

Viewing changes to routines/tksci/LAB_gcf.c

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2002-03-21 16:57:43 UTC
  • Revision ID: james.westby@ubuntu.com-20020321165743-e9mv12c1tb1plztg
Tags: upstream-2.6
ImportĀ upstreamĀ versionĀ 2.6

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* Copyright INRIA */
 
2
/* UI generator main routine */
 
3
/* Bertrand Guiheneuf, INRIA 1997 */
 
4
 
 
5
 
 
6
#include "C-LAB_Interf.h"
 
7
 
 
8
 
 
9
#include <math.h>
 
10
#include <stdio.h>
 
11
 
 
12
#include "tksci.h"
 
13
#include "TK_uicontrol.h"
 
14
 
 
15
 
 
16
 
 
17
void LAB_gcf()
 
18
 
 
19
 
 
20
{
 
21
 
 
22
 
 
23
  char MyCommand[2000];
 
24
  char *StrHandle;
 
25
  int Handle;
 
26
 
 
27
  Matrix *MOutputHandle;
 
28
  double *OutputHandle;
 
29
 
 
30
 
 
31
 
 
32
  sprintf(MyCommand, "set MyTmpBertrand [GetGcf];"); 
 
33
     
 
34
 
 
35
 
 
36
Tcl_Eval(TKinterp,MyCommand);
 
37
StrHandle = Tcl_GetVar(TKinterp, "MyTmpBertrand", 0);
 
38
Handle = (int)atoi(StrHandle);
 
39
 
 
40
MOutputHandle = MatrixCreate(1,1,"real");
 
41
OutputHandle = (double *)MatrixGetPr(MOutputHandle);
 
42
*OutputHandle = Handle;
 
43
 
 
44
ReturnParam(MOutputHandle);
 
45
 
 
46
 
 
47
 
 
48
}
 
49
 
 
50
 
 
51
 
 
52
 
 
53
 
 
54
 
 
55
 
 
56
 
 
57
 
 
58
 
 
59
 
 
60
 
 
61
 
 
62