Advertisement
whillothewhisp

gethoudinistring

May 26th, 2025
176
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.31 KB | None | 0 0
  1. static std::string get_houdini_string(HAPI_StringHandle stringHandle)
  2. {
  3.     int nameStrLen;
  4.     HAPI_GetStringBufLength(NULL, stringHandle, &nameStrLen);
  5.     std::vector<char> nameBuf(nameStrLen);
  6.     HAPI_GetString(NULL, stringHandle, nameBuf.data(), nameStrLen);
  7.     std::string name(nameBuf.data());
  8.  
  9.     return name;
  10. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement