54 m_Number.m_Pointer = NULL;
57 m_bFilteredAlpha =
false;
58 m_bFilteredParams =
false;
61 m_pAlphaFilter = NULL;
230 m_Text = p_functionExpression;
551 switch((
int)p_data_type) {
553 return moText(
"MO_DATA_NUMBER");
556 return moText(
"MO_DATA_NUMBER_CHAR");
559 return moText(
"MO_DATA_NUMBER_INT");
562 return moText(
"MO_DATA_NUMBER_LONG");
565 return moText(
"MO_DATA_NUMBER_DOUBLE");
568 return moText(
"MO_DATA_NUMBER_FLOAT");
571 return moText(
"MO_DATA_NUMBER_MIDI");
574 return moText(
"MO_DATA_FUNCTION");
577 return moText(
"MO_DATA_IMAGESAMPLE");
580 return moText(
"MO_DATA_IMAGESAMPLE_FILTERED");
583 return moText(
"MO_DATA_VIDEOSAMPLE");
586 return moText(
"MO_DATA_SOUNDSAMPLE");
589 return moText(
"MO_DATA_POINTER");
592 return moText(
"MO_DATA_TEXT");
595 return moText(
"MO_DATA_UNDEFINED");
598 return moText(
"MO_DATA_VECTOR2I");
601 return moText(
"MO_DATA_VECTOR3I");
604 return moText(
"MO_DATA_VECTOR4I");
607 return moText(
"MO_DATA_VECTOR2F");
610 return moText(
"MO_DATA_VECTOR3F");
613 return moText(
"MO_DATA_VECTOR4F");
616 return moText(
"MO_DATA_MESSAGE");
619 return moText(
"MO_DATA_MESSAGES");
626 return moText(
"MO_DATA_UNDEFINED");
632 if ( texttype ==
moText(
"MO_DATA_NUMBER") ) {
635 if ( texttype ==
moText(
"MO_DATA_NUMBER_CHAR") ) {
638 if ( texttype ==
moText(
"MO_DATA_NUMBER_INT") ) {
641 if ( texttype ==
moText(
"MO_DATA_NUMBER_LONG") ) {
644 if ( texttype ==
moText(
"MO_DATA_NUMBER_DOUBLE") ) {
647 if ( texttype ==
moText(
"MO_DATA_NUMBER_FLOAT") ) {
650 if ( texttype ==
moText(
"MO_DATA_NUMBER_MIDI") ) {
653 if ( texttype ==
moText(
"MO_DATA_FUNCTION") ) {
656 if ( texttype ==
moText(
"MO_DATA_IMAGESAMPLE") ) {
659 if ( texttype ==
moText(
"MO_DATA_IMAGESAMPLE_FILTERED") ) {
662 if ( texttype ==
moText(
"MO_DATA_VIDEOSAMPLE") ) {
665 if ( texttype ==
moText(
"MO_DATA_SOUNDSAMPLE") ) {
668 if ( texttype ==
moText(
"MO_DATA_POINTER") ) {
671 if ( texttype ==
moText(
"MO_DATA_TEXT") ) {
674 if ( texttype ==
moText(
"MO_DATA_UNDEFINED") ) {
677 if ( texttype ==
moText(
"MO_DATA_VECTOR2I") ) {
680 if ( texttype ==
moText(
"MO_DATA_VECTOR2F") ) {
683 if ( texttype ==
moText(
"MO_DATA_VECTOR3I") ) {
686 if ( texttype ==
moText(
"MO_DATA_VECTOR3F") ) {
689 if ( texttype ==
moText(
"MO_DATA_VECTOR4I") ) {
692 if ( texttype ==
moText(
"MO_DATA_VECTOR4F") ) {
695 if ( texttype ==
moText(
"MO_DATA_MESSAGE") ) {
698 if ( texttype ==
moText(
"MO_DATA_MESSAGES") ) {
711 moDataMessages *dMs = NULL;
743 for(
int c=0;c<(int)dM->Count();c++) {
744 finalMsg+=
";" + dM->Get(c).ToText();
752 for(
int c=0;c<(int)dMs->Count();c++) {
754 for(
int cc=0;cc<(int)Mes.Count();cc++) {
755 finalMsg+=
";" + Mes.Get(c).ToText();
952 return GetGLId( p_cycle, 1.0, p_filterparam);
972 pTF->
Apply( p_cycle, p_fade, p_filterparam);
978 }
else pTexture = this->
Texture();
988 else return pTexture->
GetGLId();
996 return GetGLId( p_tempo, 1.0, p_filterparam);
1017 pTF->
Apply( p_tempo, p_fade, p_filterparam);
1023 }
else pTexture = this->
Texture();
1033 else return pTexture->
GetGLId();
1042 return GetGLId( p_i, 1.0, p_filterparam);
1064 pTF->
Apply( p_i, p_fade, p_filterparam);
1070 }
else pTexture = this->
Texture();
1080 else return pTexture->
GetGLId();
1089 return GetGLId(1.0, p_filterparam);
1118 }
else pTexture = this->
Texture();
1133 return GetGLId( p_mob, p_tempo, 1.0, p_filterparam);
1140 GetGLId( p_mob, NULL, p_fade, p_filterparam );
1162 pTF->
Apply( p_mob, p_tempo, p_fade, p_filterparam);
1168 }
else pTexture = this->
Texture();
1171 if ( (p_tempo != NULL) && (
1181 else return pTexture->
GetGLId();
1195 m_Attribute =
moText(
"");
1209 m_Type = src.m_Type;
1210 m_Index = src.m_Index;
1211 m_CodeName = src.m_CodeName;
1214 m_Attribute = src.m_Attribute;
1235 switch((
int)m_Type) {
1237 return moText(
"FUNCTION");
1270 return moText(
"UNDEFINED");
1275 if (p_value_type_str==
"FUNCTION") {
1277 }
else if (p_value_type_str==
"NUM") {
1279 }
else if (p_value_type_str==
"CHAR") {
1281 }
else if (p_value_type_str==
"INT") {
1283 }
else if (p_value_type_str==
"LONG") {
1285 }
else if (p_value_type_str==
"FLOAT") {
1287 }
else if (p_value_type_str==
"DOUBLE") {
1289 }
else if (p_value_type_str==
"TXT") {
1291 }
else if (p_value_type_str==
"XML") {
1293 }
else if (p_value_type_str==
"LNK") {
1295 }
else if (p_value_type_str==
"MATRIX") {
1314 m_CodeName = p_codename;
1326 sscanf( min,
"%f", &m_Min);
1327 sscanf( max,
"%f", &m_Max);
1345 m_Attribute = p_attribute;
1355 moText fieldSeparation =
",";
1359 if (m_CodeName!=
"") m_FullJSON+= fieldSeparation+
"'cod': '" + m_CodeName +
"'";
1361 m_FullJSON+= fieldSeparation +
"'min': " +
FloatToStr(m_Min);
1362 m_FullJSON+= fieldSeparation +
"'max': " +
FloatToStr(m_Max);
1370 moText fieldSeparation =
" ";
1372 m_FullXML =
"<moValueDefinition ";
1373 m_FullXML+=
"codename='" + m_CodeName +
"'";
1374 m_FullXML+= fieldSeparation +
"type='" +
GetTypeStr() +
"'";
1375 m_FullXML+= fieldSeparation +
"min='" +
FloatToStr(m_Min)+
"'";
1376 m_FullXML+= fieldSeparation +
"max='" +
FloatToStr(m_Max)+
"'";
1377 m_FullXML+= fieldSeparation +
">";
1378 m_FullXML+=
"</moValueDefinition>";
1385 TiXmlDocument m_XMLDoc;
1387 TiXmlEncoding xencoding = TIXML_ENCODING_LEGACY;
1389 m_XMLDoc.Parse((
const char*) p_XmlText, 0, xencoding );
1392 TiXmlElement* definitionNode = m_XMLDoc.FirstChildElement(
"moValueDefinition");
1397 if (definitionNode) {
1398 m_CodeName =
moText( definitionNode->Attribute(
"codename") );
1400 m_Min = atof(
moText( definitionNode->Attribute(
"min") ));
1401 m_Max = atof(
moText( definitionNode->Attribute(
"max") ));
1425 m_ValueDefinition = src.m_ValueDefinition;
1433 m_ValueDefinition.
SetRange(min,max);
1438 m_ValueDefinition.
SetRange(min,max);
1443 m_ValueDefinition.
GetRange(min,max);
1458 m_ValueDefinition.
SetType(p_type);
1467 switch(m_ValueDefinition.
GetType()) {
1477 this->m_ValueDefinition.
SetType( p_ValueType );
1494 m_ValueDefinition.
SetIndex(p_index);
1499 return m_ValueDefinition.
GetType();
1509 return m_ValueDefinition.
GetIndex();
1524 moText fieldSeparation =
",";
1526 m_FullJSON+=
"'d':" + m_ValueDefinition.
ToJSON();
1527 m_FullJSON+= fieldSeparation +
"'v':" +
"'" +
ToText() +
"'";
1534 moText fieldSeparation =
" ";
1535 m_FullXML =
"<moValueBase ";
1536 m_FullXML+= fieldSeparation+
"type='"+
GetTypeStr()+
"'";
1537 m_FullXML+= fieldSeparation+
"value='"+
ToText()+
"'";
1542 m_FullXML+= fieldSeparation+
">";
1544 m_FullXML+=
"</moValueBase>";
1551 TiXmlDocument m_XMLDoc;
1553 TiXmlEncoding xencoding = TIXML_ENCODING_LEGACY;
1555 m_XMLDoc.Parse((
const char*) p_XmlText, 0, xencoding );
1558 TiXmlElement* valueNode = m_XMLDoc.FirstChildElement(
"moValueBase");
1564 moText value =
moText( valueNode->Attribute(
"value") );
1641 valuebase.
SetInt( p_int );
1687 m_List.Remove( p_indexsubvalue );
1692 if (leavefirstone) {
1693 while( m_List.Count()>1 ) {
1703 m_List.Add( valuebase );
1717 valuebase.
SetText( strvalue );
1719 switch(p_valuetype) {
1723 sscanf(
moText(strvalue),
"%i", &tmpInt);
1724 valuebase.
SetInt( tmpInt );
1728 sscanf(
moText(strvalue),
"%li", &tmpLong);
1733 sscanf(
moText(strvalue),
"%c", &tmpChar);
1738 sscanf(
moText(strvalue),
"%f", &tmpFloat);
1743 sscanf(
moText(strvalue),
"%lf", &tmpDouble);
1748 valuebase.
SetFun( strvalue );
1757 valuebase.
SetType( p_valuetype );
1759 m_List.Add( valuebase );
1771 valuebase.
SetText( strvalue );
1776 valuebase.
SetText( strvalue );
1781 valuebase.
SetText( strvalue );
1787 sscanf(
moText(strvalue),
"%i", &tmp2);
1788 valuebase.
SetInt( tmp2 );
1794 sscanf(
moText(strvalue),
"%i", &tmp2);
1795 valuebase.
SetInt( tmp2 );
1801 sscanf(
moText(strvalue),
"%c", &tmp2);
1808 sscanf(
moText(strvalue),
"%li", &tmp2);
1815 sscanf(
moText(strvalue),
"%f", &tmp2);
1822 sscanf(
moText(strvalue),
"%lf", &tmp2);
1830 valuebase.
SetFun( strvalue );
1839 valuebase.
SetText( strvalue );
1844 m_List.Add( valuebase );
1853 m_List = src.m_List;
1859 moText fieldSeparation =
"";
1861 for(
int vbase=0; vbase < (int)m_List.Count(); vbase++) {
1862 m_FullJSON+= fieldSeparation + m_List[vbase].ToJSON();
1863 fieldSeparation =
",";
1871 moText fieldSeparation =
"";
1872 m_FullXML =
"<moValue>";
1873 for(
int vbase=0; vbase < (int)m_List.Count(); vbase++) {
1874 m_FullXML+= fieldSeparation + m_List[vbase].ToXML();
1875 fieldSeparation =
"";
1877 m_FullXML+=
"</moValue>";
1885 TiXmlDocument m_XMLDoc;
1887 TiXmlEncoding xencoding = TIXML_ENCODING_LEGACY;
1889 m_XMLDoc.Parse((
const char*) p_XmlText, 0, xencoding );
1892 TiXmlElement* valueNode = m_XMLDoc.FirstChildElement(
"moValue");
1899 TiXmlElement* valuebaseNode = valueNode->FirstChildElement(
"moValueBase");
1901 while(valuebaseNode) {
1904 TiXmlPrinter printer;
1905 TiXmlNode* NODEDATAXML = valuebaseNode;
1907 NODEDATAXML->Accept( &printer );
1908 vbXML =
moText( printer.CStr() );
1915 valuebaseNode = valuebaseNode->NextSiblingElement(
"moValueBase");
void SetRange(MOfloat min, MOfloat max)
void SetAttribute(moText p_attribute)
void SetMessages(moDataMessages *p_datamessages)
void SetText(moText ptext)
moMathFunction * Fun()
referencias a clases
clase base para una fuente 3d o 2d
void GetRange(MOfloat *min, MOfloat *max)
moValueBase & GetSubValue(MOint p_indexsubvalue=0)
moText GetAttribute() const
virtual ~moValueDefinition()
void SetDouble(MOdouble pdouble)
void SetVector(moVector2d *p_vector2d)
MOdouble LastEval() const
moTextureBuffer * TextureBuffer()
LIBMOLDEO_API moText0 FloatToStr(double a)
moDataType TextToType(moText texttype)
void SetType(moValueType p2_type)
static moValueType ValueTypeFromStr(const moText &p_value_type_str)
virtual MOboolean Init(const moText &p_Expression, moMoldeoObject *p_pMOB=NULL)
void SetCodeName(moText p_codename)
Fija el nombre del código para este valor.
int Set(const moText &p_XmlText)
void SetTexture(moTexture *p_Texture)
void AddSubValue(const moText &strvalue, moValueType p_valuetype)
void SetFun(const moText &p_functionExpression)
void SetLong(MOlonglong plong)
void Apply(MOuint p_i, MOfloat p_fade, const moTextFilterParam &p_params)
void SetSize(MOulong p_DataSize)
moValue & operator=(const moValue &src)
void SetAttribute(moText p_attribute)
int Set(const moText &p_XmlText)
moDataMessages * Messages()
clase de para manejar textos
bool FixType(moValueType p_ValueType)
int Set(const moText &p_XmlText)
void SetNumber(moNumber p_number)
moTexture * GetTexture(MOuint p_idx)
void SetSound(moSound *p_Sound)
void SetIndex(MOint p_index)
moValueBase & operator=(const moValueBase &src)
static void Log(moText p_text)
Escribe un mensaje en el archivo de registro (log)
Buffer de imágenes para video.
MOint GetIndex() const
Devuelve el índice de este valor.
void SetMessage(moDataMessage *p_datamessage)
void SetModel(moSceneNode *p_Model)
void SetTextureFilter(moTextureFilter *p_TextureFilter)
void GetRange(MOfloat *min, MOfloat *max)
void SetType(moValueType p_type)
Fija el tipo de valor, esta función se implementa sólo como atajo a ciertos datos de la definición ...
moDataMessage * Message()
Clase Base para Objetos Moldeo ( moEffect, moIODevice, moResource, moConsole )
clase base para el manejo de una textura
void RemoveSubValues(bool leavefirstone=true)
moTextureIndex * GetDestTex()
void SetVideoBuffer(moVideoBuffer *p_VideoBuffer)
moValueType GetType() const
void Copy(const moData &data)
moText GetTypeStr() const
Devuelve el tipo en formato texto.
moData & operator=(const moData &data)
void SetIndex(MOint p_index)
Fija el índice al que corresponde este valor dentro de la configuración
moText GetCodeName() const
Devuelve un nombre de código en texto fijado por el usuario para este valor.
void SetPointer(MOpointer data, MOulong size)
moTextFilterParam m_pFilterParam
void SetRange(MOfloat min, MOfloat max)
moDefineDynamicArray(moValueIndexes) moDefineDynamicArray(moValueBases) moDefineDynamicArray(moValues) moDefineDynamicArray(moDatas) moDefineDynamicArray(moDataMessages) moData
moText GetCodeName() const
moTextureType GetType() const
virtual MOint GetGLId(moTempo *tempo)
void SetTextureBuffer(moTextureBuffer *p_TextureBuffer)
void SetFont(moFont *p_Font)
LIBMOLDEO_API moText0 IntToStr(int a)
void SetChar(MOchar pchar)
void SetCodeName(moText p_codename)
MOuint GetSubValueCount()
una textura asociada a una animación de cuadros
moTexture * TextureDestination()
if MO_DATA_IMAGESAMPLE source = destination
moTextureIndex * GetSrcTex()
moText GetTypeStr() const
void SetTextureFilterAlpha(moData *p_alpha)
void SetType(moDataType p_DataType)
moText GetAttribute() const
moValueType GetType() const
Devuelve el tipo de valor ,esta función se implementa sólo como atajo a ciertos datos de la definición ...
void SetFloat(MOfloat pfloat)
moValueDefinition & operator=(const moValueDefinition &src)
void SetTextureFilterParam(const moTextFilterParam &p_filterparam)
void RemoveSubValue(MOint p_indexsubvalue)
virtual moText & GetExpression()