*   >> Leitura Educação Artigos >> science >> programação

Fazendo um jogo 3D com Ogre - Carregando um Scene

FirstChildElement ("userDataReference") (?); if (pElement!);} //

anular DotSceneLoader :: processNode (TiXmlElement * XMLNode, SceneNode * pParent) {//Construir nome String nome do nó = m_sPrependNode + getAttrib (XMLNode, "nome");

//Cria o nó cena SceneNode * pNode; if (name.empty ()) {//Vamos Ogre escolher o nome if (pParent) pNode = pParent-> createChildSceneNode (); mais pNode = mAttachNode-> createChildSceneNode (); } Else {//Fornecer o nome, se (pParent) pNode = pParent-> createChildSceneNode (nome); mais pNode = mAttachNode-> createChildSceneNode (nome); } //

Processo de outros atributos id String = getAttrib (XMLNode, "id"); bool isTarget = getAttribBool (XMLNode, "isTarget");

TiXmlElement * pElement;

//posição Processo pElement = XMLNode-> FirstChildElement ("posição") (?); if (pElement) {pNode-> setPosition (parseVector3 (pElement)); pNode-> setInitialState (); } //

rotação Processo pElement = XMLNode-> FirstChildElement ("rotação") (?); if (pElement) {pNode-> setOrientation (parseQuaternion (pElement)); pNode-> setInitialState (); } //

escala Processo pElement = XMLNode-> FirstChildElement ("escala") (?); if (pElement) {pNode-> setScale (parseVector3 (pElement)); pNode-> setInitialState (); } //

lookTarget Processo pElement = XMLNode-> FirstChildElement ("lookTarget") (?); if (pElement) processLookTarget (pElement, pNode);

//Processo trackTarget pElement = XMLNode-> FirstChildElement ("trackTarget") (?); if (pElement) processTrackTarget (pElement, pNode);

//nó Processo (*) = pElement XMLNode-> FirstChildElement ("nó"); while (pElement) {processNode (pElement, pNode); pElement = pElement-> NextSiblingElement ("nó"); } //

entidade Processo (*) = pElement XMLNode-> FirstChildElement ("entidade"); while (pElement) {processEntity (pElement, pNode); pElement = pElement-> NextSiblingElement ("entidade"); } //

luz Processo (*) = pElement XMLNode-> FirstChildElement ("luz"); while (pElement) {processLight (pElement, pNode); pElement = pElement-> NextSiblingElement ("luz"); } //

câmera Processo (*) = pElement XMLNode-> FirstChildElement ("câmera"); while (pElement) {processCamera (pElement, pNode); pElement = pElement-> NextSiblingElement ("câmera"); } //

particleSystem Processo (*) = pElement XMLNode-> FirstChildElement ("particleSystem"); while (pElement) {processParticleSystem (pElement, pNode); pElement = pElement->

Page   <<  [1] [2] [3] [4] [5] [6] [7] [8] [9] [10]  ... >>  >> 
Copyright © 2008 - 2016 Leitura Educação Artigos,https://artigos.nmjjxx.com All rights reserved.