Archangel35757 Posted January 23, 2014 Author Posted January 23, 2014 So here's the color scheme on the bone skeleton: The purple bones are JA unique bones (i.e., the rtail and ltail bones).The yellow bones are the JO unique bones.The cyan bones are common to both JO-JA skeletons.The pink bones are the motion and hang/hand tag bones.Any other color-scheme suggestions? ...I also fixed the visual discontinuities in the spine bones.
Tempust85 Posted January 23, 2014 Posted January 23, 2014 Looks good but why do you have the effs & the unused facial bones in there? One thing I hated about the JK2 skeleton max file from 10 years ago was all the unused bones made new-to-the-scene modellers (myself included from that time) very confused. We should be making sure such confusion doesn't happen this time around.
Archangel35757 Posted January 23, 2014 Author Posted January 23, 2014 The nub_bones (or "_eff" bones), are used potentially for IK chains... they're also useful for position referencing for some control objects. In my opinion they also help show the end of the fingers. But I could easily put them on their own layer so they could be hidden. I'm debating whether to release just the skeleton-- or the skeleton as part of a simple IK rig... until my complex rig is finished.
Archangel35757 Posted January 23, 2014 Author Posted January 23, 2014 @@DT85 -- Aren't all those facial bones used by JO? I intend to use all of them in my facial rig. You can hide the JO bones if you only want to work with JA or vice versa.
Tempust85 Posted January 23, 2014 Posted January 23, 2014 JO has the same facial bones as JKA, according to JO Kyle.
Archangel35757 Posted January 23, 2014 Author Posted January 23, 2014 @@DT85 -- Those facial bones are generated from the JO Kyle root.xsi, so wouldn't that mean that something has to be weighted to them? IIRC, the JO stormtrooper skeleton has the same bones is JA. I'll take a deeper look at the root.xsi files when I get home from work today.
Tempust85 Posted January 23, 2014 Posted January 23, 2014 Raven used the same skeleton from SOF2 in JO, only with less bones in the end. You'll see all those facial bones from a JO root.xsi present in the SOF2 GLA. The skeleton inside a JO root.xsi may have those bones, but the JO GLA doesn't use them.
eezstreet Posted January 23, 2014 Posted January 23, 2014 That could be due to it encoding it as Unicode. See if you can find something about changing the string into ASCII.
eezstreet Posted January 23, 2014 Posted January 23, 2014 I'm referring to his broken paths in the files. The reason I point this out is because ASCII encoding uses 1 byte per character, and Unicode/UTF-16 uses two bytes. So when you have a byte sequence in Unicode: [0x60 0x00] [0x15 0x00] [0x96 0x00]This might show up as 'abc' (I know for a fact that it doesn't, but just bear with me). But when you convert said stream to ASCII:[0x60] [0x00] [0x15] [0x00] [0x96] [0x00] Which might show up as 'a b c ' depending on how your text editor interprets the 0x00.
Archangel35757 Posted January 24, 2014 Author Posted January 24, 2014 @@DT85 -- So I need to color the unused facial bones another unique color... and put them on a unique layer. But I plan to use all of the facial bones in my rig.
Tempust85 Posted January 24, 2014 Posted January 24, 2014 @@Archangel35757 Sounds good. You could have two max files, one that is used for rigging JO/JKA (without the unused bones) & the other is your rig. @@eezstreet I searched for some conversion code and found it, but it now crashes the plugin when trying to export out an MD3. int main(); { LPCWSTR wstr = subname; int count = wcslen(wstr); char* c = new char[count + 1]; wchar_t* pwchr = const_cast<wchar_t*> (&wstr[0]); for(int j = 0; j < count; ++j) { c[j] = static_cast<char> (*pwchr); pwchr++; } c[count] = '\0'; cout<<c<<endl; return 0; }subname is used to output this kind of string: models/model_directory/model_name.md3 P.S I put that code just above where subname gets written with fwrite. I would have thought it would catch subname BEFORE it gets written and alter it, but I so so suck at coding.
eezstreet Posted January 24, 2014 Posted January 24, 2014 Here's a way easier to do it, assuming you're using C++ (which it looks like you are) #include <string> ... void tostring(const std::wstring& in, std::string& out) { std::string temp(in.begin(), in.end()); out = temp; } And then call it by doing: std::string output; tostring(__YOUR__STRING__VAR__HERE__, output); and then simply use output.c_str() in the fwrite function
Archangel35757 Posted January 24, 2014 Author Posted January 24, 2014 @@Archangel35757 Sounds good. You could have two max files, one that is used for rigging JO/JKA (without the unused bones) & the other is your rig. <truncated...> @@DT85 and @@eezstreet -- My thinking regarding the facial bones is this: All of the bones in the JO root.xsi are (including the unused ones from SOF2) exactly what is needed for a detailed Hi-Def facial rig. The JO/JA bones (since they use the same eight bones) will be color coded differently from the SOF2 bones. The additional SOF2 facial bones will also be on a separate layer (so they can be hidden). The facial rig GUI will have controls for all of the bones-- I can make it where the unique SOF2 bones and controls have an option to be hidden-- for those folks who only want to skin their mesh to the JO/JA bones. Or you don't have to skin your face to any facial bones... (like most released JKA models today-- it's up to the user). But I plan to generate additional facial animations for the major phonemes/visemes (in addition to the standard JKA "TALK" anims)... My goal is to have some kind of lipsync system setup... that generates the rough first pass on lipsyncing.
Tempust85 Posted January 24, 2014 Posted January 24, 2014 @@eezstreet Works like a charm for the filename, but gives out this error when trying to do the texture path: error C2664: 'tostring' : cannot convert parameter 1 from 'WStr' to 'const std::wstring &' It needs to be WStr though. if( tex ) // write out a single 'skin' { // Once we have the filename we mangle it. We search for // 'models' and if found we remove the filename to that part. // Thus if we have "C:/quake3/baseq3/models/mapobjects/texture.tga" // It becomes "models/mapobjects/texture.tga" // otherwise we just leave it. WStr mapname = ((BitmapTex *)tex)->GetMapName(); subname = _tcsstr( mapname, _T("models")); //eezstreet UNICODE to ASCII fix std::string output_file; tostring(mapname, output_file); std::string output_sub; tostring(subname, output_sub); if( !g_smart_paths || subname == NULL ) //fwrite( mapname, 68, 1, file ); // full texture filename //eezstreet UNICODE to ASCII fix fwrite(output_file.c_str(), 68, 1, file ); // full texture filename else //fwrite( subname, 68, 1, file ); // full texture filename //eezstreet UNICODE to ASCII fix fwrite( output_sub.c_str(), 68, 1, file ); // filename from 'models' on. }
Archangel35757 Posted January 24, 2014 Author Posted January 24, 2014 @@eezstreet Works like a charm for the filename, but gives out this error when trying to do the texture path: error C2664: 'tostring' : cannot convert parameter 1 from 'WStr' to 'const std::wstring &' It needs to be WStr though. if( tex ) // write out a single 'skin' { // Once we have the filename we mangle it. We search for // 'models' and if found we remove the filename to that part. // Thus if we have "C:/quake3/baseq3/models/mapobjects/texture.tga" // It becomes "models/mapobjects/texture.tga" // otherwise we just leave it. WStr mapname = ((BitmapTex *)tex)->GetMapName(); subname = _tcsstr( mapname, _T("models")); //eezstreet UNICODE to ASCII fix std::string output_file; tostring(mapname, output_file); std::string output_sub; tostring(subname, output_sub); if( !g_smart_paths || subname == NULL ) //fwrite( mapname, 68, 1, file ); // full texture filename //eezstreet UNICODE to ASCII fix fwrite(output_file.c_str(), 68, 1, file ); // full texture filename else //fwrite( subname, 68, 1, file ); // full texture filename //eezstreet UNICODE to ASCII fix fwrite( output_sub.c_str(), 68, 1, file ); // filename from 'models' on. }Isn't that error complaining that you're trying to assign the address of a parameter to WStr when I think it's expecting a WStr* ???
Archangel35757 Posted January 24, 2014 Author Posted January 24, 2014 @@DT85 -- I pulled up a SoF2 model in Modview (they're a little wierd to work with... .skl files and all)... and you're correct. All of those extra facial bones are in the SoF2 skeleton. Tempust85 likes this
Tempust85 Posted January 24, 2014 Posted January 24, 2014 @@Archangel35757 The line works, just not with the fix. Sorry for hijacking your thread with this, but this info could be handy later on if you port your plugin to 2014. Btw, this error is the last hiccup to overcome before the 3ds Max 2014 MD3 exporter is ready.
Archangel35757 Posted January 24, 2014 Author Posted January 24, 2014 @@DT85 -- I have a similar code snippet getting the texture in my ROFF2 Exporter... using TSTR (not WSTR). But the 3dsMax SDK has methods to convert from WSTR/MSTR to TSTR. I'll post it tomorrow.
Tempust85 Posted January 24, 2014 Posted January 24, 2014 Using TSTR makes no difference. As the error says, I need a user-defined conversion from WStr to const std::wstring but I'm not a coder so I'm stuck.
eezstreet Posted January 24, 2014 Posted January 24, 2014 Try and see if there's a way to convert from WStr to wchar_t*. Use that converted string as the argument. C++ will automatically convert wchar_t* to wstring via implicit casting. Is WStr a class? Chances are you could do something like "theParameter.CStr();" or "theParameter.c_str();"
Tempust85 Posted January 24, 2014 Posted January 24, 2014 The issue is only with the full filename string (starting from "drive letter"), not the stripped filename (starting from "models"). I've fixed up the object names and I'm going to submit the 2014 MD3 exporter. Thanks a lot eezstreet, you were a great help.
Archangel35757 Posted January 24, 2014 Author Posted January 24, 2014 @@DT85 -- glad you got it sorted out... @@DT85, @@Psyk0Sith, @@minilogoguy18, @@eezstreet : Concerning Carcass.exe and Assimilate.exe. So I downloaded your GitHub submission for Assimilate and have it compiling-- I cleaned up the existing warnings. It appears that the version Raven released was 2.1 used by Jedi Outcast (and ST:Voyager). The mouseover help still states ST:Voy (Star Trek:Voyager). The one question I have and would like to know... it seems that Assimilate also supports the 3ds Max native .ASE animation file format. Has anyone attempted to compile a new animation using the .ASE format? That would be huge as well, if we could get that to work... as another alternative to dotXSI. I imagine you'd have to use the version of Carcass from JO as well. I looked at the version of Assimilate released for JKA and it states version 2.5 and setup for JK3. Not sure what they did differently inside the code-- except compile with the JKA anims.h file. I have an idea to combine the JO and JA anims.h file into one massive anims.h and recompile and see how it goes-- also adding "ROOT" to the enum list to eliminate the "BAD:ROOT" notification from Assimilate. Comments?
eezstreet Posted January 24, 2014 Posted January 24, 2014 Erm. All of the JK2 anims should still exist in JKA's anims.h edit: No problem @DT85DT[/member]. Glad I could be of some use somehow. All this talk of model formats is a bit over my head.
Archangel35757 Posted January 24, 2014 Author Posted January 24, 2014 Erm. All of the JK2 anims should still exist in JKA...No, scores & scores were removed... do a side-by-side comparison using Notepad++. But I'm not sure if I should combine or not.
eezstreet Posted January 24, 2014 Posted January 24, 2014 Hmm. I could write a simple Java program to combine the files. Or conversely, use a diff tool like kdiff.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now