Baking Blender's Procedural Textures for use with Indigo

Tutorials/guides/tips on how to use Indigo and the Indigo exporters
User avatar
bq1
Posts: 20
Joined: Wed Sep 13, 2006 8:59 am
Location: Leeds, UK
Contact:

Baking Blender's Procedural Textures for use with Indigo

Post by bq1 » Thu Feb 01, 2007 3:35 am

Ok, here goes. I've never written a tutorial before and I'm no expert on UV mapping, God knows! There will no doubt be mistakes and easier ways to do things, so apologies in advance. Please comment... :)

BAKING BLENDER'S PRCEDURAL TEXTURES FOR USE WITH INDIGO

Versions I used:
Blender 2.42
Indigo 0.5
Blender2Indigo Exporter 0.5beta

1. Open blender, delete the default cube and add a UV sphere ([Spacebar] -> Add -> Mesh -> UVSphere). I rotated mine around for a bit so the texture would be more interesting. (I know, texture-rotate, but I cheated...)

2. Now set up a material for it as indicated below (or whatever you like really :) ), by upping the colour to white and adding the two wood textures.

Image

3. Split your screen so you have a 3D window and UV/Image editor visible. In the 3D window switch from 'Object Mode' to 'UV Face Select', making sure your sphere is selected.

Image

4. Press 'a' in the 3D window to select all faces, then in the UV/Image Editor, create a new image (Image -> New...). I used 512x512.

5. Still in the UV/Image Editor window, select the 'Archimap UV Projection Unwrapper' script from the 'UVs' menu. I used the following options:

- Fill in holes (space efficient, slow)
- Unwrap all ... (this won't matter if you selected all the faces)
- ...then just use the defaults for the last two settings.

Image

6. Then select the 'Texture Baker' script from the 'UVs' menu in the UV/Image Editor window. Note: If you use a screen-resolution of 800x600 (like me) you'll have [Ctrl-UpArrow] to maximise that window to access the upper part of the menu. I used the following options:

- No replace
- Size: 512

edit: OR see the post below regarding superior "Bake Render Meshes" in 2.43

Image

7. When the UV map renders (and this was an epiphany for me ;) ), press F3 to save it. I called it 'wood-tex.png'.

Image

8. Now that we have an image to work with, we can remove the procedural textures from our sphere. With the sphere selected, go to the Materials pane in the Buttons window and clear the textures out.

Image

9. Now, in the Texture pane, add a new image texture and load in the file we just 'baked'. Doesn't hurt to give the texture a meaningful name. ;).

Image

10. Back in the Materials pane, with the new texture selected, set up the mapping as follows...

Image

11. A quick Blender-render shows us our result. It's not bad, but the seams are visible.

Image

12. If you go back to 'UV Face Select' mode in the 3D window with the sphere selected, select all it's faces, then load the baked image into the UV/Image editor you can see where the problems lie, as below.

Image

13. There are probably various ways of tackling this, but just for now I'm going to move the UV map up a little bit, then do the following to each of the six UV 'areas'.

a) Select a UV point, then press [Ctrl+L] to select the other linked points in that 'area'
b) Hit to scale, then type .995 to scale it down just a teeny bit.
c) Hit [Enter] to apply the scale.

Image

14. That's a bit better! Ok, so now let's export to Indigo in the usual way and render to see what happens. BEFORE YOU START THIS make sure that you've copied the baked image to the Indigo directory, and if you have trouble with it not rendering the texture, try converting the file to a JPG instead of PNG, remembering to change the relevant texture path in the XML. I had to do this so be prepared for it.

I ended up with the image below

Image

You can still clearly see the seams, but with tweaking I'm sure they could be overcome. Maybe scaling those 'areas' by .995 was a bit light-handed, or perhaps there's an tiny offset between Blender and Indigo?

I suppose you could also create some nice bump maps using this technique too. I'll be playing with it for a while, no doubt. :) Anyways, time for coffee.
Last edited by bq1 on Thu Feb 01, 2007 11:45 pm, edited 4 times in total.

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

Post by zsouthboy » Thu Feb 01, 2007 4:13 am

Kick ass!

Thanks for the tut.

Now you have me wanting to automate this whole process somehow. Hmm.

User avatar
drBouvierLeduc
Posts: 412
Joined: Wed Oct 11, 2006 2:32 am
Location: france

Post by drBouvierLeduc » Thu Feb 01, 2007 6:36 am

In order to avoid the seeds, you can use the render baking feature of blender 2.43 like this :
(follow the tutorial, except for step 6)

STEP 6 :
Do not use the script, instead go to "render --> bake-render meshes --> textures only" (ALT + Ctrl B) wich will do better then the script.

Here is a quick test, procedural texture + bump map (the same in b&w) (for a wall in rough coat) :
Image

Kachu
Posts: 54
Joined: Tue Sep 19, 2006 9:12 am

Post by Kachu » Thu Feb 01, 2007 11:33 am

Thanks I thought there was something like alt b or something like that.
Everyone else is doing it so : Core 2 duo E6600, 2 gb ram, Nvidia 8800 640 GTS and 250 gb hd

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

Post by neepneep » Thu Feb 01, 2007 11:38 am

:shock: :shock: :shock: :shock: :shock: :shock: :shock: :shock:

User avatar
bq1
Posts: 20
Joined: Wed Sep 13, 2006 8:59 am
Location: Leeds, UK
Contact:

Post by bq1 » Thu Feb 01, 2007 11:51 pm

Have followed same steps, but used Bake Render. As you can see, the results are much better. :D Just the teeniest seam...

Image

Also, replaced thumbnails with full-size images above, as I understand this was giving some people headaches.

User avatar
afecelis
Posts: 748
Joined: Tue Aug 01, 2006 4:14 am
Location: Colombia
Contact:

Post by afecelis » Fri Feb 02, 2007 2:00 am

wow! Ultra kill! 8)
AMD Ryzen 7 1800 @3.6ghz, 32GB ddr4 3200 mhz Ram, 2X Nvidia Gtx 1070 8GB, Win10/Elementary OS 5.0 Juno (ubuntu 18.04), Blender/Sketchup/Modo/Cinema4d

User avatar
drBouvierLeduc
Posts: 412
Joined: Wed Oct 11, 2006 2:32 am
Location: france

Post by drBouvierLeduc » Fri Feb 02, 2007 4:00 am

I played a bit with blender procedural textures to indigo.
I don't usually use procedural textures because they look too much cg, but for some particular materials and bump maps in general, they are perfect.
The good thing is once you find a nice material, you can use it with any object you want, no wonder how big and complicated it is (and you don't waste your time tweaking the uv-map for hours)
So thanks for pointing this technique.

Here is another quick test for a stained metal :
Image

User avatar
jurasek
Posts: 247
Joined: Sun Jun 25, 2006 11:23 pm
Location: Poland

Post by jurasek » Fri Feb 02, 2007 7:19 am

drBouvierLeduc wrote: Here is another quick test for a stained metal :
:shock: great image

greetz,
jur

User avatar
CTZn
Posts: 7240
Joined: Thu Nov 16, 2006 4:34 pm
Location: Paris, France

Post by CTZn » Fri Feb 02, 2007 9:13 am

Also, replaced thumbnails with full-size images above, as I understand this was giving some people headaches.
Hehe, who was that ?

:arrow: :mrgreen:

I'm basically a procedural lover, because bitmaps are just finite :x

That's an example I did with Maya, amongst many, so you understand why I'm eagerly waiting for OBJ texture support :twisted:

Natural/Man Made Surface

Thanks bq1 !

User avatar
VictorJapi
Posts: 58
Joined: Sun Jan 21, 2007 1:27 am
Location: Zamora - Algeciras || España

Post by VictorJapi » Fri Feb 02, 2007 10:26 am

Bake ... what a lovely feature xDDDD
winmain(){
japi victorJapi;
victorJapi::Signature();
}

User avatar
bq1
Posts: 20
Joined: Wed Sep 13, 2006 8:59 am
Location: Leeds, UK
Contact:

Post by bq1 » Sat Feb 03, 2007 2:11 pm

@drBouvierLeduc: Very nice!

@CTZn: Is that a procedural??

I'm also a huge fan of the procedural texture. We are, after all, all procedurals of one sort or another. ;) And with enough work you can get some pretty amazing results using procedural texs. I've seen woods that are pretty damn realistic with just a few layers of noise.

That's why I think the UV baking thing is so cool when used with Indigo. I can do my proc-tex thing and STILL use a kick-ass renderer! Someone must be doing this already, but it was news to me! :)

User avatar
OnoSendai
Developer
Posts: 6215
Joined: Sat May 20, 2006 6:16 pm
Location: Wellington, NZ
Contact:

Post by OnoSendai » Sat Feb 03, 2007 2:30 pm

Thanks a lot for ur tut bq1.

And nice image drBouvierLeduc!

lorem
Posts: 2
Joined: Thu May 03, 2007 5:17 am

Archi Map UV projection Unwrapper

Post by lorem » Thu May 17, 2007 8:52 pm

Hello I just would like to ask where I can find this script?
I didnt find it in standrad blender instalation and even cannot find it over the internet. Please advice it seams to be useful thing.

Thanks a lot

lorem

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

Post by Kram1032 » Thu May 17, 2007 9:58 pm

Blender 2.44
It's not at all a script ;)
except, you mean the VERY first part, in that case, it's a script, that's included by default in blender.
But I recomend you, use the 2.43 feature, which is much better.
You can find it in the render tab.
there is "Anim" and next to it "Bake"

Post Reply
17 posts

Who is online

Users browsing this forum: No registered users and 3 guests