Revision: 56718
http://sourceforge.net/p/brlcad/code/56718
Author: brlcad
Date: 2013-08-09 18:40:41 +0000 (Fri, 09 Aug 2013)
Log Message:
-----------
provide static initializers for several structs include rt_tess, mater_info,
db_tree_state, rt_wdb, and rt_g (all just so we can initialize the last one
fully).
Modified Paths:
--------------
brlcad/trunk/include/raytrace.h
Modified: brlcad/trunk/include/raytrace.h
===================================================================
--- brlcad/trunk/include/raytrace.h 2013-08-09 16:28:20 UTC (rev 56717)
+++ brlcad/trunk/include/raytrace.h 2013-08-09 18:40:41 UTC (rev 56718)
@@ -179,8 +179,8 @@
double norm; /**< @brief normal tol */
};
#define RT_CK_TESS_TOL(_p) BU_CKMAG(_p, RT_TESS_TOL_MAGIC, "rt_tess_tol")
+#define RT_TESS_TOL_INIT_ZERO {RT_TESS_TOL_MAGIC, 0.0, 0.0, 0.0}
-
/**
* R T _ D B _ I N T E R N A L
*
@@ -565,6 +565,7 @@
char ma_minherit; /**< @brief mater: DB_INH_LOWER / DB_INH_HIGHER
*/
char *ma_shader; /**< @brief shader name & parms */
};
+#define RT_MATER_INFO_INIT_ZERO { VINIT_ZERO, 0.0, 0, 0, 0, NULL }
/**
@@ -1123,6 +1124,8 @@
struct rt_i * ts_rtip; /**< @brief Helper for
rt_gettrees() */
struct resource * ts_resp; /**< @brief Per-CPU data */
};
+#define RT_DBTS_INIT_ZERO { RT_DBTS_MAGIC, NULL, 0, 0, 0, 0, 0,
RT_MATER_INFO_INIT_ZERO, MAT_INIT_ZERO, 0, BU_AVS_INIT_ZERO, 0, NULL, NULL,
NULL, NULL, NULL, NULL, NULL, NULL }
+
#define TS_SOFAR_MINUS 1 /**< @brief Subtraction encountered above */
#define TS_SOFAR_INTER 2 /**< @brief Intersection encountered above */
#define TS_SOFAR_REGION 4 /**< @brief Region encountered above */
@@ -1347,6 +1350,7 @@
#define RT_CHECK_WDB(_p) BU_CKMAG(_p, RT_WDB_MAGIC, "rt_wdb")
#define RT_CK_WDB(_p) RT_CHECK_WDB(_p)
+#define RT_WDB_INIT_ZERO { {RT_WDB_MAGIC, BU_LIST_NULL, BU_LIST_NULL}, 0,
NULL, RT_DBTS_INIT_ZERO, RT_TESS_TOL_INIT_ZERO, BN_TOL_INIT_ZERO, NULL,
BU_VLS_INIT_ZERO, 0, 0, 0, 0, 0, 0, BU_VLS_INIT_ZERO, BU_OBSERVER_INIT_ZERO,
NULL }
#define RT_WDB_NULL ((struct rt_wdb *)NULL)
#define RT_WDB_TYPE_DB_DISK 2
#define RT_WDB_TYPE_DB_DISK_APPEND_ONLY 3
@@ -1772,7 +1776,9 @@
uint32_t NMG_debug; /**< @brief debug bits for NMG's see
nmg.h */
struct rt_wdb rtg_headwdb; /**< @brief head of database object
list */
};
+#define RT_G_INIT_ZERO { 0, 0, BU_LIST_INIT_ZERO, 0, RT_WDB_INIT_ZERO }
+
/**
* global ray-trace geometry state
*/
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Get 100% visibility into Java/.NET code with AppDynamics Lite!
It's a free troubleshooting tool designed for production.
Get down to code-level detail for bottlenecks, with <2% overhead.
Download for free and get started troubleshooting in minutes.
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits