By JDHill
#288667
Sure, if things are as they should be, I should have your materials as soon as I open the file. I can try to take a look and see if/how things are not being read correctly.
By Fille
#288669
Oh nooo, what's happening... I wonder if there has been some changes to Rhino lately (I have SR5 RC1)?

I made a material disappear from one of my files just by opening another file (containing the same material - just wanted to check something... didn't dare to open another session anymore)... I closed the file, without saving, opened the original file - and the material is gone! I found it in the database, so no panic - at this point. However...
Working with this same file (A), I opened the Database Manager, dragged a material in to the scene from the other file (B), renamed it (!), did some adjustments and saved the file. I then opened file B (to check something again) - the material I had been tweaking in file A were altered also in file B, meaning that I obviously lost the original material in file B as is was replaced with the new material from A! I might have it in the Database Manager. I haven't looked yet. I have almost 100 materials in that file...

Hmmm, the Database Manager was great for dragging materials from another file to the scene I was working on, but now I can't use it for that anymore. Can I disable it somehow?

Some wishes for the future:

I would like the Database Manager to be file specific (no materials from A should show up in B) and newer do these automagic things... It should also allow us to work in multiple files at the same time - including worksessions - and also on different computers. I take my work home with me, work on some stuff and bring an updated file back with me next morning - not that I always have to, but I love my work. :) I would also like materials from an attached worksession file to disappear from the current file as soon as I close the worksession (detach the worksession file) - now they remain in the file and make it a lot heavier than it needs to be. Imaging a file, to which I attach one file one day, another file another day - or even 4 different files at the same time. You get the picture... :)
I would also like to be able to organize my materials in the Scene Manager in a specific order (by dragging them around) and have them stay that way - until I decide otherwise. :wink:

Oh my - this is a long post. I thought I had to tell you right away as this all seem 'a bit' scary...
I hope this helps to figure out what's happening. I still think it's the best Rhino plug-in ever! :) :wink:

Philip
By JDHill
#288671
I opened the Database Manager, dragged a material in to the scene from the other file

Could you clarify what you mean by 'from the other file'? I think what you're not understanding is that dragging a material from the Database Manager into the Scene Manager does not make a copy; that is, if I'm understanding your scenario, your material (A) and (B) are actually the same material. Nothing was lost or replaced, it was just the same material you were working with in both sessions. To work the way it seems you want to work, you need to actually make copies of the materials in each document you want to use them in. There are a few strategies you could use:

1. create materials in new documents by importing MXM files
2. create copies one-by-one by using the 'Clone Material' option in the Scene Manager context menu
3. export a set of materials to a material library, then import that into new documents

Any of these will result in different documents not sharing the same materials.
By Fille
#288688
Hi JD
Could you clarify what you mean by 'from the other file'?
I meant that I was dragging the material from the Volume (with the same name as file B) in the Database Manager into the Scene Manager of file A. I didn't understand that this makes it the same material. Thanks for that! Now it makes sense from a technical point of view.
To work the way it seems you want to work, you need to actually make copies of the materials in each document you want to use them in. There are a few strategies you could use:

1. create materials in new documents by importing MXM files
2. create copies one-by-one by using the 'Clone Material' option in the Scene Manager context menu
3. export a set of materials to a material library, then import that into new documents
Yes, these are the options I use normally use. So everything is 'back to normal' (for my workflow) if I just don't use the Database Manager... right? Hmmm, in that case I can't think of a situation where I would like to use it...
Anyway - thanks for the explanation! Now I can relax. :wink:

What do think about the worksession problems?
Thanks!

Philip
By JDHill
#288738
Sorry, I didn't address that - my current code does not add worksession document materials into the current document - they're used directly from the database. So that should take care of your concerns. About the db manager usage, yes, if you never opened it up, you'd always be creating materials in the ways I listed above, and therefore, they would never be shared between documents.
By Fille
#288800
Hi
Sorry, I didn't address that - my current code does not add worksession document materials into the current document - they're used directly from the database.
Hmmm, the materials from the referenced file do get added to the active file here, when saving (before I detach the referenced file).

Philip
By JDHill
#288814
Sorry, I meant that it will work that way in the next version. :)
User avatar
By caryjames
#288823
Where would I find the materials database in windows? I too had an entire directory disappear and the corresponding materials ( I still have them just not in the database). I had created a Master material file that worked really well for quite a while (with the exception of the non alphabetized names :) ) but that disappeared and most of the materials stayed in a database associated with my Rhino file but I can't find my Master file. I can re import the materials so it is not a huge deal but it would be nice to know where this is saved so that I could go get it quickly if it disappeared again. Thanks!!

P.S. I really like the Materials database :)!!!!!
By JDHill
#288833
The plugin's material database doesn't contain files that would mean anything to you - they are not MXM files, and they have strange and unfriendly names. I am not really clear on the scenario you're describing - where did things disappear from? If something failed, I would assume that you'd open Rhino and have a totally-empty database manager window; is this what happened? Did anything out of the ordinary happen prior to this? Any power outage, Rhino crash, or similar that might explain why it happened?
By Fille
#288839
Sorry, I meant that it will work that way in the next version.
Ha, ha :lol: ... Ok, thanks!

Philip
User avatar
By caryjames
#288846
Hi JD- I had created a folder/node in the material database called Master Materials, these were materials that I used all of the time. I could also see other folders in my database corresponding to different file names and enclosing the materials from those Rhino files.

I have had issues in the past with power outages causing difficulties, however this time I didn't have an outage the folder/node Master Materials was just not there when I turned on my machine. The folder Master Materials just disappeared from my database as did all of the other folders that had materials from different scenes. Some of the materials appeared in a node with the name of my current Rhino file however not all the materials were there.

The reason I was asking where the files for the database were stored was so that I would have a quicker way of updating it it this kind of event ever happened again.

Similar things have happened a couple of times in the past- it is not that big of a deal to load all the materials again. I find the database so useful that the 1/2 hour I spent reorganizing was not that big of an issue.

Thanks again JD the database is very useful - it is still a mystery how you programmed it anyway :)

after a lot of years doing arch-viz... almost 20 a[…]

render engines and Maxwell

Funny, I think, that when I check CG sites they ar[…]

Hey, I guess maxwell is not going to be updates a[…]

Help with swimming pool water

Hi Choo Chee. Thanks for posting. I have used re[…]