Revision: 52928
http://brlcad.svn.sourceforge.net/brlcad/?rev=52928&view=rev
Author: brlcad
Date: 2012-10-09 22:02:16 +0000 (Tue, 09 Oct 2012)
Log Message:
-----------
refactor multiple instances of the string constant to a define.
Modified Paths:
--------------
brlcad/trunk/src/conv/3dm/3dm-g.cpp
Modified: brlcad/trunk/src/conv/3dm/3dm-g.cpp
===================================================================
--- brlcad/trunk/src/conv/3dm/3dm-g.cpp 2012-10-09 21:58:45 UTC (rev 52927)
+++ brlcad/trunk/src/conv/3dm/3dm-g.cpp 2012-10-09 22:02:16 UTC (rev 52928)
@@ -36,6 +36,11 @@
#include "vmath.h" /* BRL-CAD Vector macros */
#include "wdb.h"
+
+/* generic entity name */
+#define GENERIC_NAME "rhino"
+
+
/* typedefs and global containers for building layer hierarchy */
typedef std::map< std::string, std::string> STR_STR_MAP;
typedef std::map< std::string, int> REGION_CNT_MAP;
@@ -341,16 +346,16 @@
bu_strlcpy(name, ON_String(layer_name), sizeof(name));
genName = name;
if (genName.length() <= 0) {
- genName = "rhino";
+ genName = GENERIC_NAME;
}
dump->Print("\n\nlayername:\"%s\"\n\n", name);
} else {
- genName = "rhino";
+ genName = GENERIC_NAME;
}
/* For layer named regions use layer region count
* instead of global region count
*/
- if (genName.compare("rhino") == 0) {
+ if (genName.compare(GENERIC_NAME) == 0) {
genName+=itoa(mcount++);
geom_base = genName.c_str();
} else {
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits