Glass + liquid rendering...

Announcements, requests and support regarding the Blender Indigo export script
ReinaDelSur
Posts: 16
Joined: Mon Dec 24, 2007 6:37 pm

Glass + liquid rendering...

Post by ReinaDelSur » Mon Dec 24, 2007 7:00 pm

Hey y'all,

I'm currently working on this project which involves an hourglass full of colored red water which would drip down into the lower part. I haven't started the FluidSim part just yet, and am just trying to render the hourglass and the liquid in Indigo, but I seem to be running into some trouble. I'm such a newbie, hopefully my sort of question hasn't yet been answered in one of those threads... (I searched the forum but didn't seem to hit on anything relevant).

Here's the blend file, so you can know what I'm actually talking about...
http://rapidshare.com/files/78699500/Sp ... blend.html

I know I still have to turn all the Blender lights into emitter planes, as they're not fit for Indigo (the project's still in its early stages, and I first tried rendering with BlenderInternal).

Indigo doesn't seem to render the liquid inside, and the body of my hourglass is not transparent (it roughly reflects the sky)... I don't know what I'm doing wrong, although I did try to heed all the advice I could find in Indigo manuals or tuts (I've been working on that hourglass on and off for a month now. And have started anew a countless number of times...): I modelled the liquid overlapping the glass, modelled the meniscus, set up my materials so that the glass had more precedence than the water (because glass displaces water). I even tried cranking up like mad both Max Num Consec Reject and Max Depth (although I'm not even sure I understand what they're about) as I seemed to read somewhere on the Indigo website that they both controlled the number of light bounces and how biased Indigo is (so I upped it all thinking I didn't care for computation times for the moment, and that I would see later...)

Even the "wooden" stick I put there temporarily to check whether the glass & liquid refracted correctly is blueish, when it should have a diffuse ocre-ish material. I must be doing something wrong big time....

Thanks for your help,

Ari ;o)
Attachments
Rendered_Hourglass.png
Here's my failed render :((
Rendered_Hourglass.png (863.61 KiB) Viewed 8415 times

User avatar
Kram1032
Posts: 6649
Joined: Tue Jan 23, 2007 3:55 am
Location: Austria near Vienna

Post by Kram1032 » Mon Dec 24, 2007 10:54 pm

Looks like you didn't use different precedences ;)

ReinaDelSur
Posts: 16
Joined: Mon Dec 24, 2007 6:37 pm

Post by ReinaDelSur » Tue Dec 25, 2007 2:58 am

I did ! Precedence for glass is 100 when precedence for colored water is 10. I didn't touch the precedence for the stick as it didn't interact with anything...

Merry Christmas!

Ari ;o)

User avatar
zsouthboy
Posts: 1395
Joined: Fri Oct 13, 2006 5:12 am

Post by zsouthboy » Tue Dec 25, 2007 5:04 am

Your glass doesn't have "thickness", at first glance. (In fact, that doesn't look like glass material at all - it looks like you may have exported without any material definitions, and all your objects got diffuse grey)

ReinaDelSur
Posts: 16
Joined: Mon Dec 24, 2007 6:37 pm

Post by ReinaDelSur » Tue Dec 25, 2007 2:48 pm

Yeah, well, that's exactly what I don't understand. Look at the blend file, I can assure you that the glass is thick (I modelled it the way they said it should be), and the materials have been exported with careful settings (I'm sure of that because I've been tweaking the precedence bit, and then all the rest around it.)

Anyway, as the materials were already defined in Blender, they get exported (sort of) into Blendigo, and I usually just need to fine-tune them. Well, they did get exported in the Blendigo script window (as I remember modifying some settings), but they don't get exported to Indigo apparently, which in turn, does not render them, but a diffuse gray instead.

I'm really drawing a blank here. Is this a bug?!? How could I make sure Indigo does get the materials I defined in the exporter window (without having to code a damn XML file...)?

Thanks guys for all your ideas...

Ari ;o)

User avatar
suvakas
3rd Place Winner
Posts: 2613
Joined: Mon Sep 04, 2006 11:08 pm
Location: Estonia
Contact:

Post by suvakas » Tue Dec 25, 2007 10:29 pm

ReinaDelSur wrote:I did ! Precedence for glass is 100 when precedence for colored water is 10. I didn't touch the precedence for the stick as it didn't interact with anything...

Merry Christmas!

Ari ;o)
Try to swap your precedence values. Glass has to have lower precedence than the water inside. If it's greater, then it "overwrites" the water inside and water becomes glass.

User avatar
Kram1032
Posts: 6649
Joined: Tue Jan 23, 2007 3:55 am
Location: Austria near Vienna

Post by Kram1032 » Tue Dec 25, 2007 11:32 pm

What suv said, except!
If the hour-glass isn't totally solid, but has walls, it should be just fine ;)

What's your IoR? Does it have transparency? (Did you check the transparent-button?) From this image, it's not sure, whether it's transparent or reflective... The sky doesn't give any Info about that.

Did you use PT or Hybrid? You definitely didn't use MTL... right?

ReinaDelSur
Posts: 16
Joined: Mon Dec 24, 2007 6:37 pm

Here are my precise settings...

Post by ReinaDelSur » Wed Dec 26, 2007 1:39 am

