1 | /* |
---|
2 | * ---------------------------------------------------------------------- |
---|
3 | * RapptureGUI_Init |
---|
4 | * |
---|
5 | * This file contains the function that initializes all of the various |
---|
6 | * extensions in this package. |
---|
7 | * ====================================================================== |
---|
8 | * AUTHOR: Michael McLennan, Purdue University |
---|
9 | * Copyright (c) 2004-2012 HUBzero Foundation, LLC |
---|
10 | * |
---|
11 | * See the file "license.terms" for information on usage and |
---|
12 | * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES. |
---|
13 | * ====================================================================== |
---|
14 | */ |
---|
15 | |
---|
16 | #include <tcl.h> |
---|
17 | #include <tk.h> |
---|
18 | |
---|
19 | #ifdef BUILD_rappture |
---|
20 | #undef TCL_STORAGE_CLASS |
---|
21 | #define TCL_STORAGE_CLASS DLLEXPORT |
---|
22 | #endif |
---|
23 | |
---|
24 | extern Tcl_AppInitProc Rappturegui_Init; |
---|
25 | extern Tcl_AppInitProc RpCanvHotspot_Init; |
---|
26 | extern Tcl_AppInitProc RpCanvPlacard_Init; |
---|
27 | extern Tcl_AppInitProc RpDiffview_Init; |
---|
28 | extern Tcl_AppInitProc RpListbox_Init; |
---|
29 | extern Tcl_AppInitProc RpReadPoints_Init; |
---|
30 | extern Tcl_AppInitProc RpSqueezer_Init; |
---|
31 | |
---|
32 | #ifdef ENABLE_VTK |
---|
33 | extern Tcl_AppInitProc RpDxToVtk_Init; |
---|
34 | extern Tcl_AppInitProc RpPdbToVtk_Init; |
---|
35 | #ifdef ENABLE_VTK_DICOM |
---|
36 | extern Tcl_AppInitProc RpDicomToVtk_Init; |
---|
37 | #endif |
---|
38 | #endif |
---|
39 | |
---|
40 | #ifdef BUILD_Rappture |
---|
41 | __declspec( dllexport ) |
---|
42 | #endif |
---|
43 | |
---|
44 | int |
---|
45 | Rappturegui_Init( Tcl_Interp * interp) |
---|
46 | { |
---|
47 | if (Tcl_InitStubs(interp, "8.4", 0) == NULL) { |
---|
48 | return TCL_ERROR; |
---|
49 | } |
---|
50 | if (Tk_InitStubs(interp, "8.4", 0) == NULL) { |
---|
51 | return TCL_ERROR; |
---|
52 | } |
---|
53 | if (RpDiffview_Init(interp) != TCL_OK) { |
---|
54 | return TCL_ERROR; |
---|
55 | } |
---|
56 | if (RpCanvPlacard_Init(interp) != TCL_OK) { |
---|
57 | return TCL_ERROR; |
---|
58 | } |
---|
59 | if (RpListbox_Init(interp) != TCL_OK) { |
---|
60 | return TCL_ERROR; |
---|
61 | } |
---|
62 | if (RpReadPoints_Init(interp) != TCL_OK) { |
---|
63 | return TCL_ERROR; |
---|
64 | } |
---|
65 | if (RpSqueezer_Init(interp) != TCL_OK) { |
---|
66 | return TCL_ERROR; |
---|
67 | } |
---|
68 | if (RpCanvHotspot_Init(interp) != TCL_OK) { |
---|
69 | return TCL_ERROR; |
---|
70 | } |
---|
71 | #ifdef ENABLE_VTK |
---|
72 | if (RpDxToVtk_Init(interp) != TCL_OK) { |
---|
73 | return TCL_ERROR; |
---|
74 | } |
---|
75 | if (RpPdbToVtk_Init(interp) != TCL_OK) { |
---|
76 | return TCL_ERROR; |
---|
77 | } |
---|
78 | #ifdef ENABLE_VTK_DICOM |
---|
79 | if (RpDicomToVtk_Init(interp) != TCL_OK) { |
---|
80 | return TCL_ERROR; |
---|
81 | } |
---|
82 | #endif |
---|
83 | #endif |
---|
84 | return TCL_OK; |
---|
85 | } |
---|
86 | |
---|