Log in

View Full Version : GR2 Editor/Viewer/Extractor/Importer


Pages : 1 2 3 4 5 [6] 7 8 9 10 11

TheDarkWraith
05-20-12, 03:17 PM
But why the textures and UVW order are change ?

I think I see why:

Before import the mesh has 5 subsets. These subsets use the materials (in numerical subset order):
- CT_BODY_TDC
- CT_Buttons_Levels_Wheels
- CT_Cadrans_TDC
- CT_Cadrans_TDC_Gauges_01
- CT_Book_Map_Letter_TDC_Labels_01

When I look inside the OBJ file from Wings3D I find:
- g tdc_CT_Body_TDC_subset0 (CT_Body_TDC)
- g tdc_CT_Book_Map_Letter_TDC_Labels_subset4 (CT_Book_Map_Letter_TDC_Labels_01)
- g tdc_CT_Buttons_Levels_Wheels_subset1 (CT_Buttons_Levels_Wheels)
- g tdc_CT_Cadrans_TDC_Gauges_subset3 (CT_Cadrans_TDC_Gauges_01)
- g tdc_CT_Cadrans_TDC_subset2 (CT_Cadrans_TDC)

So Wings3D mixed up the subset ordering from 0-4 to 0,4,1,3,2 :doh:

This makes things interesting. Wonder why it did that?

Well I could code something to look for _subsetx in the g entries to match it up to a specific subset :hmmm:

BIGREG
05-20-12, 03:21 PM
yes after import the subset 4 have the texture of the subset 1

subset 2 have this from the 3 :doh:

TheDarkWraith
05-20-12, 03:23 PM
yes after import the subset 4 have the texture of the subset 1

subset 2 have this from the 3 :doh:

The Wings3D AO file has the subsets listed in numerical order (0-4). The non-AO one doesn't. Why? :hmmm:

BIGREG
05-20-12, 03:26 PM
But before the new version all was good :hmmm:

TheDarkWraith
05-20-12, 04:10 PM
But before the new version all was good :hmmm:

Your Wings3D file was different. All the subsets were in numerical order. The one you sent me they are not in numerical order anymore. Did you do something to get them out of numerical order?

TheDarkWraith
05-20-12, 04:14 PM
AO problem fixed with the second importer :yeah: Now looking into a way to match what is read from OBJ file to a particular existing mesh subset...

BIGREG
05-20-12, 04:31 PM
Your Wings3D file was different. All the subsets were in numerical order. The one you sent me they are not in numerical order anymore. Did you do something to get them out of numerical order?

AO problem fixed with the second importer :yeah: Now looking into a way to match what is read from OBJ file to a particular existing mesh subset... :up:

Nothing , i have just import/export

TheDarkWraith
05-20-12, 04:32 PM
Nothing , i have just import/export

Well Wings3D swapped the subset ordering somehow. No worries. I'm adding something that will give the user the option to force subset ordering now :up:

BIGREG
05-20-12, 04:38 PM
So good http://dl.dropbox.com/u/8655607/27.gif

TheDarkWraith
05-20-12, 05:09 PM
So good http://dl.dropbox.com/u/8655607/27.gif

We have success!

http://www.subsim.com/radioroom/picture.php?albumid=553&pictureid=5692

Your Room_CT with the import of the non-AO and AO Wings3D TDC files :yeah: TDC has 3 more verticies than stock courtesy of Wings3D :DL

I'll send you the new Room_CT.GR2 file. I still have just a little more work to do on the new version before I can send it to you. I have to explain how this new force subsets thing works :up:

TheDarkWraith
05-20-12, 06:05 PM
Working with BIGREG has shown that even Wings3D can shuffle around subset ordering. Thus I needed to code in a way to force subset ordering:

http://www.subsim.com/radioroom/picture.php?albumid=553&pictureid=5693

When importing and 'Force subset ordering' is checked the app will (try) and keep the subsets in numerical order as they are read from the OBJ file(s). I'll get to why I say (try) here in a few.

When the app exports mesh data to OBJ files it adds "_subsetx" to the end of every 'g' entry in the OBJ file. 'g' entries signify mesh subsets in the OBJ files. As I've seen from BIGREG's files Wings3D can scramble up the order of the subsets - no longer are they in _subset0 to _subsetx numerical order. Thus is 'Force subset ordering' is checked then the app will rearrange the subsets so that they are in numerical order as they are read from the OBJ file.

If some 'g' entries have "_subsetx" entries and some do not then the app will place all the "_subsetx" entries at the front (numerically lower) and then will place all the non "_subsetx" entries after those as they are found.

BIGREG
05-20-12, 07:55 PM
Well, I can not sleep :yawn:, so I just tried, one word amazing http://dl.dropbox.com/u/8655607/horsie.gif
everything works perfectly http://dl.dropbox.com/u/8655607/happy11.gif

TDW you're a genius http://dl.dropbox.com/u/8655607/this.gif I do not know how you thanked http://dl.dropbox.com/u/8655607/merci.gif

TheDarkWraith
05-20-12, 08:06 PM
Well, I can not sleep :yawn:, so I just tried, one word amazing http://dl.dropbox.com/u/8655607/horsie.gif
everything works perfectly http://dl.dropbox.com/u/8655607/happy11.gif

TDW you're a genius http://dl.dropbox.com/u/8655607/this.gif I do not know how you thanked http://dl.dropbox.com/u/8655607/merci.gif

Glad it's working for you :yeah:

I don't think people understand what kind of power the app has given them with the use of my second importer :DL They now have the ability to import any geometry into an existing mesh - the geometry could have thousands more verticies or could have only a few more, could have many less or just a few less - it doesn't matter as the second importer works with the file's Sentinel to allocate/deallocate space in the GR2 file as needed :yeah:

@BIGREG - you're going to like what I've been working on under the radar here for some time. It's something you asked for a long time ago but couldn't be done until I worked out some things in the app :yep: Hopefully the first test of it will come tomorrow for me :DL

I've been looking closely at the files 3DS Max created (OBJs) and think I might try writing something that can take all these individual objects it defines and create one object with subsets out of it. I started writing something for it already.

Now the next big thing that I'll be working on for the app is creating new meshes. All the required functions are already coded - it's just a 'simple' matter of putting everything together, creating all the new pointers, allocating many 'spaces' in the GR2 file, and telling the file's Sentinel to create a new mesh ;)

CaliEs
05-20-12, 08:06 PM
Well, I can not sleep :yawn:, so I just tried, one word amazing http://dl.dropbox.com/u/8655607/horsie.gif
everything works perfectly http://dl.dropbox.com/u/8655607/happy11.gif

TDW you're a genius http://dl.dropbox.com/u/8655607/this.gif I do not know how you thanked http://dl.dropbox.com/u/8655607/merci.gif
Will there be a screenshot of your current work?

BIGREG
05-20-12, 08:12 PM
:salute: CaliEs

Not yet,i need to redo many things with the new editor
But tomorrow i send screenshot here :03:

CaliEs
05-20-12, 08:20 PM
:salute: CaliEs

Not yet,i need to redo many things with the new editor
But tomorrow i send screenshot here :03:
Good.

BIGREG
05-20-12, 08:31 PM
QUOTE= Glad it's working for you :yeah:

I don't think people understand what kind of power the app has given them with the use of my second importer :DL They now have the ability to import any geometry into an existing mesh - the geometry could have thousands more verticies or could have only a few more, could have many less or just a few less - it doesn't matter as the second importer works with the file's Sentinel to allocate/deallocate space in the GR2 file as needed :yeah: Yes :woot:

@BIGREG - you're going to like what I've been working on under the radar here for some time. It's something you asked for a long time ago but couldn't be done until I worked out some things in the app :yep: Hopefully the first test of it will come tomorrow for me :DL Yes of course :03:

I've been looking closely at the files 3DS Max created (OBJs) and think I might try writing something that can take all these individual objects it defines and create one object with subsets out of it. I started writing something for it already. it would be practical :yep:

Now the next big thing that I'll be working on for the app is creating new meshes. All the required functions are already coded - it's just a 'simple' matter of putting everything together, creating all the new pointers, allocating many 'spaces' in the GR2 file, and telling the file's Sentinel to create a new mesh ;)

Yes ,if we can add meshes ,i can redo the missing knob and needle in sub and more :D
But i don't know is possible to attache a mesh to a bone :06:

TheDarkWraith
05-20-12, 08:35 PM
Yes ,if we can add meshes ,i can redo the missing knob and needle in sub and more :D
But i don't know is possible to attache a mesh to a bone :06:

Attach a mesh to a bone...not following you :06: You have the ability to bind a mesh to a bone in the mesh treeview under the bone bindings entry. Is that what you're talking about?

It will take some time to code in the adding of new meshes. There's so many pointers and 'spaces' that have to be created in the GR2 file for this. I take it one step at a time. Create space for x...save GR2 file...open with Granny Viewer to ensure I didn't break/shred GR2 file...create space y....repeat. Create pointer z...repeat...it's a long and arduous process but the only sure way to detect flaws in my code :yep:

BIGREG
05-20-12, 08:40 PM
You have the ability to bind a mesh to a bone in the mesh treeview under the bone bindings entry. Is that what you're talking about?

Yes for animate the meshes via .sim :D

TheDarkWraith
05-20-12, 08:54 PM
Yes for animate the meshes via .sim :D

Animate the meshes via .sim how :06:

The ability to bind a mesh to a bone that I was talking about only applies to the app. As far as I've been able to tell specifying the bone binding for the mesh in the GR2 file does nothing. I'd love for someone to show me that this is incorrect so I can see how/what/why it's done and it's purpose :yep:

I believe the app let's you specify the bone binding for the mesh (for the GR2 file). Hell I can't remember - I'll have to look at the code in VS and see if I included that or not.

TheDarkWraith
05-21-12, 12:28 AM
@BIGREG: anything look different in the below (besides AO turned off) :06:

http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5695'

I imported your 3DS Max OBJ TDC into Room_CT's TDC :D You didn't send me the 3DS Max TDC AO OBJ files so I couldn't import them and thus had to turn self-illumination rendering off.

Yep, I wrote the converter that takes 3DS Max OBJ files and converts them to 'standard' format :rock:

One 'problem' with the converter - the number of vertices! I tried to optimize it by removing duplicate vertices but that caused rendering problems (due to in the face definitions the vertex was given multiple texture coordinates and only the last one was used). If I didn't optimize it then it rendered correctly. The TDC has 11673 :o vertices now using the 3DS Max files :-? Maybe having 3DS Max optimize the mesh before exporting to OBJ file will be best :yep:

I'll send you v1.1.181.1 for testing. I found some small bugs in the last version I sent you :up:

BIGREG
05-21-12, 02:52 AM
:salute: Bonjour

Quote : You didn't send me the 3DS Max TDC AO OBJ files

Yes ,but the subsim database have a problem,i can not acces my PM :-?

http://dl.dropbox.com/u/8655607/database%20error.jpg

Maybe having 3DS Max optimize the mesh before exporting to OBJ file will be best

:yep: Yes, it would be great :O:

I'll send you v1.1.181.1 for testing. I found some small bugs in the last version I sent you

Heck, I can not access my PM :-?

BIGREG
05-22-12, 04:45 AM
Hi :salute:

@ CaliEs : sorry no screenshots
yet ,i working to redo the texture coordinate for the Periscop base
( But ,Anyway, I can say to the guy who did the graphics, he found his diploma in a lucky dip ! ) :88) :nope: and i am not a expert !

@ TDW : for the moment all work fine :yeah:

Edit : For working use the 3DWings version from ManifoldLab :03: : http://s331378245.onlinehome.us/manifoldlab_releases/
with the original, there are problems (Hide option does not work properly, can not open large meshes ...)

tonschk
05-22-12, 07:31 AM
Thank you a lot :DL BIGREG :sunny: :yeah: :salute: :woot::rock: Thank you very much

Hi :salute:

yet ,i working to redo the texture coordinate for the Periscop base
( But ,Anyway, I can say to the guy who did the graphics, he found his diploma in a lucky dip ! ) :88) :nope: and i am not a expert !

@ TDW : for the moment all work fine :yeah:

BIGREG
05-23-12, 06:46 PM
:salute: Hi

Just a little screenshot (sorry in french) :D

Before :

http://dl.dropbox.com/u/8655607/appercuUVW.jpg

After :

http://dl.dropbox.com/u/8655607/apercu_UVW01little.jpg

TheDarkWraith
05-23-12, 06:56 PM
:salute: Hi

Just a little screenshot (sorry in french) :D

Nice. Can't wait to see an in-game screenshot :yep:

BIGREG
05-23-12, 07:00 PM
Yes, me too, but there are a lot of work to do :D

BIGREG
05-24-12, 07:16 PM
:salute: Hi

Argh ! :damn:

I think i have lost 3 days of work :nope:

I can not more import the mesh in the editor ,that give me this error :

http://dl.dropbox.com/u/8655607/error%20face.jpg

TDW ,i think the problem come when i save en reopen the file with 3Dwings :06:

TheDarkWraith
05-24-12, 07:47 PM
:salute: Hi

Argh ! :damn:

I think i have lost 3 days of work :nope:

I can not more import the mesh in the editor ,that give me this error :

http://dl.dropbox.com/u/8655607/error%20face.jpg

TDW ,i think the problem come when i save en reopen the file with 3Dwings :06:

Open up the file with Notepad++ and go to line number 30685 and see what the problem is. It should be pretty obvious :yep:

BIGREG
05-24-12, 08:12 PM
Here :

http://dl.dropbox.com/u/8655607/error%20face2.jpg

:hmmm:

TheDarkWraith
05-24-12, 08:45 PM
Here :

http://dl.dropbox.com/u/8655607/error%20face2.jpg

:hmmm:

Look at the lines starting at 30688. There are 4 verticies defined! Why? :06:

BIGREG
05-24-12, 09:32 PM
Yes ,and after it's worse :doh:

Here the file : http://dl.dropbox.com/u/8655607/Periscop_3dwings.zip

TheDarkWraith
05-24-12, 10:46 PM
Yes ,and after it's worse :doh:

Here the file : http://dl.dropbox.com/u/8655607/Periscop_3dwings.zip

What app wrote that file? I'm sure it wasn't mine as it can't write 4 verticies in a face definition :hmmm:

BIGREG
05-25-12, 12:02 AM
3dsWings :-? ,But I saved and opened to continue working on it and after, impossible to import :hmmm: :nope:

I tried again, if I import the mesh in 3dwings and I export it: Ok

By cons, if I backup the mesh, I open it again, and exports: Error

BIGREG
05-25-12, 01:56 AM
Ok,I found where does the error, it comes when I edited the textures in 3Dwings (the error with faces)
(that come when i change the allocation of a different texture on some face)
But the error of import / backup / reopening / export is still existing

Edit : Therefore, the error came from the allocation of a texture on a hidden face

