![]() |
SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997 |
|
|
11-21-11, 02:51 PM
|
#1 |
|
Mate
![]() Join Date: Nov 2011
Posts: 53
Downloads: 4
Uploads: 0
|
First off - Great Work!
I apologize if this has been asked (I haven't gone throug the 15 pages of this thread yet). But is it possible to get a GR2 exported into something that Blender can import. I saw that exporting to OBJ is in work. Does that include Bones and meshes? Thanks! EDIT: I do het an error that says: Info header tag value expected to be 0x80000032 When I try to open a Civ5 GR2 file Last edited by Ekmek; 11-21-11 at 03:01 PM. |
|
|
11-21-11, 03:30 PM
|
#2 | |
|
Black Magic
![]() |
Quote:
Right now working on something that I flagged for follow-up that I forgot about. It deals with bone bindings or more specifically mesh to bone bindings. Each mesh is assigned (bound) to a bone in the GR2 files. I went back and reviewed this section of my code and found that I wasn't setting the transform for the mesh before rendering it. So I adjusted the code to set the transform to the bound bone then rendering the mesh and it totally screwed up everything. The meshes were all in the incorrect places. Now I have to figure out how this bone binding is supposed to work
|
|
|
|
11-21-11, 03:54 PM
|
#3 |
|
Black Magic
![]() |
maybe someone will find this interesting:
I coded the GR2 editor/viewer to be able to change parameters in the GR2 file now (transform, inverseworldtransform, rotation, maxproperties, etc.). For a test to see if I have the app working correctly I changed the position of crane01 of the King George V. I set the X position to -1.25 from -0.7. Now my app showed the crane as having moved to the new spot but when I checked in Goblin and GrannyViewer they show it hasn't moved. This tells me that the transform data is only used to derive the inverseworldtransform which is what is used to place the item. Interesting ![]() This also means that everything is flipped as to how I'm presenting it with the app. Crane01 is actually on the right side of the ship vice the left like I render it. Wow. I have to make some major changes... EDIT: went back and looked at GrannyViewer again and noticed that yes everything is flipped from how I'm presenting it but the crane01 was in fact moved to it's new position. This tells me that the transform used when rendering the mesh is the bounded bone transform (rotation and position) * bounded bone inverseworldtransform. Everything is flipped because GrannyViewer is using a left hand coordinate system and I'm rendering with a right handed coordinate system. Last edited by TheDarkWraith; 11-21-11 at 04:16 PM. |
|
|
11-21-11, 04:16 PM
|
#4 | |
|
Grey Wolf
![]() Join Date: Jul 2011
Location: UK
Posts: 877
Downloads: 89
Uploads: 3
|
Quote:
Blimey, sounds a bit |
|
|
|
11-21-11, 04:22 PM
|
#5 |
|
Black Magic
![]() |
now you want to talk about confusing check this out:
I moved crane01 to a new position (X of -1.25 from -0.7) and GrannyViewer showed it as moved to new position. I check Goblin Editor and it shows it as not moved (still in original position). Either the devs didn't fully understand the Granny system or they chose to impose their own way of rendering. To add insult to injury GrannyViewer renders with a left-hand coordinate system and Goblin Editor renders with a right-hand coordinate system... ![]() Now the kicker is how is it actually rendered in game....time to find out...if it renders differently I'm going to pull my hair out! |
|
|
11-21-11, 04:49 PM
|
#6 |
|
Black Magic
![]() |
This is sad, just utterly sad
![]() I changed the position, rotation, scaling, and flags of the crane01 (this mesh is supposedly bound to a bone of the same name) of the King George V and NOTHING happened. GrannyViewer shows all the changes but Goblin Editor shows no changes (everything rendered just as nothing had changed). This means that SH5 uses the GR2 files just for storing mesh data and nothing more I wondered why when I viewed the individual meshes they were already pre-positioned to where they needed to be This means we cannot move meshes around without extracting them, repositioning them in 3D model program, then re-importing them back into the GR2 file. That's nuts.Now the questions begs to be asked, why did they use the Granny system when they don't even use 10% of it's potential? ![]() At least with SH3/4 I could change the position and rotation of meshes in the DAT file and those changes were reflected in game... Bones at least reflect changes made to them but those are only good for waypoints. Talk about a big let down... Now I have to go back and try my version of the app that used the granny2.dll and see what happens... |
|
|
11-21-11, 04:57 PM
|
#7 |
|
Stowaway
Posts: n/a
Downloads:
Uploads:
|
I'd tend to think they got saddled with it but did not have the time to work with it as well as they could have.
![]() To do the Open Bunker I had to move the verts themselves. Same thing on some of SteelVikings stuff I did. Many of the Games I've checked GR2 files on suffer the same problem. The Dev's of many Games never went the extra steps that can be done. Now SWTOR is an interesting use of the Granny System. As is the First Templar.
|
|
01-16-12, 04:03 PM
|
#8 | |
|
Mate
![]() Join Date: Nov 2011
Posts: 53
Downloads: 4
Uploads: 0
|
Quote:
Its great to see your progress. Out of curiousity how hard would it be to make an import/export script for Blender? I figure this might be the quickest way to get all the tools you are looking for. If you are not familar with a blender script I can post one. Thank you for all your hard work. |
|
|
|
01-16-12, 04:08 PM
|
#9 | |
|
Black Magic
![]() |
Quote:
|
|
|
|
01-17-12, 01:32 AM
|
#10 | |
|
Mate
![]() Join Date: Nov 2011
Posts: 53
Downloads: 4
Uploads: 0
|
Quote:
cool, thanks! If I sent you some of the import/export python scripts for obj, nif, and 3ds files would that help? I would post them now (combined its only 110kb) but I dont have priviledges to post attachments yet
|
|
|
|
01-17-12, 01:34 AM
|
#11 | |
|
Black Magic
![]() |
Quote:
|
|
|
|
01-17-12, 09:28 PM
|
#12 | |
|
Mate
![]() Join Date: Nov 2011
Posts: 53
Downloads: 4
Uploads: 0
|
Quote:
cool! here it is: http://www.megaupload.com/?d=WF9GNSBQ |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
