These are chat archives for highfidelity/hifi

18th
Sep 2014
Jeremy
@JeroMiya
Sep 18 2014 05:58
how are enum values in C++ mapped in the JS API? I couldn't figure it out from the Qt documentation. Are they integers? strings? If integers, are the enum values defined somewhere?
Judas
@judasshuffle
Sep 18 2014 11:11
The mesh size options could use a constrain proportions check box.
Andrew Meadows
@AndrewMeadows
Sep 18 2014 14:39
@JeroMiya, I would expect enum values to be integers when exposed to JS since they would be integers in C++. However, most of the enum values in the C++ code are not revealed to JS, only those that have been explicitly exposed (of which I don't know any). Perhaps you could describe what you really want to do: what values would you like to query via JS?
Corey Evans
@whyroc
Sep 18 2014 16:01
Hi, I'm trying to build in visual studio 2010 express, almost there, but running into an error with Linker:
voxels.lib(Tags.obj) : error LNK2019: unresolved external symbol _inflateEnd referenced in function "int __cdecl ungzip(class std::basic_ifstream<char,struct std::char_traits<char> > &,class std::basic_stringstream<char,struct std::char_traits<char>,class std::allocator<char> > &)" (?ungzip@@YAHAAV?$basic_ifstream@DU?$char_traits@D@std@@@std@@AAV?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z)
any pointers? This is when I build the interface project
Corey Evans
@whyroc
Sep 18 2014 16:10
Thank you hifi! looks like an amazing product
David Rowe
@ctrlaltdavid
Sep 18 2014 16:49
@murillodigital Hi .. Latest Windows build 1148 still has the old 2.0.4 Leap.dll instead of the latest 2.1.3 ... Checked with a clean install of Interface, too.
Andrew Meadows
@AndrewMeadows
Sep 18 2014 16:58
@whyroc, it sounds like you're missing a lib dependency... maybe gzip
Joe Large [Omega Heron]
@OmegaHeron
Sep 18 2014 19:31
@whyroc That's a missing zlib error
Thijs Wenker
@thoys
Sep 18 2014 21:39
Corey Evans
@whyroc
Sep 18 2014 22:04
@OmegaHeron yep, that was it..ty! I added {hifilibs} \zlib\lib\ to interface general c++ properties -> Addtitional Include Directories and linker -> General , and {hifilibs} \zlib\lib\zdll.lib to Linker->input ->Additional Dependencies. Nice Loading screen!, now what remains.. how to login? :)
Jeremy
@JeroMiya
Sep 18 2014 23:05
@AndrewMeadows I am writing TypeScript type declarations for the JavaScript API, so I'm looking for all of the mapped enums. or in other words, how do I tell from the c++ code if an enum is mapped to the JavaScript API and how are the enum values exposed? Some of the slotted or invokable methods in the c++ have function arguments that are enum values. In one case I saw some custom mapping code convert the enum to and from a string value, but in other cases I just saw the enum type used as-is in slotted functions in qobject classes without custom script-to/from-qobject mapping code.
David Rowe
@ctrlaltdavid
Sep 18 2014 23:09
Hi. ... Is there a way to get the "base" head position (in C++ code) without the body and head lean applied?
Jeremy
@JeroMiya
Sep 18 2014 23:09
So in those latter cases you would expect the scripts to pass number values in when the c++ function is expecting an enum? If so, does qtscript also define global variables for each enum value? E.g. for EnumName::EnumValue, would it define EnumName.EnumValue as a global variable with the integer value of EnumValue?