TheDarkWraith
05-25-12, 08:51 AM
Ok,I found where does the error, it comes when I edited the textures in 3Dwings (the error with faces)
(that come when i change the allocation of a different texture on some face)
But the error of import / backup / reopening / export is still existing

Edit : Therefore, the error came from the allocation of a texture on a hidden face

So everything is ok then and work continues? :06:

I've been doing some research on the OBJ format and face definitions. I've found:
v x y z w

Polygonal and free-form geometry statement.

Specifies a geometric vertex and its x y z coordinates. Rational
curves and surfaces require a fourth homogeneous coordinate, also
called the weight.

x y z are the x, y, and z coordinates for the vertex. These are
floating point numbers that define the position of the vertex in
three dimensions.

w is the weight required for rational curves and surfaces. It is
not required for non-rational curves and surfaces. If you do not
specify a value for w, the default is 1.0.

NOTE: A positive weight value is recommended. Using zero or
negative values may result in an undefined point in a curve or
surface.

I've also found that face (f) definitions having 4 verticies are sometimes used to define polygons or quads (cubes, boxes). It's akin to a triangle strip. The x,y,z vertices define the first triangle. W, the fourth f definition, would make the second triangle (y,z,w). I'm going to code something into the GR2 Editor/Viewer to try this and see what happens :yep:

BIGREG
05-25-12, 11:35 AM
:salute: Hi

I galley, to allocate materials, just on some faces :stare:
(certainly due to hidden faces, and / or material default)


I've also found that face (f) definitions having 4 verticies are sometimes used to define polygons or quads (cubes, boxes). It's akin to a triangle strip. The x,y,z vertices define the first triangle. W, the fourth f definition, would make the second triangle (y,z,w). I'm going to code something into the GR2 Editor/Viewer to try this and see what happens

Hoping that it will work better :yeah:,but the best will be able to use 3DsMax :D

TheDarkWraith
05-25-12, 12:14 PM
but the best will be able to use 3DsMax :D

You can. The version I sent you will allow you to import 3DsMax files :yep:

BIGREG
05-25-12, 12:20 PM
:yeah: I get try it soon as it happens :woot:

Edit : nothing in PM :06:

TheDarkWraith
05-25-12, 01:58 PM
:yeah: I get try it soon as it happens :woot:

Edit : nothing in PM :06:

The last one I sent you via PM. Do I need to resend it?

BIGREG
05-25-12, 02:30 PM
Yes,nothing in my PM box :hmmm: :cry:

Tomi_099
05-25-12, 09:35 PM
You can. The version I sent you will allow you to import 3DsMax files :yep:

--------:yeah:

Great what you doing.:up:
Could I also in 3D Max test?:ping::rock:

TheDarkWraith
05-26-12, 12:09 AM
--------:yeah:

Great what you doing.:up:
Could I also in 3D Max test?:ping::rock:

PM sent :up:

BIGREG
05-26-12, 01:40 AM
:salute: Hi

Hello

Yippee :woot:, I just try, perfect, really great TDW :yeah:

a huge thanks :yep:

Edit : Just a little problem with the textures:

http://dl.dropbox.com/u/8655607/Probtex.jpg

BIGREG
05-26-12, 02:59 AM
:woot:

Ok, I said nothing :oops: , it was enough to import / export the AO mesh with 3dsMax :D

Yet,all work perfect :rock:

SouriaBasharAkbar
05-26-12, 03:43 AM
sorry i need desperate help, Somebody please help, I detect hydrophone working on surface and notthing works I have mods, installed. I don't understand why are my mods installed wrong spot, does ui-boat not allow to fix bugs? please help

http://i363.photobucket.com/albums/oo72/Soviet23/modsoup-2.jpg

cpj93070
05-26-12, 04:04 AM
Man im so thick till now i didn't even know how to post a reply on threads lol.:yeah::haha::har:

BIGREG
05-26-12, 04:14 AM
http://dl.dropbox.com/u/8655607/optimiz.jpg

Tomi_099
05-26-12, 04:23 AM
:salute: Hi

Hello

Yippee :woot:, I just try, perfect, really great TDW :yeah:

a huge thanks :yep:

Edit : Just a little problem with the textures:

http://dl.dropbox.com/u/8655607/Probtex.jpg

---------------------------

---Y..LOOK THIS !!

http://www.subsim.com/radioroom/showthread.php?p=1338094#post1338094



http://img706.imageshack.us/img706/3050/resultm.jpg


You have this problem!

Your texture is o.k

http://www.subsim.com/radioroom/showpost.php?p=1341809&postcount=1313


Test it so !!

Export your model (obj) ..and the same model import /export ..(2x) (GR2Editor .TDW /
or (2x) S3D (Skwas ) and then in GR2Editor)
Test your result!

Do not forget the 3D settings in the export-Max! ..befor..

http://i251.photobucket.com/albums/gg307/Nisgeis/SubSim/Step4.jpg

UNstichit ..ALL..Normals above !!

BIGREG
05-26-12, 04:43 AM
Merci Tomi_099 :03:

Yes,i have found :yep:

Thank,for the link , you have make a amazing work for the VIIa http://dl.dropbox.com/u/8655607/drool.gif http://dl.dropbox.com/u/8655607/tongue.gif

Tomi_099
05-26-12, 05:54 AM
PM sent :up:


---------

GREAT :up:
A GREAT JOB you've done!:yeah:
An enormous respect!:salute:

TheDarkWraith
05-26-12, 08:43 AM
---------

GREAT :up:
A GREAT JOB you've done!:yeah:
An enormous respect!:salute:

I expect to see some screenshots from you soon :yep:

In regards to the 4 vertices found in the face definition (f) that BIGREG posted, should I code the app to treat those as a triangle fan or simply keep throwing the error that it currently does? If the face definition includes more than 4 vertices, once again interpret as triangle fan or throw error? :hmmm:

BIGREG
05-26-12, 11:34 AM
:salute: Hi

Thank you again for this new version :yep: TDW :yeah:

In regards to the 4 vertices found in the face definition (f) that BIGREG posted, should I code the app to treat those as a triangle fan or simply keep throwing the error that it currently does? If the face definition includes more than 4 vertices, once again interpret as triangle fan or throw error? :hmmm:

For me, I would go for the triangles fan solution ,but i am not an expert :know:

BIGREG
05-27-12, 01:15 PM
:salute: Hi

I have try the new version,

But, see, there is a problem with the export/import of AO :-?
I tried exporting / importing the base of the periscope AO without opening/modifying and load both with AO option checked

Result :

Everything becomes dark on some side, and viewing angle in goblin, and ingame

Edit:Have face error, if i try to modify the UVW with 3Dwings

TheDarkWraith
05-27-12, 04:01 PM
:salute: Hi

I have try the new version,

But, see, there is a problem with the export/import of AO :-?
I tried exporting / importing the base of the periscope AO without opening/modifying and load both with AO option checked

Result :

Everything becomes dark on some side, and viewing angle in goblin, and ingame

Edit:Have face error, if i try to modify the UVW with 3Dwings

What happens if you export the AO and then immediately reimport it back into the app? Is everything ok or is that when the problem appears?

BIGREG
05-27-12, 04:16 PM
Yes the problem appear when i reimport immediately the mesh :hmmm:
that seem the light is not good render :doh:
and i have try to move the UVW to reorganize ,with 3dwings but i have face error when i reimport

TheDarkWraith
05-27-12, 05:26 PM
Yes the problem appear when i reimport immediately the mesh :hmmm:
that seem the light is not good render :doh:
and i have try to move the UVW to reorganize ,with 3dwings but i have face error when i reimport

Send me the file you are loading into the app, tell me what you were exporting, and I'll fire up VS and see what's going on :up:

BIGREG
05-27-12, 05:55 PM
I'm trying to see where it comes from, I just tried with 3Dsmax and miraculously :o , I succeeded :woot:, but I'm not sure how I managed that :oops::doh:
I must try again, soon as I find, with certainty :yep:

For the mesh is Periscope_O_Base, in conning tower
just trying to export it and import it with the AO, and looks into goblin

By cons, there is some problem to modify the UVW with 3DsMax

TheDarkWraith
05-27-12, 06:47 PM
I'm trying to see where it comes from, I just tried with 3Dsmax and miraculously :o , I succeeded :woot:, but I'm not sure how I managed that :oops::doh:
I must try again, soon as I find, with certainty :yep:

For the mesh is Periscope_O_Base, in conning tower
just trying to export it and import it with the AO, and looks into goblin

By cons, there is some problem to modify the UVW with 3DsMax

I exported it and re-imported it back in scrict and got an error :o Number of subsets defined error :shifty: I'm looking into it :up:

A loose import works fine.

BIGREG
05-27-12, 06:58 PM
I have see after export/import with 3dsMax -> import/export with editor and
import with 3dwings ,that the all faces are break (no more welded in elements) -> result lot of vertices and edges :dead:
same when i export the mesh optimized with 3dsmax

TheDarkWraith
05-27-12, 07:10 PM
I have see after export/import with 3dsMax -> import/export with editor and
import with 3dwings ,that the all faces are break (no more welded in elements) -> result lot of vertices and edges :dead:
same when i export the mesh optimized with 3dsmax

I noticed that 3DS Max breaks all the vertices. It appears that 3DS Max takes all the vertices that are bowties and breaks them apart.

Found the error in the app related to strict import and fixed it. Sending you updated version here in a few :up:

I saw no errors in AO map when exported and then immediately re-imported back in using strict or loose import.

BIGREG
05-27-12, 07:16 PM
I saw no errors in AO map when exported and then immediately re-imported back in using strict or loose import.
have you try to see with goblin ?

edit : i have found that : http://www.gamefront.com/files/21735401/BasicLoadingTutorial.zip on this forum http://forum.xentax.com/viewtopic.php?f=16&t=1805&start=75

TheDarkWraith
05-27-12, 07:17 PM
have you try to see with goblin ?

No I didn't, I'll take a look now :up:

TheDarkWraith
05-27-12, 07:25 PM
have you try to see with goblin ?

edit : i have found that : http://www.gamefront.com/files/21735401/BasicLoadingTutorial.zip on this forum http://forum.xentax.com/viewtopic.php?f=16&t=1805&start=75

Just tried a strict import and everything ok :up:
Just tried a loose import and diffuse and AO screwed up :o Looking into why now :shifty:

TheDarkWraith
05-27-12, 07:46 PM
Just tried a strict import and everything ok :up:
Just tried a loose import and diffuse and AO screwed up :o Looking into why now :shifty:

I don't know why Goblin has a problem with the loose imported file. When I reload it with app it renders and looks fine. I can't find anything wrong with the code.

The big question is how does it look in game? Have you tried that? It might be that Goblin has a problem :yep:

BIGREG
05-27-12, 07:52 PM
Ingame is same :-?

yet i try to modify the UVW ,but i have error with 3dwings and with 3dsmax that don't work ?!? the material is good render ,when i reload it with 3dwings is ok ,but after import in editor,no change :doh:

TheDarkWraith
05-27-12, 07:56 PM
Ingame is same :-?

yet i try to modify the UVW ,but i have error with 3dwings and with 3dsmax that don't work ?!? the material is good render ,when i reload it with 3dwings is ok ,but after import in editor,no change :doh:

Hold on, I might have found a bug in the second importer...

BIGREG
05-27-12, 07:58 PM
:salute: Great that you've found

TheDarkWraith
05-27-12, 08:13 PM
:salute: Great that you've found

Yes there was a definite problem in the second importer! If you did a loose import and had import AO checked then the normal data was not being written to the verticies (it was 0!). This problem has been fixed :up:

Now what I have noticed is the exporter must be clipping the normals somehow :hmmm: When I turned lighting on I had very hard edges where there was no light. Didn't matter which importer (strict or loose) I used. I'm looking into this now :up:

EDIT:

correction I only had hard edges with the second importer (loose import). So exporter is fine is the second importer that still has a bug...

TheDarkWraith
05-27-12, 09:13 PM
Ok, the hard edges make sense now. Reason for them is because when using the second importer (loose import) the binormal, tangent, bone indicies, and bone weights are not being set! When I switched rendering to fixed-function the hard edges disappeared. This is what clued me into the missing data.

I'll have the second importer calculate the binormal and tangent data so at least that data is set. The bone weights and bone indicies I'm not sure how we are going to overcome that data (for those meshes that use it - would be only for skeletal skin mesh data) :hmmm:

TheDarkWraith
05-28-12, 12:51 AM
Starting with v1.1.186.1 you have the ability to calculate (or re-calculate) the tangent and binormal data (if the mesh has it). This data is lost when doing a loose import unless the calculate tangent and binormals checkbox is checked on the import page (it's calculated)

http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5703

The Mesh tab's File box now has a Calculate button which will re-calculate the tangents and binormals of the selected mesh in the mesh treeview (provided the mesh has normal data and either tangent or binormal data or both).

:|\\

BIGREG
05-28-12, 01:26 AM
:salute: Hi

Impeccable with 3Dwings :yeah:

Test in progress with 3DsMax

BIGREG
05-28-12, 02:34 AM
With 3DsMax

Export 3Dsmax and import without AO (no optimized option) : Problem texture (not required)

Export 3Dsmax and import with AO "the two objects" (no optimized option) : OK
But... the UVW modify and the allocation of material (by element) don't work in editor,but that work (not perfect) if i open the .obj in 3Dwings :doh:

I have try with all optimize export option enable : Same result ;)

For the AO render : OK :yeah:

Edit :

http://dl.dropbox.com/u/8655607/LittleBug.jpg

BIGREG
05-28-12, 03:57 AM
http://dl.dropbox.com/u/8655607/LittleBug2.jpg

:haha::har:

but practical to make labels :D

TheDarkWraith
05-28-12, 08:26 AM
Everything is working good or there is a problem in the app? It's hard for me to discern what you are implying/saying :06:

BIGREG
05-28-12, 09:41 AM
:salute: Hi

With 3DWings all is OK ,3dwings 3 does not add more vertices :yeah: and UVW work great (material allocation/location) :woot:
Just with 3DsMax the material allocation and location don't work in editor :hmmm:

Here is a glimpse :O:

http://dl.dropbox.com/u/8655607/VueAP.jpg

to be continued ....

If someone have conning tower photos :06:, He is welcome :yep:
But,I think the conning tower was poorly done, given the limited picture I hold :-?

Edit : i have try to subdivide faces ,but that give me faces errors when i import :hmmm:

Tomi_099
05-28-12, 09:53 AM
BIGREG..BIGREG.BIGREG..BIGREG..BIGREG..BIGREG..BIG REG!!!

..THIS IS THE BEST NEWS TODAY !!:yeah:

This is the best message for SH5 .. it is finally! a breakthrough!:up:
Great ..
can you describe you and your act for all import modder! :yeah:

-------------

Please BIGER SEND ME YOUR ( inport) FILES I MEKET TEST IT WITH 3D-MAX ( THANKS A LOT)!!

BIGREG
05-28-12, 10:25 AM
Thank Tomi

But congratulations, it's for TDW, it is he who has done everything :yep:

You need just export with the editor and open it with 3DWings
(Attention !, there is a risk of error face with the default material ,when selecting in 3Dwings, i think...)
You don't need export/import the AO (But you need import in loose mod and uncheck AO when importing)
For the material you can just use this one present in the mesh,But we can change the material after with the editor :03:
For the allocation of material, although applied to a full element (not a face) same to change the position of UVW
You can move and/or transform all vertices/faces :rock:
For adding vertices/faces that don't work currently with 3Dwings(still work for TDW) :D

Voila :salute:

I get send you my last file

BIGREG
05-28-12, 10:43 AM
Everything is working good or there is a problem in the app? It's hard for me to discern what you are implying/saying :06:

Idem for me :D ,the problem to resolve is when i importing after 3DsMAX the Material allocation/UVW location don't work :hmmm:

TheDarkWraith
05-28-12, 12:46 PM
Idem for me :D ,the problem to resolve is when i importing after 3DsMAX the Material allocation/UVW location don't work :hmmm:

What do you mean? I don't understand :06: There is a problem with the app when importing 3DsMax files?

BIGREG
05-28-12, 12:52 PM
Yes when i make change ,that have no effect after import :hmmm:
But if i open the file with 3Dwings all was good exported from 3dsMax :doh:

TheDarkWraith
05-28-12, 01:23 PM
Yes when i make change ,that have no effect after import :hmmm:
But if i open the file with 3Dwings all was good exported from 3dsMax :doh:

So you're saying that there's something wrong with the second importer when reading 3DsMax exported files? I'll need to see 3DsMax export files of before and after change so I can see what's going on in VS :yep:

BIGREG
05-28-12, 01:52 PM
Here the Perisope Base exported from 3DsMax (i have change the material of the plate behind the interuptor) : http://dl.dropbox.com/u/8655607/Periscope_O_base_3DsMax.zip

TheDarkWraith
05-28-12, 01:57 PM
Here the Perisope Base exported from 3DsMax (i have change the material of the plate behind the interuptor) : http://dl.dropbox.com/u/8655607/Periscope_O_base_3DsMax.zip

I don't know where that spot is - can you show me a screenshot of where the change is? And a shot in Wings3D of what it's supposed to look like?

BIGREG
05-28-12, 02:03 PM
http://dl.dropbox.com/u/8655607/plaque.jpg

Try to open it with 3DWings :03:

TheDarkWraith
05-28-12, 02:10 PM
What do you see is wrong when you open it up with my app? I don't see anything that strikes me as wrong :hmmm:

BIGREG
05-28-12, 02:12 PM
Moment , i think i have send you a bad file ,wait a minute i send a new one :oops:

TheDarkWraith
05-28-12, 02:13 PM
Try to open it with 3DWings :03:

Can I see the exported OBJ files from Wings3D for this change?

BIGREG
05-28-12, 02:32 PM
This one have the texture :03: : http://dl.dropbox.com/u/8655607/Periscope_3DsMax.zip

http://dl.dropbox.com/u/8655607/Differ.png

Tomi_099
05-28-12, 02:40 PM
I have this Problem !!:hmmm:

http://img442.imageshack.us/img442/9874/46509818.jpg (http://imageshack.us/photo/my-images/442/46509818.jpg/) Uploaded with ImageShack.us (http://imageshack.us)

TheDarkWraith
05-28-12, 02:43 PM
This one have the texture :03: :

the dial's face has changed, that's all? I think I see why you think the app is in error. Currently the app will not set new materials for what it imports - it merely reads the data from the file. I haven't coded in the ability to see if the mtrl referenced in the OBJ file (and thus the MTL file's definition of it's physical file) exists and if so to set the subset's material to it (or create a new material and then set the subet's material to it)

TheDarkWraith
05-28-12, 02:45 PM
I have this Problem !!:hmmm:

[IMG]

What does the error say in English? I don't read German :DL

I'll need to see the file you were trying to import, what kind of import you were trying (strict or loose), what mesh you were trying to import into, and what GR2 file you had opened :yep:

BIGREG
05-28-12, 03:06 PM
When you import from 3DsMax ,you need to import export the AO in 3DsMax and check the option in editor to load both (but in loose mod)

BIGREG
05-28-12, 03:07 PM
the dial's face has changed, that's all? I think I see why you think the app is in error. Currently the app will not set new materials for what it imports - it merely reads the data from the file. I haven't coded in the ability to see if the mtrl referenced in the OBJ file (and thus the MTL file's definition of it's physical file) exists and if so to set the subset's material to it (or create a new material and then set the subet's material to it)

Not new material assigned this is the original,but 3dsmax export the map in the folder "Maps"

TheDarkWraith
05-28-12, 03:46 PM
Not new material assigned this is the original,but 3dsmax export the map in the folder "Maps"

ah, so you're saying that the app didn't read the new map exported out by 3DsMax?

BIGREG
05-28-12, 04:27 PM
No the texture are present after the import ,but no change
The editor does not assign the material (texture) that I modified on the panel behind the button with 3dsMax and ditto when I change the location of UVW
in the previous view (Post:#1339) the editor in the middle shows that it has not changed the texture, while in 3DsMax when exporting it's ok, as well that after import into 3Dwings

TheDarkWraith
05-28-12, 04:31 PM
No the texture are present after the import ,but no change
The editor does not assign the material (texture) that I modified on the panel behind the button with 3dsMax and ditto when I change the location of UVW
in the previous view (Post:#1339) the editor in the middle shows that it has not changed the texture, while in 3DsMax when exporting it's ok, as well that after import into 3Dwings

I see a reason for this. I never coded in the reading of the mtl file :o :damn: I'm writing that code now :up:

BIGREG
05-28-12, 04:32 PM
:O::yeah:

Tomi_099
05-28-12, 04:53 PM
:O::yeah:

:rock:

TheDarkWraith
05-28-12, 07:59 PM
Somehow I totally overlooked coding in the reading of the MTL file in every version released to date :o That has since been taken care of in v1.1.188.1.

v1.1.188.1 also now writes the material's emissive to the MTL file on export (I overlooked that one also!)

Since SH5 does not use seperate maps for ambient, diffuse, or specular but instead uses one map for all three you should ensure your OBJ files have map_Ka, map_Kd, and map_Ks all specifying the same texture. If you don't then the texture read for map_Ks is what will be 'given' to mesh's subset's material.

When importing and you elect to import diffuse data and your MTL files reference textures for the maps and those maps are found then the app will assign those textures temporarily to the mesh's subset's material. I say temporarily because the material's pointer is not changed. All the material is told to do is replace it's current texture with the new one. Thus rendering is then done with the new texture. So if you save after importing the material's texture WILL NOT be changed in the GR2 file.

The material's properties WILL be changed. The ambient, diffuse, specular, and emissive colors will be updated in the material. The Ns value will also be updated. Thus if a save is done after importing these material properties will be saved to the GR2 file.

A new option has been added (Edit-->Options-->Camera-->Reset camera to default position on last file closed). If checked then the camera will be reset when the last opened file is closed. If not checked then the camera will stay where it is when last file is closed (maintains position and orientation).

:|\\

KarlKoch
05-29-12, 01:28 AM
I have this Problem !!:hmmm:

http://img442.imageshack.us/img442/9874/46509818.jpg (http://imageshack.us/photo/my-images/442/46509818.jpg/) Uploaded with ImageShack.us (http://imageshack.us)[/IMG]

Error says Index is out of bounds. Must not be negative and smaller as listing.

BIGREG
05-29-12, 01:49 AM
:salute: Hi

Tomi send me the file to see what happen :yep:

TDW with the version 1.1.188.1
I have all the time errors (lack Ks in the MTL) with 3dWings and 3dsMax :hmmm:
But one thing good that is the export in subset (element) ,yet in 3DWings the selection by element work (not more the all object selected) :rock:
other good thing the vertices/faces etc.. numbers exported are the same when i exporting with 3dsmax or 3dwings :yeah:

Edit :

I just tried to understand how the AO works in wings3d, But I'm not about to have all understood :doh::88)
So I tried the function, it adds an object to me (a bulb:http://www.gif-anime-gratuit.com/gif-anime-gratuit/objet/ampoules/ampoules005.gif) in my list of geometry and material (editable: texture, color etc ...)
But can not assign or pair it with the mesh. :hmmm:
i have try to export/importing But i have the MTL error :shifty:

Quick question: Why, I have this sacred "default material" in wings3d ?
Will not do this AO !?!? , Which would be already present ? , But not recognized as AO, but as a material ? other is just for the hidden faces ?

In other words, is there way to have the materials and the AO, included in one. OBJ ? :D

Into 3dsmax ,i have found how to add AO and the import works ,But dito as the previous version,the material change don't work ...

TheDarkWraith
05-29-12, 06:27 AM
TDW with the version 1.1.188.1
I have all the time errors (lack Ks in the MTL) with 3dWings and 3dsMax :hmmm:
But one thing good that is the export in subset (element) ,yet in 3DWings the selection by element work (not more the all object selected) :rock:
other good thing the vertices/faces etc.. numbers exported are the same when i exporting with 3dsmax or 3dwings :yeah:

What exactly does the error say? I used your 3DsMax files as test files and was able to load them with no errors.

As far as your questions about Wings3D I don't know the answer. I know just enough about Wings3D to be dangerous with it and that's it :DL

TheDarkWraith
05-29-12, 06:57 AM
Error says Index is out of bounds. Must not be negative and smaller as listing.

I wonder what he did to get that error :06: I'd like to know so I can gracefully handle it :yep:

BIGREG
05-29-12, 07:07 AM
:salute: Sorry

4 hours of tutorials later ... I believe that. Obj can contain all the data
Here is a link to examples (Use as a milk cow :D ): http://www.download.lyndondaniels.com/ranchers/

Edit : Last version repport

3DsMax: Still this problem of Material Change, nothing to do with 3DsMax, the changes do not appear with the editor :-?, but well under Wings3D :hmmm:

Wings3D : All work pretty ,But in the previous version, the selection by element which work well is no longer the case.

TheDarkWraith
05-29-12, 08:15 AM
Edit : Last version repport

3DsMax: Still this problem of Material Change, nothing to do with 3DsMax, the changes do not appear with the editor :-?, but well under Wings3D :hmmm:

Wings3D : All work pretty ,But in the previous version, the selection by element which work well is no longer the case.

3DsMax: Send me all the files for this - the GR2 file and all your OBJs and MTLs. Give me a step by step procedure of what you are doing so I can duplicate it so I can see what's going on.

Wings3D: What do you mean by selection by element?

I'm sending you another version, 1.1.190.1, as I just found a Wings3D OBJ file that contains multiple objects in it so I had to write a converter to convert the multiple objects into a single object (like I did with 3DsMax)

TheDarkWraith
05-29-12, 08:32 AM
I took the last archive you sent me with the OBJs and MTL files from 3DsMax and edited one of the jpg files in Photoshop to see if the app was actually applying the new textures called for in the MTL files:

http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5705

I did a loose import of the Periscope base from the files you sent me. This tells me the app is reading the MTL files correctly and is applying the new textures :hmmm: I'm really puzzled as to why your new material is not showing.

Was the change you made to the AO or to the diffuse? I need the GR2 file you are currently using to do a correct import and to be able to see what you are seeing.

BIGREG
05-29-12, 08:47 AM
3DsMax: Send me all the files for this - the GR2 file and all your OBJs and MTLs. Give me a step by step procedure of what you are doing so I can duplicate it so I can see what's going on.

Wings3D: What do you mean by selection by element?

I'm sending you another version, 1.1.190.1, as I just found a Wings3D OBJ file that contains multiple objects in it so I had to write a converter to convert the multiple objects into a single object (like I did with 3DsMax)

My step

With all new editor version a make a new export with a original file
exporting the both (with AO)

3DsMax

-> import the .obj in 3dsmax ,select some faces and assign an other existing material -> export (no option checked)
->import the AO and export (to have the same vertices )
->import in editor in loose mod with AO

Wings3D

-> Same with 3DsMax :yep:

For selecting : you can select by vertices,faces,edge and element in the previous version ,not the all mesh was selected,but only the subset :rotfl2:

TheDarkWraith
05-29-12, 08:59 AM
My step

With all new editor version a make a new export with a original file
exporting the both (with AO)

3DsMax

-> import the .obj in 3dsmax ,select some faces and assign an other existing material -> export (no option checked)
->import the AO and export (to have the same vertices )
->import in editor in loose mod with AO

Wings3D

-> Same with 3DsMax :yep:

For selecting : you can select by vertices,faces,edge and element in the previous version ,not the all mesh was selected,but only the subset :rotfl2:

Now it makes sense. The file exported from Wings3D or 3DsMax with the changes is probably identical to the file exported from Wings3D or 3DsMax with no changes. Try it and see. This would explain why the app shows no changes :yep:

I believe that in order for those kinds of changes you are making to persist they have to be placed into a new subset. Think about it: you asked 3DsMax to just change the rendering material for some faces - the texture coordinates are the same. There would need to be new entries in the OBJ file denoting the material for these changed faces and the vertices, texture coordinates, and face definitions for them also. The app will currently not allow you to add/remove subsets.

BIGREG
05-29-12, 09:22 AM
and why :06: that work with wings3D :doh:

TheDarkWraith
05-29-12, 09:28 AM
and why :06: that work with wings3D :doh:

Those files you sent me I loaded into Wings3D and saw no change (rendered exactly like the app showed). Maybe you didn't send me the correct files? :hmmm:

BIGREG
05-29-12, 09:48 AM
New pm with the file from the last version :03:

You can see the mesh from Wings3D with diffuses is not optimized ,but this one with AO is optimized :doh: ,this is the first time ,that make that with Wings :88)

TheDarkWraith
05-29-12, 10:35 AM
New pm with the file from the last version :03:

You can see the mesh from Wings3D with diffuses is not optimized ,but this one with AO is optimized :doh: ,this is the first time ,that make that with Wings :88)

The Wings3D one will not load - the app won't allow it. This is because the number of non-AO vertices does not equal the number of AO vertices in the OBJ files. The app has to be able to map the AO texture coordinates to the non-AO vertices. The only way it can do this is if both vertice counts are equal.

The 3DsMax one throws the mtl error because you only exported 3 subsets. It was looking for every subset. This is an oversight on my part and I'll correct the code :up:

BIGREG
05-29-12, 04:04 PM
Well, I have sought and learned many things about the AO :know:
Now I must put it into practice http://dl.dropbox.com/u/8655607/sweatingbullets.gif

During my research, I found this description of .OBJ : http://people.sc.fsu.edu/~jburkardt/txt/obj_format.txt
Maybe it can be useful :06: (albeit with your knowledges :D)

TheDarkWraith
05-29-12, 09:02 PM
I'm currently updating the app to be compliant with the document BIGREG posted above. It''ll take me a couple of days :up:
There is one thing that I will not be compliant with - I will force you to list the subset names (g entries) or the app will return an error. The model name (o entry) is now optional.

Since doing this I've seen an error in my code relating to how the materials were being assigned to the subsets with the new mtl reader code. This will be fixed also :yep:

BIGREG
05-30-12, 01:49 AM
:salute: Hi

Good luck TDW :yeah:, I'll continue to learn and test the use of AO :O:

I'll try to compile all the data (textures and UVW) into one. "OBJ" with 3DsMax :yep:

To see, I just need to add the AO for each texture, and redo the UVW
Yesterday I tried to add a "self illumination", it adds me a map "Ke" in Mtl ... ;)

Tomi_099
05-30-12, 09:02 PM
:salute: Hi

Good luck TDW :yeah:, I'll continue to learn and test the use of AO :O:

I'll try to compile all the data (textures and UVW) into one. "OBJ" with 3DsMax :yep:

To see, I just need to add the AO for each texture, and redo the UVW
Yesterday I tried to add a "self illumination", it adds me a map "Ke" in Mtl ... ;)

---------------------------------


http://www.gamefront.com/files/21773593/CT_Body_table.rar

The CT_Body_table is the original table in the room CT.GR2.
this table I wanted to import as knife ( Knifel)
and failed.:hmmm:

TheDarkWraith
05-30-12, 09:49 PM
---------------------------------


http://www.gamefront.com/files/21773593/CT_Body_table.rar

The CT_Body_table is the original table in the room CT.GR2.
this table I wanted to import as knife ( Knifel)
and failed.:hmmm:

This knife?
http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5707

I'm sending you revised version (I had an error in one I sent you) :up:

Since your OBJ file has no normal data ensure you uncheck import normal data or the app will throw an error :yep:

BIGREG
05-31-12, 01:29 AM
:salute: Hi

Repport Version 1.1.193.1

Wings3D : All is OK :up: (Just the mesh are not more optimized=more vertices)

3DsMax : Hum :hmmm: that seem when importing ,that the AO map replace the diffuse,
i have make test : import with AO (to have the same vertice) and after without and i have this error :


Edit:

Like I said, version 1.1.186.1 had the advantage of having the optimized meshes, even with 3DSMax.
Which for me personnaly is appreciable, and for those with small configurations (computers)

Re-edit : For the AO error with 3DsMax,It was not a mistake of the editor :yep:, but from me :shifty: :oops:
I had not deselect the mesh :88) (forgot to check the option Selected: texture)


I have found a little bug ,when importing the all AO seem to be altered , but when you disable the UI view ( Edit->option->show UI) everything returns to normal :hmmm:

With 3DsMax nothing to do ,impossible, to change the allocation of material on the faces

A very good news ,i have try to tesselate the mesh ,and that work great :woot: :yeah: :rotfl2: this means that we can add faces :rock:

still a little bug with the AO I think :hmmm::06:
export / import a mesh without modification creates a problem of light (dark on certain angle of view), I tried several render with 3dsmax, but I found nothing conclusive so far :-?

TheDarkWraith
05-31-12, 12:37 PM
I have found a little bug ,when importing the all AO seem to be altered , but when you disable the UI view ( Edit->option->show UI) everything returns to normal :hmmm:

With 3DsMax nothing to do ,impossible, to change the allocation of material on the faces

A very good news ,i have try to tesselate the mesh ,and that work great :woot: :yeah: :rotfl2: this means that we can add faces :rock:

still a little bug with the AO I think :hmmm::06:
export / import a mesh without modification creates a problem of light (dark on certain angle of view), I tried several render with 3dsmax, but I found nothing conclusive so far :-?

It's quite possible that I have a bug or two that I still need to work out in the new code. I'll look into it tonight when I get back into my hotel room :up:

Tomi_099
05-31-12, 03:08 PM
It's quite possible that I have a bug or two that I still need to work out in the new code. I'll look into it tonight when I get back into my hotel room :up:

-------------------------

Thanks !!

Maybe can help this !! :hmmm:


http://developer.nvidia.com/content/parallel-nsight-21-dynamic-shader-editing

http://developer.nvidia.com/nvidia-nsight-visual-studio-edition

TheDarkWraith
05-31-12, 03:55 PM
I have found a little bug ,when importing the all AO seem to be altered , but when you disable the UI view ( Edit->option->show UI) everything returns to normal :hmmm:

What kind of import (strict or loose)?

With 3DsMax nothing to do ,impossible, to change the allocation of material on the faces

Don't understand :06: Are you saying problem with app or problem with 3DsMax?

still a little bug with the AO I think :hmmm::06:
export / import a mesh without modification creates a problem of light (dark on certain angle of view), I tried several render with 3dsmax, but I found nothing conclusive so far :-?

What kind of import (strict or loose)? What happens if you don't import normals? What happens if you don't import AO? What happens if you don't import AO and normals?



See above in yellow.

If you can send me the files you were working with and what you were doing I'll try to recreate the problem. I need to see the problem in order to figure out what's going on.

BIGREG
05-31-12, 04:56 PM
:salute:

What kind of import (strict or loose)? - Loose

Don't understand :06: Are you saying problem with app or problem with 3DsMax?
- i think in editor ,when i open the file with wings all is good


