#include "LCD_DocGeoUtil.hh"
#include "LCD_DocumentUtil.hh"
#include "LCD_DocManager.hh"
#include "LCD_Document.hh"
Include dependency graph for LCD_DocGeoUtil.cc:

Go to the source code of this file.
Functions | |
| XERCES_CPP_NAMESPACE_USE double | getTotalThickness (DOM_Element shape) |
|
|
Definition at line 278 of file LCD_DocGeoUtil.cc. References LCD_DocumentUtil::convertValue(), LCD_DocumentUtil::firstDesc(), and LCD_DocGeoUtil::getLayerWidth().
00278 {
00279 double tmpValue;
00280 DOM_NodeList list = shape.getElementsByTagName(DOMString("slice"));
00281 DOM_Element tmpElt;
00282 double width;
00283 bool ok;
00284
00285 // Get width due to layers
00286 tmpElt = LCD_DocumentUtil::firstDesc(shape, "layering");
00287 width = LCD_DocGeoUtil::getLayerWidth(tmpElt, true);
00288
00289 // add on width of inner wall, if any
00290 tmpElt = LCD_DocumentUtil::firstDesc(shape, DOMString("iwall"));
00291 if (tmpElt != DOM_Element()) {
00292 ok = LCD_DocumentUtil::convertValue(tmpElt.getAttribute("width"),
00293 &tmpValue);
00294 width += tmpValue;
00295 }
00296
00297 // add on width of outer wall, if any
00298 tmpElt = LCD_DocumentUtil::firstDesc(shape, "owall");
00299 if (tmpElt != DOM_Element()) {
00300 ok = LCD_DocumentUtil::convertValue(tmpElt.getAttribute("width"),
00301 &tmpValue);
00302 width += tmpValue;
00303 }
00304 return width;
00305 }
|
1.3.4