Пример #1
0
 inline hkvProperty(const char* name, const std::vector<hkStringPtr>& value, const char* customType = NULL, hkUint32 flags = 0, const char* szDescription = NULL)
   : m_name(name), m_type(TYPE_ARRAY), m_customType(customType), m_flags(flags), m_description(szDescription), m_icon(NULL)
 {
   size_t numValues = value.size();
   m_array.reserve(numValues);
   for (size_t valueIdx = 0; valueIdx < numValues; ++valueIdx)
   {
     m_array.push_back(hkvVariantValue(value[valueIdx]));
   }
 }
Пример #2
0
void hkvFbxAsset::getInternalProperties(hkvPropertyList& properties, hkvProperty::Purpose purpose) const
{
  int iFlags = (purpose == hkvProperty::PURPOSE_USER_INTERFACE_READ_ONLY) ? hkvProperty::FLAG_READ_ONLY : 0;

  properties.push_back(hkvProperty::groupStart("FBX"));
  properties.back().setDescription("Asset specific properties and settings.");
  {
    if (purpose == hkvProperty::PURPOSE_SERIALIZATION)
    {
      properties.push_back(hkvProperty("FBX Target", m_fbxTarget.getString(), hkvProperty::TYPE_STRING));
      properties.back().setDefaultValue(m_fbxTarget.getStringForAvailableElementsId(0), false);
    }
    else
    {
      properties.push_back(hkvProperty("FBX Target", m_fbxTarget.getAvailableElementsId(),
        m_fbxTarget.getAvailableElementStrings(), iFlags,
        "The FBX target defines how animations inside the FBX file are handled. Select 'Single output' if you want all animation takes to be merged into one output. "
        "Also select this option if you want to create a vmesh or a model file with animations.\n"
        "Select 'Multiple Outputs' if each animation take in the FBX file should have its separate transformation as required by Havok Animation Studio."));
      if (getFbxTarget() != HKV_FBX_TARGET_NONE)
      {
        properties.back().getMetaInfo()[hkvProperty::ENUM_META_CONFIRMATION_MESSAGE] = hkvVariantValue("Changing the 'FBX Target' will reset the output targets, do you want to continue?", false);
      }

      if (m_tagfiles.empty())
      {
        properties.push_back(hkvProperty("INFO", "Transform required.", hkvProperty::TYPE_STRING, hkvProperty::FLAG_READ_ONLY,
          "Please transform the FBX Asset once to generate the list of possible targets."));
      }
    }
    getTagfileArrayProperties(properties, purpose);
  }
  properties.push_back(hkvProperty::groupEnd());

  hkvFilterManagerTransformableAsset::getInternalProperties(properties, purpose);
}