summaryrefslogtreecommitdiff
path: root/indra/llprimitive/llvolumexml.cpp
diff options
context:
space:
mode:
authorXiaohong Bao <bao@lindenlab.com>2011-11-28 11:34:53 -0700
committerXiaohong Bao <bao@lindenlab.com>2011-11-28 11:34:53 -0700
commitfcd232e0fb9ebd18a1d3c967147232912425bc53 (patch)
treebfb7a9213e8a3da483a42cc69f16fa1a9e185b3c /indra/llprimitive/llvolumexml.cpp
parenta375272ff5cabb97593129523d4e326cb3d0fda2 (diff)
parent2851cd519338ef4a1fde15da8d4015ab4380d6cb (diff)
Automated merge with https://bitbucket.org/VirLinden/viewer-development-shining-fixes
Diffstat (limited to 'indra/llprimitive/llvolumexml.cpp')
-rw-r--r--indra/llprimitive/llvolumexml.cpp19
1 files changed, 11 insertions, 8 deletions
diff --git a/indra/llprimitive/llvolumexml.cpp b/indra/llprimitive/llvolumexml.cpp
index f4f9d4d713..bf2297a029 100644
--- a/indra/llprimitive/llvolumexml.cpp
+++ b/indra/llprimitive/llvolumexml.cpp
@@ -34,9 +34,9 @@
//============================================================================
-LLXMLNode *LLVolumeXml::exportProfileParams(const LLProfileParams* params)
+LLPointer<LLXMLNode> LLVolumeXml::exportProfileParams(const LLProfileParams* params)
{
- LLXMLNode *ret = new LLXMLNode("profile", FALSE);
+ LLPointer<LLXMLNode> ret = new LLXMLNode("profile", FALSE);
ret->createChild("curve_type", TRUE)->setByteValue(1, &params->getCurveType());
ret->createChild("interval", FALSE)->setFloatValue(2, &params->getBegin());
@@ -46,9 +46,9 @@ LLXMLNode *LLVolumeXml::exportProfileParams(const LLProfileParams* params)
}
-LLXMLNode *LLVolumeXml::exportPathParams(const LLPathParams* params)
+LLPointer<LLXMLNode> LLVolumeXml::exportPathParams(const LLPathParams* params)
{
- LLXMLNode *ret = new LLXMLNode("path", FALSE);
+ LLPointer<LLXMLNode> ret = new LLXMLNode("path", FALSE);
ret->createChild("curve_type", TRUE)->setByteValue(1, &params->getCurveType());
ret->createChild("interval", FALSE)->setFloatValue(2, &params->getBegin());
ret->createChild("scale", FALSE)->setFloatValue(2, params->getScale().mV);
@@ -63,12 +63,15 @@ LLXMLNode *LLVolumeXml::exportPathParams(const LLPathParams* params)
}
-LLXMLNode *LLVolumeXml::exportVolumeParams(const LLVolumeParams* params)
+LLPointer<LLXMLNode> LLVolumeXml::exportVolumeParams(const LLVolumeParams* params)
{
- LLXMLNode *ret = new LLXMLNode("shape", FALSE);
+ LLPointer<LLXMLNode> ret = new LLXMLNode("shape", FALSE);
- exportPathParams(&params->getPathParams())->setParent(ret);
- exportProfileParams(&params->getProfileParams())->setParent(ret);
+ LLPointer<LLXMLNode> node ;
+ node = exportPathParams(&params->getPathParams()) ;
+ node->setParent(ret);
+ node = exportProfileParams(&params->getProfileParams()) ;
+ node->setParent(ret);
return ret;
}