Things keep getting weirder every day. I decided to start rerendering today to check whether all my settings were correct and I now get something "different", to say the least (check out that wonderful black picture with a white glowing stick!)

I really don't know what I'm doing wrong, so I decided to post a screencap of ALL my Blendigo settings when exporting. Hopefully you guys can spot my mistake and tell me how to fix it. Thanks SUV & KRAM for your advice, and I did change precedence order, when I suddenly realized "no." meant "number" (DUH!). So as you'll see, glass is now 1 and water is now 2.

Again, thank you for your help and time.

Ari ;o)

@ Kram: I don't know what PT is but from the settings you can see I used Hybrid AND Metropolis (if that's what MTL means...). I also included a screencap of the curves I drew to spin the hourglass and the liquid inside, so you can tell me whether they are adequate...
Attachments
New render.png
Weird and wondrous...
New render.png (80.55 KiB) Viewed 8174 times
Indigo settings.gif
My Blendigo export settings
Indigo settings.gif (100.78 KiB) Viewed 8175 times
Hourglass curves.gif
Hourglass + liquid curves
Hourglass curves.gif (12.78 KiB) Viewed 8177 times

neepneep
Indigo 100
Posts: 413
Joined: Wed Jun 28, 2006 10:21 am

Post by neepneep » Wed Dec 26, 2007 1:50 am

Try using regular transparency and not glossy transparency :D

ReinaDelSur
Posts: 16
Joined: Mon Dec 24, 2007 6:37 pm

Nope... :((

Post by ReinaDelSur » Wed Dec 26, 2007 2:08 am

Specular instead of Glossy Transparent doesn't seem to work any better, I'm afraid. Everything is still rendering black except for white glowing stick (I so don't understand why the stick wants to emit light BTW as it's got a diffuse shader...)

neepneep
Indigo 100
Posts: 413
Joined: Wed Jun 28, 2006 10:21 am

Post by neepneep » Wed Dec 26, 2007 3:26 am

Ah ha...Your normals on the INNER glass mesh and the TOP liquid mesh are inverted.

edit: compare this hourglass with your one and you will see...
Attachments
hourglass_test.zip
(74.93 KiB) Downloaded 244 times
Last edited by neepneep on Wed Dec 26, 2007 3:29 am, edited 1 time in total.

ReinaDelSur
Posts: 16
Joined: Mon Dec 24, 2007 6:37 pm

Post by ReinaDelSur » Wed Dec 26, 2007 3:29 am

Should I go for the recalculate normals outside blablabla thingy?

I'll try it and tell you what the result is...

EDIT: OH GOD! So the normals for the glass should be facing outwards when outside but INWARDS when inside?!?!?!! How am I suppposed to shift them back now, knowing I wanted to avoid a normals problem and therefore "recalculated normals outside" I don't know how many times...

Other than that, I don't know what the problem with the top liquid's normals are, though. Or is it that they should ALSO be facing inwards? (which --if it's the case-- does not really make sense to me...)

Thanks,

Ari ;o)
Last edited by ReinaDelSur on Wed Dec 26, 2007 3:37 am, edited 1 time in total.

User avatar
DaveC
Posts: 596
Joined: Mon Sep 11, 2006 12:20 am
Location: The Tottenham, London, UK
Contact:

Post by DaveC » Wed Dec 26, 2007 3:29 am

I have solved your problem for you. First, as mentioned by neepneep, your normals on the inner faces of the egg-timer are facing the wrong way. select them and flip them. Secondly, your egg-timer is over 11 meters tall. Very thick glass. Scale it down to 0.02 of it's current size and apply the scale. Then try it again. It should work. It did for me ;)
Last edited by DaveC on Wed Dec 26, 2007 3:35 am, edited 1 time in total.
The hardest part of BEING yourself is FINDING yourself in the first place...
http://thebigdavec.googlepages.com

neepneep
Indigo 100
Posts: 413
Joined: Wed Jun 28, 2006 10:21 am

Post by neepneep » Wed Dec 26, 2007 3:32 am

ReinaDelSur wrote:Should I go for the recalculate normals outside blablabla thingy?

I'll try it and tell you what the result is...
Dont bother with recalc normals outside because it wont work.
You must do it manually :D

lar111
Posts: 81
Joined: Sun Jun 24, 2007 7:29 pm

Post by lar111 » Wed Dec 26, 2007 3:41 am

I had a quick look at your blend file and its a weird problem, your materials aren't being exported. I'm not sure if others foud the same thing. I also got the same dark render at first, turn off extra atmospheric under the enviroment tab and move the sun a bit and you get a lit render. Oh yes and as others have mentioned the normals on the inside are pointing the wrong way( try selecting one vertices of the inside surface and then ctrl L to select linked and then flip the normals of the selected). But that still doesn't solve your problem, the materials are not being exported, and every thing is getting assigned the default material (diffuse grey). I think its a problem with blender, for some reason the materials don't seem to be linked with the meshes like normal. I found that if I created a new object and assigned it a material, that the new object wound render as expected . But I don't know enough about blender or the how the exporter works to be able to help any further.

Post Reply
24 posts

Who is online

Users browsing this forum: No registered users and 6 guests