What kind of import (strict or loose)? What happens if you don't import normals? What happens if you don't import AO? What happens if you don't import AO and normals?
- i have try in loose (the strict mod don't work,vertice error) i have try with and without AO(darkside),but i have not try without normal

EgoApocalypse
05-31-12, 06:15 PM
keep up the good work guys.:up:

( Just a little hello )

Tomi_099
05-31-12, 07:44 PM
:hmmm:

The table and the knives were taken but no textures.
whether TGA / DDS / or JPG:06:

http://img706.imageshack.us/img706/7129/ohnetextur.jpg
By tomi_099 (http://profile.imageshack.us/user/tomi_099)



I'm not sure, but 3D Max leaves at the MTL not specified on the textures


MY MAX EXPORT MTL
http://img52.imageshack.us/img52/8346/meinsc.jpg
By tomi_099 (http://profile.imageshack.us/user/tomi_099)



.ORGINAL MTL
http://img535.imageshack.us/img535/2619/orgga.jpg
By tomi_099 (http://profile.imageshack.us/user/tomi_099)



First i have this problem
http://img834.imageshack.us/img834/3630/errormxy.jpg
By tomi_099 (http://profile.imageshack.us/user/tomi_099)

then i exportit with this option !

http://img801.imageshack.us/img801/7963/exportsucces.jpg By tomi_099 (http://profile.imageshack.us/user/tomi_099)


...??? I just noticed that there is (Faces) QUADS .That mast be TRIAGLES wright.
Oops ..!

Import was succes !!


http://img42.imageshack.us/img42/7973/succesu.jpg
By tomi_099 (http://profile.imageshack.us/user/tomi_099)

Hallo TheDarkWraith you conteyn UVW from 3D-Max in your GR2 Editor ???




I had the original 2texturen on the table with ID1,
and a texture for the knife,
with the ID 2

All were reproduced on two 1Textur.

This means that the table and the knife are on 1 image with a UVW

---> You see the yellow color in the texture is of the knife and the green table<--

http://img210.imageshack.us/img210/2776/11render.jpg (http://imageshack.us/photo/my-images/210/11render.jpg/)

Uploaded with ImageShack.us (http://imageshack.us)

################################################## #############

AMBIENT OCCLUSION ( AO )


http://img687.imageshack.us/img687/3405/1ambienocclusion.jpg
By tomi_099 (http://profile.imageshack.us/user/tomi_099)

.

http://img526.imageshack.us/img526/3405/1ambienocclusion.jpg
By tomi_099 (http://profile.imageshack.us/user/tomi_099)

..




http://img715.imageshack.us/img715/7409/4dxt51024x1024.jpg
By tomi_099 (http://profile.imageshack.us/user/tomi_099)


My FILES

http://img403.imageshack.us/img403/4296/11aandbfolder.jpg

TheDarkWraith
05-31-12, 09:27 PM
:hmmm:

The table and the knives were taken but no textures.
whether TGA / DDS / or JPG:06:

If you imported UVs for the table and knives then it should show with the texture specified for the main object (I'm assuming your table and knife were added to an existing subset?). Trying turning Self-Illumination off in the rendering tab and see what happens. Then re-enable self-illumination and disable diffuse and see what happens.

I'm not sure, but 3D Max leaves at the MTL not specified on the textures

BIGREG is able to export from 3DsMax with MTL entries and a MTL file

First i have this problem
then i exportit with this option !
...??? I just noticed that there is (Faces) QUADS .That mast be TRIAGLES wright.
Oops ..!
Import was succes !!

If the numer of vertices has changed from the original then you cannot do a strict import. You have to do a loose import. Trying to do a strict import with the number of vertices not equalling the original will result in the error you received.

Hallo TheDarkWraith you conteyn UVW from 3D-Max in your GR2 Editor ???

I'm not familiar with 3DsMax UVW files. The app currently is only able to read/write GR2, OBJ, and MTL files.

See above in yellow.

BIGREG
06-01-12, 01:42 AM
:salute: Hi all

Quick question for everyone
I just tried to find the problem of light in the conning tower.
But it seems that is an original problem :hmmm::06: ,
after a try with the original files, I have this:

http://dl.dropbox.com/u/8655607/SH5Img%402012-06-01_08.27.39.jpg

http://dl.dropbox.com/u/8655607/SH5Img%402012-06-01_08.27.43.jpg

So if someone could tell me if, at his home it did the same thing
(no mods installed and stand in front of the attack periscope)

BIGREG
06-01-12, 02:49 AM
:woot: Ok ,i have found the problem :damn: Oh ! My god ! :roll:

This problem of shadows came, when I load a backup recorded in the port, inside the bunker ! :doh:

So the problem was not from AO or normals in the conning tower in it even :nope:

But,How the light is used in the bunker ! Amazing ! :o

Edit :

So this is what I was saying that the light outside, influenced the inside of the submarine., It will really find a solution for the lights (adds / controls / modifications)

@Tomy : Use "MentalRay" in the render setup->common->assign renderer and save the AO as DXT1 or DXT5 without alpha :03:


:-?....

THE_MASK
06-01-12, 03:44 AM
Lights cfg
http://www.subsim.com/radioroom/downloads.php?do=file&id=3550

BIGREG
06-01-12, 04:20 AM
Thank Sober :03:

I know there are ways to change the light via the file lights.cfg :yep:
But What i mean is the possibility of adding some lights on bones and can control them : keyboard keys or the status (good/bad) or by time (day/night) or action (alarm/silence) :O: :D

Edit : i have found this plugin for 3DsMax to manage the UVW and textures : http://www.renderhjs.net/textools/

Re edit :
I have see a problem in the AO mtl file for the table in the conning tower

-Ok-
-Not Good-


Original Exported from editor :

newmtl conning_tower_room_01_subset0
Ns 2.000000000
Ka 0.588000000 0.588000000 0.588000000
Kd 0.588000000 0.588000000 0.588000000
Ks 0.900000000 0.900000000 0.900000000
Ke 0.000000000 0.000000000 0.000000000
map_Ka conning_tower_room_01.Jpg
map_Kd conning_tower_room_01.Jpg
map_Ks conning_tower_room_01.Jpg
map_bump tile_metal_03_N.Jpg
bump tile_metal_03_N.Jpg


# Exported from Wings 3D 1.4.1.2012-05-09---20-11.mlab

newmtl conning_tower_room_01_subset0
Ns 100.0 ???? no the same value
d 1.0 ????
illum 2 ????
Kd 0.588 0.588 0.588
Ka 0.588 0.588 0.588
Ks 0.9 0.9 0.9
Ke 0.0 0.0 0.0
map_Ka conning_tower_room_01.Jpg
map_Kd conning_tower_room_01.Jpg
newmtl default ?????
Ns 100.0
d 1.0
illum 2
Kd 0.7898538076923077 0.8133333333333334 0.6940444444444445
Ka 0.7898538076923077 0.8133333333333334 0.6940444444444445
Ks 1.0 1.0 1.0
Ke 0.0 0.0 0.0


# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
# File Created: 01.06.2012 18:44:33

newmtl conning_tower_room_01_subset0
Ns 2.000000000
Ni 1.500000000
d 1.000000000
Tr 0.000000000 ?????
Tf 1.000000000 1.000000000 1.000000000 ?????
illum 2
Ka 0.588000000 0.588000000 0.588000000
Kd 0.588000000 0.588000000 0.588000000
Ks 0.899999976 0.899999976 0.899999976
Ke 0.000000000 0.000000000 0.000000000
map_Ka maps\conning_tower_room_01.Jpg
map_Kd maps\conning_tower_room_01.Jpg
map_Ks maps\conning_tower_room_01.Jpg
map_bump -bm 0.020000000 maps\tile_metal_03_N.Jpg
bump -bm 0.020000000 maps\tile_metal_03_N.Jpg

@TDW

I think normally the "self illumination", should have the suffix "Ke"?
remains to be seen how to export the 2 UVW in the same .OBJ and it will be much easier for modifications
(since, we must modify the two meshes at the same time. and it is not easy and the double work)
and normally the ambient occlusion, don't have alpha chanel !?!

For the AO mtl ,we need just one material : map_K"e" conning_tower_room_01.Jpg

Tomi_099
06-01-12, 07:32 PM
:woot: Ok ,i have found the problem :damn: Oh ! My god ! :roll:

This problem of shadows came, when I load a backup recorded in the port, inside the bunker ! :doh:

So the problem was not from AO or normals in the conning tower in it even :nope:

But,How the light is used in the bunker ! Amazing ! :o

Edit :

So this is what I was saying that the light outside, influenced the inside of the submarine., It will really find a solution for the lights (adds / controls / modifications)

@Tomy : Use "MentalRay" in the render setup->common->assign renderer and save the AO as DXT1 or DXT5 without alpha :03:


:-?....
-----------------------------------------

THANK YOU !!! :salute:

@Tomy : Use "MentalRay" in the render setup->common->assign renderer and save the AO as DXT1 or DXT5 without alpha :03:

BIGREG
06-02-12, 02:07 AM
Hi :salute:

Here is the table with the AO file that contains just the necessary map (Warning! in the editor there is an error with lights, so trying in goblin or in game)

Import in loose mod with AO

CT_Table : http://dl.dropbox.com/u/8655607/Table_AOmodif.zip

Here a view ingame :

http://dl.dropbox.com/u/8655607/SH5Img%402012-06-02_08.58.30.jpg

TheDarkWraith
06-02-12, 07:38 AM
Hi :salute:

Here is the table with the AO file that contains just the necessary map (Warning! in the editor there is an error with lights, so trying in goblin or in game)

Import in loose mod with AO

CT_Table : http://dl.dropbox.com/u/8655607/Table_AOmodif.zip

Here a view ingame :

I might have finally figured out why also :yep: Still investigating...

BIGREG
06-02-12, 08:40 AM
:salute: Hi TDW

I also try to understand the why and how :O:
But there is not much information on the self illumination map "ke", at least for what is to add textures vertex or for UVW ID (channels)

Edit

Here a doc of the .mtl : http://www.fileformat.info/format/material/index.htm

TheDarkWraith
06-02-12, 09:24 AM
:salute: Hi TDW

I also try to understand the why and how :O:
But there is not much information on the self illumination map "ke", at least for what is to add textures vertex or for UVW ID (channels)

Edit

Here a doc of the .mtl : http://www.fileformat.info/format/material/index.htm

Ke is not for AO, it's the emissive property of the material. Think of it as a glow stick - it's the color given off by the material itself.

TheDarkWraith
06-02-12, 10:02 AM
Here a doc of the .mtl : http://www.fileformat.info/format/material/index.htm

Thank you :up: I'll read it over. I had many questions about the data contained in those MTL files :yep:

BIGREG
06-02-12, 10:10 AM
Me who believed that this format very simple :rotfl2:
I don't know if you had the opportunity to add some parameters, such as:

-illum http://dl.dropbox.com/u/8655607/this.gif :D
-Tr
-Tf

etc.... :06:

Tomi_099
06-02-12, 11:55 AM
Hi :salute:

Here is the table with the AO file that contains just the necessary map (Warning! in the editor there is an error with lights, so trying in goblin or in game)

Import in loose mod with AO

CT_Table : http://dl.dropbox.com/u/8655607/Table_AOmodif.zip

Here a view ingame :

http://dl.dropbox.com/u/8655607/SH5Img%402012-06-02_08.58.30.jpg



Thank you friends, I'll try to test!
THANKS for TDW Ubdates GR2! :up:
Now I have make a little familiar to me with Wings 3D! :O:


BIGREG it is possible that you show us your reference when setting texture baking in 3D Max?
Abaut: ---> Lights/Ilumination/ Shedows !!
By the Backing Prozess !!
Your Maps looks Good !!! :up:

TheDarkWraith
06-02-12, 12:11 PM
Hopefully the bugs are all worked out now in the second importer.

@Tomi99 - the link BIGREG gave you for the table's AO will cause an error in the importer. You need to edit the CT_Body_table_AO file and change the mtllib entry to this:

mtllib CT_Body_table_AO.mtl

:up:

TheDarkWraith
06-02-12, 12:12 PM
Me who believed that this format very simple :rotfl2:
I don't know if you had the opportunity to add some parameters, such as:

-illum http://dl.dropbox.com/u/8655607/this.gif :D
-Tr
-Tf

etc.... :06:

After all the bugs are worked out in the second importer (and the MTL file reader) I'll look into these :up:

BIGREG
06-02-12, 01:17 PM
Report 1.196.1.1:

Seem the AO map replace the diffuse :hmmm:

Try with original and fresh exported file and direct re import

http://dl.dropbox.com/u/8655607/probaodif.jpg

TheDarkWraith
06-02-12, 03:48 PM
Report 1.196.1.1:

Seem the AO map replace the diffuse :hmmm:

Try with original and fresh exported file and direct re import

What import options did you have checked and what kind of import did you do?

BIGREG
06-02-12, 04:06 PM
in strict ,with all options checked

Edit : i have just retry (with the same export) and all is good :hmmm:

in strict,loose with and without AO :doh:

Re-edit : I don't understand ,i have re re try with all options possible and all work great :yeah:

BIGREG
06-02-12, 05:29 PM
:woot:All work fine :yeah:

- Export/import Strict&Loose
- Pro optimizer ( vertices,normals,... optimized :up: )
- Adding faces :D :rotfl2:
- UVW unwrap

The next "stress" test : modification of the Material attribution of the Periscope Base :yep:

Edit : Result

- Wings3D : Ok the material is good assigned :up:

-3DsMax : Always the same "no change" with the material attribution other the all subset will change :hmmm:
(We can always detach the party to modify and connect with the subset that has the desired material)

TheDarkWraith
06-02-12, 06:28 PM
:woot:All work fine :yeah:

- Export/import Strict&Loose
- Pro optimizer ( vertices,normals,... optimized :up: )
- Adding faces :D :rotfl2:
- UVW unwrap

The next "stress" test : modification of the Material attribution of the Periscope Base :yep:

Good to hear :yeah: That second importer I wrote had a hard time 'playing' with the existing code :shifty:. Next time I'll write the code as I need it and not before-hand!

BIGREG
06-02-12, 07:02 PM
Anyway Thank TheDarkWraight :yep: :up:

Which would be fine too, is the possibility of adding materials to the meshes/subsets :06:

TheDarkWraith
06-02-12, 07:25 PM
Anyway Thank TheDarkWraight :yep: :up:

Which would be fine too, is the possibility of adding materials to the meshes/subsets :06:

What do you mean :06:

BIGREG
06-02-12, 07:33 PM
eg: for the table just one material "texture" and for the periscope base=5

TheDarkWraith
06-02-12, 09:26 PM
eg: for the table just one material "texture" and for the periscope base=5

still don't understand :hmmm:

BIGREG
06-02-12, 09:50 PM
Since we can not add new materials, with wings or 3dsmax
but just the possibility to use the materials present, with the exported object :-?
example: For the table in the conning tower, I wanted to add a matchbox So I am forced to use the one and only material present, to texture the whole (table + matchbox)

I asked if you could not do something, for that in the editor :06:

kind: menu meshes -> Mesh or subset selected -> Adding material

TheDarkWraith
06-02-12, 11:21 PM
Since we can not add new materials, with wings or 3dsmax
but just the possibility to use the materials present, with the exported object :-?
example: For the table in the conning tower, I wanted to add a matchbox So I am forced to use the one and only material present, to texture the whole (table + matchbox)

I asked if you could not do something, for that in the editor :06:

kind: menu meshes -> Mesh or subset selected -> Adding material

ah, ok. What you are asking for is the ability to add new subsets to a mesh. Every subset has a material assigned to it thus this is the only way to do what you are wanting. The app currently does not have this ability. Maybe soon :yep:

CaliEs
06-03-12, 02:31 AM
Report 1.196.1.1:
...
http://www.subsim.com/radioroom/showpost.php?p=1892571&postcount=1391
...


A bit confusing this upside down view on the Grid-map of the Atlantic.
I would prefer to have a different map of something we have not seen yet in the type vii U-Boat.
For expl:
coastal waters of England, Bay of Biscaya, Gibraltar, Irish Sea, North Sea or Norwegian Sea.
or
coastal waters of Kiel, Wilhelmshafen, Lorient or Nazaire etc.

BIGREG
06-03-12, 04:24 AM
:salute: Hi CaliEs

Do not worry :D, it's already done, but the images posted are made with an original file :03:
But if you have maps, you can send them to me via PM :yep:
and I saw a mod for SH3 or SH4 which allows to change randomly the maps and other ...
I have the author's permission to use it (with the source code), but we must see if it is compatible with SH5 :O:

BIGREG
06-03-12, 05:37 AM
Here a Matchbox :D

http://dl.dropbox.com/u/8655607/Matchbox.jpg

Trevally.
06-03-12, 05:59 AM
Here a Matchbox :D


Great job BigReg:yeah:

BIGREG
06-03-12, 06:11 AM
Thank and i found i way to add objects already done in .OBJ format :D
and how to redo the 2 meshes (diffuse&AO) relatively quickly :rotfl2:

CaliEs
06-03-12, 06:55 AM
But if you have maps, you can send them to me via PM :yep:


Of course no high resolution-maps, but it's a start.

Baltic sea:
http://www.aotd-flottille.de/wbb2/jgs_db.php?action=download&download_id=38&sid=

Norwegian sea:
http://www.aotd-flottille.de/wbb2/jgs_db.php?action=download&download_id=36&sid=

Gibraltar/Mediterranean Sea:
http://www.aotd-flottille.de/wbb2/jgs_db.php?action=download&download_id=35&sid=
http://www.kartengruppe.it/immagini/okm/0293.jpg

Coastal waters England
http://img.xrmb2.net/images/882458.png
http://www.aotd-flottille.de/wbb2/jgs_db.php?action=download&download_id=33&sid=
http://www.kartengruppe.it/index2.php?option=com_content&view=article&id=13

Atlantik
http://www.aotd-flottille.de/wbb2/jgs_db.php?action=download&download_id=19&sid=
http://www.kartengruppe.it/index2.php?option=com_content&view=article&id=21

North Sea
http://img.xrmb2.net/images/103012.png

Kiel
http://img.xrmb2.net/images/946144.png
http://greif.uni-greifswald.de/geogreif/geogreif-content/upload/sek/P19-1Kiel-Hafen.jpg (1906)
http://greif.uni-greifswald.de/geogreif/geogreif-content/upload/sek/G14.jpg (1951)
http://greif.uni-greifswald.de/geogreif/geogreif-content/upload/sek/P5-1EinfahrtKiel.jpg (1915)

Wilhelmshafen
http://img.xrmb2.net/images/441063.png
http://greif.uni-greifswald.de/geogreif/geogreif-content/upload/sek/H7-1Jade-Weser-Ems.jpg (1906)

Lorient
http://img.xrmb2.net/images/387183.png

Saint-Nazaire
http://img.xrmb2.net/images/968042.png

TheDarkWraith
06-03-12, 06:57 AM
Thank and i found i way to add objects already done in .OBJ format :D
and how to redo the 2 meshes (diffuse&AO) relatively quickly :rotfl2:

Nice :yeah:

Now for a challenge: add boxes and food in the hallways and in the kitchen :cool:

I'm putting together a plan of action for letting you add subsets to a mesh via the app :up:

BIGREG
06-03-12, 07:37 AM
:salute: Hi TDW

Now for a challenge: add boxes and food in the hallways and in the kitchen :cool:


Yes, But it would be better if we could add the foods, as meshes, to control them through. SIM :yep: ( mesh+bone=Total control :D )



Great :yeah:

gap
06-03-12, 10:07 AM
Here a Matchbox :D

http://dl.dropbox.com/u/8655607/Matchbox.jpg

Wanna zigarette?

http://i.ebayimg.com/t/WW2-German-Army-Issue-Landser-Cigarettes-Eckstein-No-5-Dresden-/00/s/MTA3OFg4MDg=/$(KGrHqR,!oQE9fskJ8uTBPkLBlhkMQ~~60_57.JPG

more nazi cigarettes and cigarette cases (praying moderators to delete this post in case by posting these I have infringed any law :rolleyes:):

http://i.ebayimg.com/t/WW2-German-Army-Issue-Landser-Cigarettes-Eckstein-No-5-Dresden-/00/s/NzU1WDU4NA==/$(KGrHqV,!i8E7DZvCDDrBPkLBZMbRg~~60_3.JPG

http://i.ebayimg.com/t/WW2-German-Army-Issue-Landser-Cigarettes-Eckstein-No-5-Dresden-/00/s/NzM4WDU4Nw==/$(KGrHqJ,!igE9p4OK2n5BPkLBfny3!~~60_3.JPG

http://i.ebayimg.com/t/WW2-German-Army-Issue-Landser-Cigarettes-Eckstein-No-5-Dresden-/00/s/Nzc0WDc4OQ==/$(KGrHqN,!jkE9WFzI)v3BPkLBjGw2g~~60_3.JPG

http://i.ebayimg.com/t/WW2-German-Army-Issue-Landser-Cigarettes-Eckstein-No-5-Dresden-/00/s/NjIxWDkwNQ==/$(KGrHqF,!k8E9G8tTy)BBPkLB(Yh4!~~60_57.JPG

http://i2.photobucket.com/albums/y18/pzrwest/20eckstein-cigpak.jpg

http://jbwid.com/img_97/prv1940s.jpg

http://www.militaryantiquesmuseum.com/img/Product27423.jpg

http://www.militaryantiquesmuseum.com/img/Product27422.jpg

http://gmic.co.uk/uploads/monthly_03_2011/post-1206-0-73591200-1299693758.gif

http://www.cowanauctions.com/itemImages/mm9886.jpg

http://www.icollector.com/images/1186/22487/22487_0162_1_lg.jpg

BIGREG
06-03-12, 10:55 AM
http://dl.dropbox.com/u/8655607/merci.gif to you both GAP and CALIES for the pictures :yeah:

TheDarkWraith
06-05-12, 06:45 PM
Added the ability for the file's Sentinel to create additional mesh subsets. Currently I can add subsets to a mesh from Sentinel's command line window. Adding the ability for these additional subsets to be created when importing OBJ files into a mesh now (if needed) :up:

The ability to delete mesh subsets I'm still thinking about. I have to come up with the correct algorithm first then I can implement it code wise.

BIGREG
06-05-12, 06:48 PM
:yeah: Great TDW

TheDarkWraith
06-05-12, 11:49 PM
Which would be fine too, is the possibility of adding materials to the meshes/subsets :06:

While finishing up with the new code for the second importer that lets you import OBJ data that has more subsets than the original mesh I finally realized what you were asking :o

I exported the CT_Table from Room_CT. Opened up the OBJ file and copied the face data thus making another subset (_subset1). Imported it back in and everything worked correctly (2 subsets now instead of 1) :rock:

In the GR2 file format the PrimaryTopologyGroups (aka mesh subsets) have a material index property. This material index property references the material for the subset from the mesh's material bindings. Here's where I was getting tripped up! I totally forgot about these material bindings! I'm adding code that will let you add material bindings to a mesh so that each subset of the mesh could be assigned a seperate material :yep:

After that I'm going to write the code to remove mesh subsets and remove materials from the mesh's material bindings.

EDIT:

ability to add material bindings to meshes has been coded in and is working. Have to change the code for the meshes treeview now to reflect this change.

BIGREG
06-06-12, 04:02 AM
:salute: Hi TDW

Super cool :yeah:

I eagerly await the next version :yep:

TheDarkWraith
06-06-12, 11:41 AM
Made some changes to the mesh's treeview context menus:

If you right click on the mesh name you'll see:

Edit
Rename
-------
View material bindings
Add material to material bindings



if you right click on the mesh subset's material you'll see:

View all
-------
Select new Material from material bindings



if you right click on the mesh's subset's material entries there is an additional command: Reload. This will reload the texture from the file.

This now let's you assign more materials to a mesh's material bindings. This is turn lets you assign different materials to each of the mesh's subsets.

The material and texture treeviews also get this Reload command so the texture can be reloaded.

I know someone is going to ask "What's with this Reload thing?". It's quite simple: say you spot a defect or you change the texture in Photoshop or some other app and you want to see the change now. Reload will let you do this. Before you had to close the current GR2 file and then reopen it.

Adding the code for removing material bindings from a mesh and for deleting mesh subsets now :DL

BIGREG
06-06-12, 04:26 PM
Ok i am ready for test :yep: :yeah:

Ps: At the moment I arrange my files a bit (a lot of new 3D objects :D, textures .....)

TheDarkWraith
06-06-12, 06:03 PM
Ok i am ready for test :yep: :yeah:

Ps: At the moment I arrange my files a bit (a lot of new 3D objects :D, textures .....)

Finished coding the removal of material bindings. Working on the removal of mesh subsets now. All the treeview context menus have been updated.

@BIGREG and Tomi99 - test away! Be safe - BACKUP YOUR FILES BEFORE SAVING WITH THE APP!

BIGREG
06-06-12, 07:01 PM
Work great TDW :yeah: :D

Next step: Import new meshes :03: (not subsets) in order to connect to a bone :yep:
I think that it is not possible with subsets :06:

eg: To adding meshes -> new bone created -> add/attach a mesh or if possible subsets :O: :06:

:yawn:

TheDarkWraith
06-06-12, 07:08 PM
Work great TDW :yeah: :D

Next step: Import new meshes :03: (not subsets) in order to connect to a bone :yep:
I think that it is not possible with subsets :06:

eg: To adding meshes -> new bone created -> add/attach a mesh or if possible subsets :O: :06:

:yawn:

I'm testing the removal of mesh subsets now :D If all goes well a new version will be coming your way!

With the ability to import variable geometry and subsets you can mimmick new meshes. Pick a mesh and import whatever you want into it. You basically just made a new mesh. All I have to do is give you the ability to delete meshes then you can take a GR2 file and use it as a shell. Hollow out the shell by deleting the meshes you don't need and import your geometry into the meshes you do need (do the same for textures and materials) and voila - you have new GR2 file :D

I don't understand what you're asking here: eg: To adding meshes -> new bone created -> add/attach a mesh or if possible subsets :06:

BIGREG
06-06-12, 07:16 PM
I want to animate objects as: news TDC knobs/wheels,torpedo doors knobs,coffee in tasse, lights indicators(with to faces red/green or white) etc....
and for that i need the ability to attach a bone of a mesh/subset

TheDarkWraith
06-06-12, 07:25 PM
I want to animate objects as: news TDC knobs/wheels,torpedo doors knobs,coffee in tasse, lights indicators(with to faces red/green or white) etc....
and for that i need the ability to attach a bone of a mesh/subset

Each mesh is already setup to a bone (it's called a bone binding). The bone with the same name as the mesh is it's bone binding (that's how SH5 is setup). You can assign any bone(s) to a mesh though I do not currently give you the ability to change the mesh's bone binding(s).

BIGREG
06-06-12, 07:31 PM
and do you think is possible to bind a bone of a subset :06:

TheDarkWraith
06-06-12, 07:32 PM
and do you think is possible :06:

What? To change the bone binding of the mesh? Sure it's possible. I just have to code it :DL

BIGREG
06-06-12, 07:35 PM
not change ,that bring nothing,But binding a bone with a subset other the ability to change subset into a mesh :06:

Eg : the torpedo door panel in CT ,i can cut the knobs and make subsets ,but to animate them with the .sim i need bones to each subsets

TheDarkWraith
06-06-12, 08:04 PM
not change ,that bring nothing,But binding a bone with a subset other the ability to change subset into a mesh :06:

Eg : the torpedo door panel in CT ,i can cut the knobs and make subsets ,but to animate them with the .sim i need bones to each subsets

The GR2 file format does not allow you to specify bones for each subset (from what I can tell). It only allows you to bind a bone to an entire mesh. Remember that I'm going by what I know and have learned from working with the GR2 format. It may allow you to do this but I don't know how.

The only way to do what you're wanting is to break the subsets into entirely new meshes. Then you would be able to assign a bone to each mesh.

BIGREG
06-06-12, 08:08 PM
Yes ,explode the subsets :D to make separate meshes :yep: or the other way is when we create bone the ability to attach directly an imported mesh :hmmm::06:

TheDarkWraith
06-06-12, 08:59 PM
Anything look different here (I have the self-illumination rendering disabled so it's easier to see) :06:

http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5721

mesh CT_Body subset 3 was removed by the app :rock: Granny Viewer confirms file saved is ok :D

:|\\

BIGREG
06-06-12, 09:11 PM
:D we can dance in the conning tower now :haha:

BIGREG
06-07-12, 11:24 AM
:salute: Hi

Repport version 1.203.1 :

- The export/import in strict don't work with this version file exported (original/without modif) ,but work with file from 1.196.1

- Error when select an other material : Menu meshes/subset/select new material binding

- after reload a saved .GR2 ,the same material/texture is attibued on all subsets in the mesh (perhaps mishandling :88))

To add : an option in the file menu : "Save as" (to not always save over) :yep:
and the ability to save without modification :D

TheDarkWraith
06-07-12, 01:09 PM
:salute: Hi

Repport version 1.203.1 :

- The export/import in strict don't work with this version file exported (original/without modif) ,but work with file from 1.196.1

I need specifics in order to try and recreate what you did. What files were you using? What mesh were you trying to import into? I need the files you were trying to import also.

- Error when select an other material : Menu meshes/subset/select new material binding

Which GR2 file was loaded? Which mesh/subset were you trying to change? I'll need the GR2 file you loaded in order to see why you are getting an error. What does the error say?

- after reload a saved .GR2 ,the same material/texture is attibued on all subsets in the mesh (perhaps mishandling :88))

I'll need the GR2 file you tried to load so I can see what's going on.

To add : an option in the file menu : "Save as" (to not always save over) :yep:
and the ability to save without modification :D

Save with modification? Don't understand :06:

The Save as is something I can and will add :up:

The deleting of a mesh subset has a small bug that I'm trying to sort out. There is one embedded string pointer that is becoming corrupted everytime I delete a mesh subset. This one embedded string pointer just so happens to be an empty string also ("") :hmmm:

BIGREG
06-07-12, 02:36 PM
I need specifics in order to try and recreate what you did. What files were you using? What mesh were you trying to import into? I need the files you were trying to import also.


Arhg ! :damn: to understand nothing, now it works :doh:

Which GR2 file was loaded? Which mesh/subset were you trying to change? I'll need the GR2 file you loaded in order to see why you are getting an error. What does the error say?

Here the .gr2 ,But nothing to do ingame :nope:

http://dl.dropbox.com/u/8655607/undersea.zip

Save with modification? Don't understand :06:

Saving the .GR2,without we make a modification ( for make a copy of the file -> other i need to remodifie something to save it again)

TheDarkWraith
06-07-12, 09:50 PM
- after reload a saved .GR2 ,the same material/texture is attibued on all subsets in the mesh (perhaps mishandling :88))

I loaded up your undersea.GR2 and why I thought you were having trouble was exactly why.

- You created a new material called fish - excellent
- You imported an OBJ file that contained a new subset for grass01 thus making the total number of subsets for the mesh 2 - excellent

I got a good laugh out of the texture you assigned for the fish material - British.dds :rotfl2:

Now here is where you ran into a problem. You saw that everything was rendered as you expected EXCEPT for the fact that the material for the fish (the new subset) was only temporary! Remember I haven't finished the MTL reader of the importers yet so what I've done is anything you import is automatically assigned the first material binding of the mesh. This is why you think there is an error.

What you need to do after you import (until I finish the MTL reader):
- at the mesh you imported into: for each subset's material right click and select "Reload all". This will show you the real texture that will be rendered.

Now to utilize your new material (fish) you need to right click on grass01 (Mesh) and select "Add material to material bindings". Select the fish material. Now you will have two material bindings defined for the mesh. Now right click on Subset 1 (the new subset) of the grass01 mesh and select "Select new material from material bindings". Select the fish material. Voila - just what you were wanting to do :D

I'm sending you revised version and your undersea.GR2 modified by moi to reflect what you were wanting to do :up: This version will also let you delete mesh subsets now :cool: File-->Save is now always enabled (provided at least one GR2 file is open and one is selected). File-->Save as... has been added so you can save to a different filename.

http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5724

The bug of some embedded string pointers becoming corrupt when deleting a mesh subset has been put to rest. It was a nasty bug - took 3 days to find :shifty: The good news is it's fixed - the bad news is those of you who have modified GR2 files from this app probably have some embedded strings that aren't the correct string anymore. This bug could've reared it ugly head anytime you saved a modified GR2 file from the app :dead: You'll know you were bitten by the bug if you see names that are different from what they were before. That's the only side effect from the bug - mangled string names (not all - maybe 1, maybe a few, but definitely not all of them). The bug started to rear it's ugly head when the app went into alpha state (the ending .1 in the version number) :-?

I'll work on deleting materials and textures from a GR2 file now...maybe even bones...

BIGREG
06-08-12, 02:10 AM
:salute: Hi TDW

Thank,I knew well that I missed something :oops::88)
For the british texture , this is the first I saw and I found that funny :D

Now to utilize your new material (fish) you need to right click on grass01 (Mesh) and select "Add material to material bindings". Select the fish material.
This is by doing that I had errors :doh:

I'm sending you revised version and your undersea.GR2 modified by moi to reflect what you were wanting to do :up: This version will also let you delete mesh subsets now :cool: File-->Save is now always enabled (provided at least one GR2 file is open and one is selected). File-->Save as... has been added so you can save to a different filename.

I'll work on deleting materials and textures from a GR2 file now...maybe even bones... :yeah:

I'll try the new version, and trying to remember everything :O:

BIGREG
06-08-12, 06:23 AM
:salute: Here again a request :D

https://dl.dropbox.com/u/8655607/Mapadd.jpg

TheDarkWraith
06-08-12, 07:05 AM
Ah yes, I totally forgot about adding/removing maps to/from a material. I'll look into it :up:

BIGREG
06-08-12, 07:52 AM
Thank

I test the new version and all see to working fine :yeah:

TheDarkWraith
06-09-12, 01:46 AM
Coded in the ability to define maps for the material when you create a new material. Here I added a new material to the NLL.GR2 file and defined 3 maps for the material:

http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5733

http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5734

The extended data is correct for the maps but the extended data is incorrect for the main material extended data. It appears I grabbed the wrong pointer somehow :hmmm: The extended data looks like it comes from a material with no maps and a texture defined.

Here is the NLL_Test.GR2 file is you'd like to view it for yourself: http://www.mediafire.com/?2k35daqhvdqw832

You can load it up in the app also :up:

Work continues...

BIGREG
06-09-12, 03:43 AM
:salute: Hi

I have try,but not found the error :06:
After export the boat03 in 3DsMax all see good :hmmm:
Other i don't have understand ,How is the error :88)

In any case, it's promising :rock:

TheDarkWraith
06-09-12, 09:36 AM
:salute: Hi

I have try,but not found the error :06:
After export the boat03 in 3DsMax all see good :hmmm:
Other i don't have understand ,How is the error :88)

In any case, it's promising :rock:

In GrannyViewer click the TDW_Test_Material_With_3_Maps ExtendedData. Compare that to another material with 3 maps defined. You'll see two completely different extendeddatas (mine is wrong). Other than that everything else is perfect.

BIGREG
06-09-12, 10:13 AM
Ok,i have see, "Bump map" in the new material and in the other "standart" and more Granny Thing :hmmm:,
But all see to work ,i have take a look in the view detailed mesh list->material binding and all seem good :hmmm::hmmm:

TheDarkWraith
06-09-12, 10:19 AM
Ok,i have see, "Bump map" in the new material and in the other "standart"
and more Granny Thing :hmmm:,But all see to work ,i have take a look in the mesh list->material binding and all seem good :hmmm::hmmm:

Other than the incorrect extendeddata it's perfect. Due to not having the correct extendeddata nothing will be able to read the ambient, diffuse, specular, or emissive material properties because they don't exist. This, of course, is a problem. The new material is useless without these.

I found the bug that's caused this and corrected it. Now I have another problem. I wrote an extendeddata cloner that will take pointers to an existing item's extendeddata, clone/copy it, then populate the new extendeddata with the item's pertinent information. There are a couple problems with this cloner/copier currently if the extendeddata contains pointers that point to some other data. I have to fix these problems now :yep:

BIGREG
06-09-12, 10:23 AM
Great work again TDW :yeah:

TheDarkWraith
06-09-12, 06:01 PM
There are times when I just sit in front of my computer screen with my jaw wide open saying "did that just really happen?". I just had another one of those times.

I finished writing the code for creating a new material and being able to define x number of maps for it. I had to fix the bugs in the ExtendedData class's cloner function and once those bugs were worked out I commenced test #1.

Now let me back up before commencement of test #1. The ExtendedData class's cloner function is a work of art. The human brain cannot follow or even begin to comprehend the amount of recursion that is going on simultaneously. That is what made it so hard to write the code and even harder to debug it. I ended up writing 'helper' code to spit out what was going on with all these recursions so I could try and peace together what happened and why when it didn't work. Reviewing the output of the helper code was a task in itself. After 2 straight days I finally worked out all the bugs. Now why it's a work of art (in a code way): the function is given a pointer to existing extendeddata and a pointer to the new extendeddata. It then creates the needed space in the new extendeddata to house all the 'old' data. It starts reading the old data and copies what it reads to the new data. If the extendeddata only contained numbers it would've been simple but no, it also contains pointers, and pointers to lists, and pointers to char arrays, etc. The other pointers sometimes contain pointers to the same items mentioned and those other pointers...well you get the picture. Everytime the function encounters one of these pointers it has to create more space in the GR2 file to house the data it contains and also create new pointers for the data. This single cloner function contains everything needed to handle all of these so when it encounters one of these it calls itself. The second 'calling' could end up calling itself again...and that could end up calling itself again...and that could...well, you get the picture again. The human mind cannot follow all that recursion, it's impossible. The amount of calls for space allocations and pointer creations alone would drive you mad trying to follow it.

back to commencement #1...I created a new material with 3 maps. I clicked the Accept button and let it rip just waiting for a breakpoint to trigger saying "You idiot....ERROR!"...but nothing happened. The window just disappeared. I checked the material treeview and my new material was listed. Whoa. I opened the file's Sentinel window and asked for the chain for section 0 (linked list). Sentinel reported no breaks in the chain :o No way. I clicked File-->Save as... and saved the file as a new name in case there were errors. Fired up GrannyViewer and opened the file. GrannyViewer says all is good. I check the extendeddata for my new material and everything is populated :o Unbelievable. My jaw dropped :rock:

Kaicokid
06-09-12, 07:57 PM
It's a new dawn!

TheDarkWraith
06-09-12, 10:02 PM
The second importer (a loose import) can now import variable geometry and variable number of subsets :rock: You are no longer tied to what the mesh was originally. You can go crazy now :D

If you'd like to be a tester then PM me.

reignofdeath
06-09-12, 10:20 PM
There are times when I just sit in front of my computer screen with my jaw wide open saying "did that just really happen?". I just had another one of those times.

I finished writing the code for creating a new material and being able to define x number of maps for it. I had to fix the bugs in the ExtendedData class's cloner function and once those bugs were worked out I commenced test #1.

Now let me back up before commencement of test #1. The ExtendedData class's cloner function is a work of art. The human brain cannot follow or even begin to comprehend the amount of recursion that is going on simultaneously. That is what made it so hard to write the code and even harder to debug it. I ended up writing 'helper' code to spit out what was going on with all these recursions so I could try and peace together what happened and why when it didn't work. Reviewing the output of the helper code was a task in itself. After 2 straight days I finally worked out all the bugs. Now why it's a work of art (in a code way): the function is given a pointer to existing extendeddata and a pointer to the new extendeddata. It then creates the needed space in the new extendeddata to house all the 'old' data. It starts reading the old data and copies what it reads to the new data. If the extendeddata only contained numbers it would've been simple but no, it also contains pointers, and pointers to lists, and pointers to char arrays, etc. The other pointers sometimes contain pointers to the same items mentioned and those other pointers...well you get the picture. Everytime the function encounters one of these pointers it has to create more space in the GR2 file to house the data it contains and also create new pointers for the data. This single cloner function contains everything needed to handle all of these so when it encounters one of these it calls itself. The second 'calling' could end up calling itself again...and that could end up calling itself again...and that could...well, you get the picture again. The human mind cannot follow all that recursion, it's impossible. The amount of calls for space allocations and pointer creations alone would drive you mad trying to follow it.

back to commencement #1...I created a new material with 3 maps. I clicked the Accept button and let it rip just waiting for a breakpoint to trigger saying "You idiot....ERROR!"...but nothing happened. The window just disappeared. I checked the material treeview and my new material was listed. Whoa. I opened the file's Sentinel window and asked for the chain for section 0 (linked list). Sentinel reported no breaks in the chain :o No way. I clicked File-->Save as... and saved the file as a new name in case there were errors. Fired up GrannyViewer and opened the file. GrannyViewer says all is good. I check the extendeddata for my new material and everything is populated :o Unbelievable. My jaw dropped :rock:


Not to be ignorrant. But can you please explain this in simpler speak and what it means to the game?? :arrgh!:

TheDarkWraith
06-09-12, 11:46 PM
Not to be ignorrant. But can you please explain this in simpler speak and what it means to the game?? :arrgh!:

You can now take an existing GR2 file and turn it into something else (new geometry and materials). An existing GR2 file is just a shell to hold your new data.

Here's what you could do: take the LifeBoat.GR2 and turn it into another ship...or an airplane...or a sub....or whatever you want. It all depends on what you import into the existing meshes.

BIGREG
06-10-12, 01:19 AM
:salute: Bonjour à tous :D

TDW you are the master of the geniuses :yep:
Even the guys at MIT should be jealous not to have you :smug:
Incredibly, the job you have done :yeah:
I'll try the new version immediately :D

jean74
06-10-12, 01:54 AM
TheDarkWraith

I follow your posts and the developpment of your editor since you started. Due to real life I can't test and help you as Bigreg does.

What you have done is unbelievable !!! I can't imagine the complexity of the code of your GR2 Editor. I would like to have 0.01% of yours skills !

Without you SH5 would be certainly dead (new UIs, new Ai, new FXs, new tools,...),

So many thanks for all your work, and RESPECT from me

Best regards,


Jean

BIGREG
06-10-12, 02:36 AM
v1.218.1 report:

I try to create a material with 3 maps for the rock4 , in the undersea.gr2

- Add texture: rock4.dds and rock4_N.dds - OK

- Creation of maps: material type: map with no texture

one for the diffuse: Map#rk4diff - OK
one for illumination: Map#rk4ill - OK
and one for the bump:Map# rk4bump - OK

- Creation of material: No texture with map (named rock4)

add diffuse illumination, bump create rather

and i have this error:

https://dl.dropbox.com/u/8655607/errortexture.jpg

Bad procedure from me :06: :hmmm:

I have try with just the diffuse and that work,but if i assign more maps i have the same error

TheDarkWraith
06-10-12, 06:46 AM
Looking into it.

I just created 3 materials (type no maps with texture - diff, illum, and bump). Created ok. Tried to create a new material (type maps with no texture) and added all 3 new materials as the maps. Clicked Accept and got the same error as you...Now stepping through it in VS 2008 to see why :hmmm:

TheDarkWraith
06-10-12, 07:09 AM
I see the error but it's not really an error because the data it's trying to find doesn't exist in the undersea.GR2 file. What I need to do is not let you create a material with certain types of maps if the data it needs doesn't exist in the GR2 file. I'll correct the code.

The extendeddata datatype definitions for a material with 3 maps doesn't exist in undersea.GR2. It was trying to get the pointer to this data structure and the call failed. Since the app had already modified the memory of the file it had no option but to fail gracefully and close the file so you would not be able to save a corrupt version of it.

I have been putting off creating these data structures as it's going to be a royal pita to code. In the meantime the app has just been grabbing pointers to the data structures it needs from existing items and if they didn't exist I didn't let you create the item. Creating a material with maps slipped through the cracks as I forgot to check if the data structure needed exists first before letting you try and create the material with maps. Like I said I'll correct the code so at least you can't try and create it if the data it needs doesn't exist.

TheDarkWraith
06-10-12, 08:08 AM
- Creation of material: No texture with map (named rock4)

add diffuse illumination, bump create rather

and i have this error:

The main reason you are getting this error is because an embedded string doesn't exist in the GR2 file. I'm adding some code that will automatically add the 'essential' embedded strings to the GR2 file if they don't exist upon load.

tonschk
06-10-12, 09:09 AM
:salute: I completely agree with your statements jean74 :yeah:, in my opinion this is one of the most important threads of the Subsim forum

TheDarkWraith

I follow your posts and the developpment of your editor since you started. Due to real life I can't test and help you as Bigreg does.

What you have done is unbelievable !!! I can't imagine the complexity of the code of your GR2 Editor. I would like to have 0.01% of yours skills !

Without you SH5 would be certainly dead (new UIs, new Ai, new FXs, new tools,...),

So many thanks for all your work, and RESPECT from me

Best regards,


Jean

BIGREG
06-10-12, 10:12 AM
The main reason you are getting this error is because an embedded string doesn't exist in the GR2 file. I'm adding some code that will automatically add the 'essential' embedded strings to the GR2 file if they don't exist upon load.

Cool :O: I'm waitting the next version :yep:

TheDarkWraith
06-10-12, 11:19 AM
Cool :O: I'm waitting the next version :yep:

Just about ready. Doing final testing now :D

BIGREG
06-10-12, 02:15 PM
:yeah:

TheDarkWraith
06-10-12, 03:41 PM
The problem BIGREG was having was that the GR2 file he was working with was missing some embedded strings. These embedded strings are needed to define the maps he wanted to add. So what I did was look for these 'essential' embedded strings when the GR2 file is read in and if they don't exist I ask you if you want to add them. If you do then the app will add them to the GR2 file and you will have 100% functionality. If you don't then there's some things you will not be able to do with the app. Most GR2 files have all these 'essential' embedded strings already :yep:

BIGREG
06-10-12, 04:07 PM
:woot: Great that work fine,just an error when i try to remove the old "binding" material :O:

edit : for the undersea.GR2 ,when you open it with Goblin and merge the .sim ,i have lost controllers ,but in the left windows ,it could not come from missing meshes ? rock2,3,5 !?

TheDarkWraith
06-10-12, 06:04 PM
:woot: Great that work fine,just an error when i try to remove the old "binding" material :O:

What's the error :06:

If you renamed anything in that GR2 file then yes it's possible that's why you are getting the errors. The name is it's ID (the name is converted into an Int64 somehow)

BIGREG
06-10-12, 06:38 PM
The error occurs when removing the old material that is no longer used by the subset
example: for the rock4, I use my new material "Rock4" with my 3 maps :yeah: and I want to remove the binding with the previous material "rk" in the menu: Meshes->rock4->remove material... result error and corrupted save file :hmmm:

otherwise it works very well if I leave the old material :D:yeah:

Edit : for the error in goblin , that is an original error :shifty: other maybe that come from the annimation
but, I do not think, since I have no error with the other animated objects :-? eg:attack periscop,torpedo doors etc..

TheDarkWraith
06-10-12, 06:38 PM
The error occurs when removing the old material that is no longer used by the subset
example: for the rock4, I use my new material "Rock4" with my 3 maps :yeah: and I want to remove the binding with the previous material "rk" in the menu: Meshes->rock4->remove material... result error and corrupted save file :hmmm:

otherwise it works very well if I leave the old material :D:yeah:

send me the GR2 file so I can try it in VS and watch what's happening :hmmm:

BIGREG
06-10-12, 07:09 PM
Here before removing the old material : https://dl.dropbox.com/u/8655607/Rock4_TEST_Before_remove.zip

and here after (corrupted) : https://dl.dropbox.com/u/8655607/Rock4_TEST_after_remove.zip

TheDarkWraith
06-10-12, 07:50 PM
Here before removing the old material : https://dl.dropbox.com/u/8655607/Rock4_TEST_Before_remove.zip

and here after (corrupted) : https://dl.dropbox.com/u/8655607/Rock4_TEST_after_remove.zip

I see the error. It's my fault also :dead: When I removed the material from the mesh's material bindings I never updated each subset's map references to reflect this! This has been fixed :up:

I just finished coding the Texture remover. Testing it now...

BIGREG
06-10-12, 07:54 PM
Super :03:

Now,we can make many things with your editor ,Thank TDW or maybe not :hmmm:, given the job as it allows :03: :O: :D :haha:

TheDarkWraith
06-10-12, 09:54 PM
Texture remover works for the most part. I knew this one was going to be difficult because of all the pointers that have to be adjusted and/or removed. Looks like I got them all but one...Sentinel says there is 1 break in the linked list...now to figure out which one I missed :hmmm:

BIGREG
06-10-12, 10:44 PM
All work great TDW :woot::yeah:

Now i can add the illumination and the bump map for the rocks :D

TheDarkWraith
06-11-12, 06:44 PM
Just finished coding the texture remover. Had some bumps and bugs in testing but they're all worked out now. We can now delete textures from GR2 files :rock:

Now I have to write an extendeddata remover/deallocater. I have the extendeddata cloner/copier (allocater) coded so I should be able to do the reverse of it to deallocate extendeddata. That's the theory and plan anyways...:D

TheDarkWraith
06-11-12, 11:48 PM
GrannyViewer seems to have the main menu hard coded as to what items appear in it (the main screen when you select view in detail). I was going to add a new menu entry 'Author Info' but it refuses to show it. I have all the correct pointers and datatype definitions for it and I've printed out the data to verify they are correct and in the correct locations :damn: Some peoples children...:nope:

Now I'll have to attach it to the ExtendedData entry in the main menu :shifty:

BIGREG
06-12-12, 01:53 AM
:salute: Hello

https://dl.dropbox.com/u/8655607/transmap.jpg

(the "non" transparency in editor is present also with original file)


in my last modification ,i have make that for the material :

one Material with the 2 maps (diffuse and illumination :the same texture is used : the illumination is the alpha chanel from .dds :03:) and one with the bump
and create a material to binding the both and use by the mesh and that work fine :yep:

I'm going to test/stress the new version a bit :D :rock::rotfl2:

BIGREG
06-12-12, 05:51 AM
Here's a little explanation to assign a new material with 3 maps :

https://dl.dropbox.com/u/8655607/explanation.jpg

TDW , i have nothing to say :D,all work fine :yeah: ,and yet, I have tortured it in every sense :arrgh!:
(import meshes-add/delete subset-change/add/delete material/texture) :rock:

It remains only to be able to:

- Added functions in. Mtl (tr, tf, ill, ....)

- Add new meshes (or transform subsets) for connecting bone :yep:

- Export/import annimations .... if possible, of course :06:

- And that's it all :03:, I think :hmmm: :D

TheDarkWraith
06-12-12, 06:26 AM
(the "non" transparency in editor is present also with original file)

ah, so that's what they meant by Opacity. I'd really love to figure out where they get these names from and their purpose :hmmm: I hate to hard code names and their purpose but so far I've had to do this for Diffuse Color, Self-Illumination, Bump, Additional Bumpmap, and now Opacity. I'll tell the app to recognize Opacity as the AO map.

BIGREG
06-12-12, 06:41 AM
I hate to hard code names and their purpose but so far I've had to do this for Diffuse Color, Self-Illumination, Bump, Additional Bumpmap, and now Opacity

Dito for me :doh:
But i think the illumination map ( the alpha chanel in the dds) is/can used for transparency or illumination via the missing function in .MTL (tr,tf,ill...)
For the AO ,yes that must to be the oppacity in the editor
(if you can rename it : "Ambient Occlusion" :yep: )

edit : no is good i have look in 3dsmax and the name used is "oppacity"

Here a view of the material maps in 3DsMax :

https://dl.dropbox.com/u/8655607/map3dsmax.jpg

this is just the maps possible with a standart material :timeout:

TheDarkWraith
06-12-12, 07:23 AM
It gets worse. I stepped through the loading of undersea.GR2 in VS 2008 and saw that texture ...\seabed01.dds is being loaded by the app. Then I watched the materials being made...Map#63 has no pointer to a texture in the GR2 file thus is why you never 'see' anything from it. GrannyViewer confirms this also - no pointer to a texture. Why is this bad? Because SH5 is not conforming to Granny's rules. They side stepped Granny and when SH5 encounters a map reference with Opacity as the usage they aren't looking for whether the material referenced by the map reference has a texture or not they are simply reading the extendeddata and grabbing the 'bitmap' or 'File Name' entry and creating a texture from it :nope:

BIGREG
06-12-12, 07:28 AM
For the oppacity Map#63 in the undersea.gr2 ,i think the dev have missing to assignate them :stare::nope:,i have not see change with or without (ingame/goblin)
and in texture folder are no maps for it ,in .dds we can have only have one alpha !

other we need to make

- 1 texture .dds (dxt5) diffuse/illumination (include (ka+kd)+ks)
- 1 texture_O .dds no apha (dxt1) for the "oppacity" * (ke or d ?) which of the two :hmmm:
- 1 texture_N.dds no apha (dxt1) for the bump* (bump)

*or we can make only one dxt5 (with alpha) ,and use the alpha for the bump map ? (ke or d+bump)

TheDarkWraith
06-12-12, 08:10 AM
I had to make some changes to the app so that I could assign a texture to Map#63 thus giving it a texture pointer. Confirmed it now has a texture pointer with GrannyViewer. Checked what Goblin thought of it and everything is ok. Now I just have to figure out how to render these 'Opacity' maps...:hmmm:

BIGREG
06-12-12, 08:37 AM
I think ,you need to add the "ke" map in the equation :D for the opacity
and for the light (sticla) the map "d" Self-illumination :timeout::O:

description from 3dsMax :

Topics in this section




Ambient color is the color of the object in shadow.
Diffuse (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab041063133-18033351112a1ce86c6-7f7b.htm) is the color of the object in direct, "good" lighting.
Specular (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab041063133-18033351112a1ce86c6-7e62.htm) is the color of shiny highlights.
Color Controls let you choose the materials color components, or replace them with maps.
Self-Illumination (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa4.htm) makes a material appear lit from within. Self-illumination is not available for the Strauss shader (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa7.htm).
Opacity (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa3.htm) controls how opaque or transparent a material is.
Diffuse Level (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa2.htm) controls the brightness of the diffuse color component. Diffuse Level is available only for the Anisotropic (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fad.htm), Multi-Layer (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7faa.htm), and Oren-Nayar-Blinn (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa9.htm) shaders.
Roughness (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa1.htm) controls how quickly the diffuse component blends into the ambient component. Roughness is available only for the Multi-Layer (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7faa.htm) and Oren-Nayar-Blinn (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa9.htm) shaders.
Color Controls (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa5.htm)
Color controls set the colors for different color components. You can set the color by clicking the color swatch to display the Color Selector (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab041063133-2a605991112a1ce7a04-7ff7.htm).

Self-Illumination Setting (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa4.htm)
These controls make the material self illuminated (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab041063133-18033351112a1ce86c6-7e70.htm). Self-illumination creates the illusion of incandescence by replacing shadows on the surface with the diffuse color. As you increase self-illumination, the self-illumination color takes over from the ambient color. At a setting of 100, the material shows no shaded areas, although it can show specular highlights.

Opacity (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa3.htm)
Opacity controls whether a material is opaque, transparent, or translucent. (A more physically accurate way to generate translucency is to use the Translucent shader (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa6.htm).)

Diffuse Level (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa2.htm)
Diffuse Level controls the brightness of the material's diffuse component.

Roughness (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa1.htm)
Roughness controls the rate at which the diffuse component blends into the ambient component.

Translucency Setting (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa0.htm)
The translucency controls are available for the Translucent shader (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WSf742dab0410631334fd1fb1c112a1ce99ff-7fa6.htm).

Specular Highlight Controls (mk:@MSITStore:C:\PROGRA~1\Autodesk\3DSMAX~1\help\ 3dsmax.chm::/WS1a9193826455f5ffba679e112a6a19004-888.htm)
The topics in this section describe the various controls for different kinds of Standard material highlights.

Edit: and the ambient occlusion is an other story ....

re edit :

i have try the all map present in 3dsmax with the standart material and show after in .mtl :

ambient : map_ka
diffuse : map_kd
specular : map_ks
specular level : not exported in .mtl
glossiness : not exported in .mtl
self-illumination : map_d
opacity : map_ke
filter color : not exported in .mtl
bump : map_bump and bump -bm (why two ???)
reflection : map_refl
refraction : not exported in .mtl
displacement : not exported in .mtl

TheDarkWraith
06-12-12, 09:52 AM
If you look at the texture defined for the Opacity it looks like it's a color key. Maybe the reason why there is no texture defined for the opacity (as viewed in GrannyViewer) is because the path specified in the extendeddata for it specifies the texture to use as the color key. Color keys usually take the first texel in the image to denote transparency. That first texel would make the border around the grass disappear if used as a color key :hmmm:

BIGREG
06-12-12, 10:11 AM
maybe the plants don't have specular ? :hmmm: and the ks is used as "ke" (opacity)
other is three pointers in .gr2 (1 diffuse/ambiente - 1 for specular - 1 for the opacity (same texture as specular and use just the alpha) with other value :06:

in the editor :you have make an add map possibility= "additionnal bump map" ,but i have nothing for that in 3dsmax !?

TheDarkWraith
06-12-12, 11:00 AM
Just as I suspected. That second map, even though it has no texture defined, the game is using the bitmap or File Name entries in it's extendeddata to read a texture and grab the first texel as a color key for transparency. I did a little test to find this out:
- loaded undersea.GR2 in the app
- added the Map#62 material to Grass01's material bindings
- removed Map#63 from Grass01's material bindings
- saved it

Opened it up in Goblin and:
http://www.subsim.com/radioroom/picture.php?albumid=642&pictureid=5736

Theory is correct :D

This means I have to make some drastic changes to my rendering engine and to my material class...

BIGREG
06-12-12, 11:04 AM
take a look too ,on the lens in the sub :03: no texture in material ,just material properties :doh:

TheDarkWraith
06-12-12, 11:10 AM
take a look too ,on the lens in the sub :03: no texture in material ,just material properties :doh:

which GR2 file and which mesh?

BIGREG
06-12-12, 11:15 AM
a have looking in the conning tower CT_lens1 or 2 dito

TheDarkWraith
06-12-12, 11:21 AM
a have looking in the conning tower CT_lens1 or 2 dito

Found it. I see that I'm not using something from the extendeddata of a material - Opacity. That is why the lenses look like they do in Goblin and look totally solid in my app. I'll have to fix that also :shifty:

I always wondered why those lenses on the TDC and clock were rendered solid white with my app. Now I know why!

BIGREG
06-12-12, 11:34 AM
Super,i have try in granny and there are opaque too ,But if you can render them into editor :yeah:
that say you are better than the granny's guys :haha:

edit :

Can you rename the "self-illumination" to "specular" in the editor menu ?

re edit:

the menu

None : -> lens glass ???
Ambiente : Not necessary to view it (attached with diffuse)
Diffuse : the texture color map
Specular : the diffuse alpha chanel
Self-illumination : -> map_d (if you can sort it) eg : lights (sticla)
Opacity : -> map_ke (if you can sort it) eg : the sea plants
Bump : is OK

Optional : reflection: -> map_refl -> the normal use is with the AO but work with the "normal" mesh :hmmm:

Ambiente occlusion :the AO-> as a diffuse map ? -> map_kd ???? anyway we use it with another .obj with other uvw location

BIGREG
06-13-12, 04:25 AM
:salute: Hello

V 1.1.235.1

After testing,i have always the problem to see the opacity in 3DsMax :stare:

and i have decided to found why :yep:

import a fresh original mesh (grass02) with the original texture into 3DsMax

Hum :hmmm: no opacity map and no transparent border in render :cry:

Ok ,i create a new texture .Dds (dxt1) for that, i take the alpha channel from diffuse to create it -> seabed01_O.dds

try to add ... :hmmm: Hum !!! better but something make refflect on the "hidden"...

Tja ! :damn: ... stay calm,stay calm.....:rotfl2:and take the bull by the horns !

Delete the material in 3DsMax en recreate a new with the same textures and use : ambiente,diffuse,specular and add my new texture as opacity

Result : :D Yes ! that work great :woot: ,but in editor this map is not recognized :wah: TDW... Please :cry:

here a view with the exported .mtl :

https://dl.dropbox.com/u/8655607/opacity.jpg

Edit : I have just try to optimize the number of map ,for that i have delete my new material and replace with the same as the diffuse "seabed01.dds"
and change in the opacity the "channel output" to alpha and that work too :D But is better to have the 2 materials to not alterate the specular/ambiente

Conclusion : the opacity (alpha) map must be exported/imported as map_d

re edit :

i can't not export/import the lens (no texture) and without diffuse options error : invalide faces definitions,missing numbers parameters
try to change the lights (i have make 2 subsets) and if i change one material= the illumination don't work anymore of all subsets

BIGREG
06-15-12, 10:22 AM
Hello :salute:

Some test result :

- replace material on "normal" object with lights (sticla) material "bec_submarine" = white map without "illumination"

- replace material with the lens material = bug in goblin/ingame

EDIT :to "illuminate" (as lights) an object ,i have try to create a new material with 2 maps : diffuse(bec_submarine)+a self-illumination(same texture) = work fine :yep:
(that is with GR2 editor and not in 3dsmax) :yeah:

a problem lies in the data exported in .mtl
eg : sticla = ka,kd,ks but only the ks need to be "normally" exported ,but that seem the diffuse need to be exported too :hmmm:

Here a "hot" knob :D :

https://dl.dropbox.com/u/8655607/SH5Img%402012-06-15_19.17.55.jpg

and for that ,the color come from self-illumination map (is my new red texture) and the light from diffuse map (bec-submarine.dds) :doh::hmmm::06:

BIGREG
06-16-12, 08:12 AM
Some news from GR2land :D

Today ,i have tested,the "glass" effect as the lens

And I just realized ,for this, there is no map https://dl.dropbox.com/u/8655607/doh.gif
But colors to replace them (ambient, diffuse, specular) with color choice for each

The trick to create a material "glass" :

name: green_glass
create a new material : no map,no texture
go to the desired mesh -> bind the new material
go to subset -> bind the material
after you need to save/close/reload ( other : no colors values) :hmmm:
go to the modified subset : and change the three colors with green

and finish :woot:

So we can redo real bottles, glasses, various liquids, and the lamps more Detailed: the bulb to light :sunny:, and the translucent cover over :/\\k:

TDW can you add the alpha or strength for change the opacity :06:

ps:we can add render as the lens via the .sim :yep:

mobucks
06-16-12, 08:55 AM
A glass effect that reacts to the sun/light on our watch crew's binoculars would we AMAZING!

BIGREG
06-16-12, 10:01 AM
Here the "glass" knob (with EnvMappingCtlr controller assigned in .sim :D) :

https://dl.dropbox.com/u/8655607/SH5Img%402012-06-16_16.52.21.jpg

But,i have try with sticla and found ,that we can use just one type of material (glass,light effects) per mesh (with all subsets) , and delete all other mesh materials binding
for sticla mesh that seem the transparent effect don't work :hmmm::06:
But off other meshes work great :rock:

What we need now is the possibility of transforming the subsets, in meshes or the ability to import a mesh on a bone (at its creation)

TheDarkWraith
06-16-12, 10:38 AM
From what I've been reading of your postings you're telling me that the following parameters are defined in the mtl file as:
- d: the opacity of the material. Correlates to Opacity in the GR2 material's extended data :06:
- map_d: the AO (self-illumination) map. If this is so it will greatly simplify my importers as I won't have to deal with two different mtl files :yep:

The Illum parameter I will not support. That deals with lighting models and it's way too complicated to add support for all that are defined. My app is not a texture editor, it's a GR2 editor.

We're still in the same problem with the OBJ file not supporting two sets of texture coordinates. Even if I add map_d as being the AO we still need two seperate files so that the texture coordinates for non-AO and for AO can be specified.

BIGREG
06-16-12, 10:50 AM
:salute: Bonjour TDW

- d: the opacity of the material. Correlates to Opacity in the GR2 material's extended data :06:
Yes,but i am not an expert :D if you can try to export the opacity as map_d + if possible ( "d" value ) in .mtl , i can test it :yep:

- map_d: the AO (self-illumination) map. If this is so it will greatly simplify my importers as I won't have to deal with two different mtl files :yep:
We're still in the same problem with the OBJ file not supporting two sets of texture coordinates. Even if I add map_d as being the AO we still need two seperate files so that the texture coordinates for non-AO and for AO can be specified.

Not, a problem is another .obj and we can export/import the uvw coordinates :O:

The Illum parameter I will not support. That deals with lighting models and it's way too complicated to add support for all that are defined. My app is not a texture editor, it's a GR2 editor.

Ok,i understand and we have the ground to make lights :rock:

TheDarkWraith
06-16-12, 11:36 AM
Yes,but i am not an expert :D if you can try to export the opacity as map_d + if possible ( "d" value ) in .mtl , i can test it :yep:

Let's find out if it does correlate or not. Try this:
- open up a GR2 file with the app
- go to it's material that has 3 maps defined
- edit the material's extendeddata to change the opacity from it's current value to some value picked by yourself
- save the file
- open in Goblin and in-game to see if any change or not

Let me know results :up:


I'm adding the 'd' parameter to the exporter and importers currently

BIGREG
06-16-12, 11:51 AM
Here : :woot:

https://dl.dropbox.com/u/8655607/SH5Img%402012-06-16_18.46.08.jpg

BIGREG
06-16-12, 12:02 PM
Let's find out if it does correlate or not. Try this:
- open up a GR2 file with the app
- go to it's material that has 3 maps defined
- edit the material's extendeddata to change the opacity from it's current value to some value picked by yourself
- save the file
- open in Goblin and in-game to see if any change or not

Let me know results :up:


But for that i need to create one with an opacity map ? :88)

on "normal" objects i have just the amb,diff,specular :hmmm:

TheDarkWraith
06-16-12, 12:40 PM
But for that i need to create one with an opacity map ? :88)

on "normal" objects i have just the amb,diff,specular :hmmm:

Why would you? The Opacity parameter in the material's extendeddata is specifying the opacity according to the GR2 file. Just try it and see.

The map_d that you are referring to as opacity map is the self-illumination (AO) map. That has nothing to do with the Opacity in the material's extendeddata.

BIGREG
06-16-12, 01:18 PM
Maybe,But normaly :

Ambiente occlusion is the map with the objects shaders (in 3dsMax)
(more maps are "baked" to make it )

self-illumination is to add "light" to the diffuse map ( in 3DsMax)

Opacity is to make :

"cuts" as the sea bed plants borders
But ingame/editor is the alpha channel from diffuse (but i don't understand how) other "normals" objects use the alpha as ambient or specular

or to make "glass"

But,ingame/editor the glass effect is make without map ,just colors (no map/no texture)
we can change the colors :up:
but not the transparency (no alpha or strenght values)

TheDarkWraith
06-16-12, 01:25 PM
Maybe,But normaly :

Ambiente occlusion is the map with the objects shaders (in 3dsMax)
(more maps are "baked" to make it )

self-illumination is to add "light" to the diffuse map ( in 3DsMax)

Opacity is to make :

"cuts" as the sea bed plants borders
But ingame/editor is the alpha channel from diffuse

or to make "glass"

But,ingame/editor the glass effect is make without map ,just colors (no map/no texture) , we can change the colors :up:
but not how transparent (no alpha or strenght values)

You have to differentiate between 3dsMax rules and SH5 rules. The app plays by the rules defined by SH5 thus many things will not be the same as in 3dsMax.

Opacity in SH5 controls the overall opacity of the material. A material with no maps or texture renders by the colors defined in it's material (ambient, diffuse, and specular). AO or self-illumination in SH5 controls does just what it's supposed to do - provide ambient occlusion (darkening/lightening of areas)

Transparency is defined by the Opacity parameter in the material's extendeddata (and the 'd' parameter in the MTL file)

TheDarkWraith
06-16-12, 01:32 PM
:o I forgot to add the ability to change a material's extendeddata :damn:

I'll add that ability now :yep:

I was going to change the TDC material's Opacity parameter in the extendeddata but saw that I never gave the app the ability to do so.