ScriptSpot home

Forum topic · General Scripting

PNG Generation from material

By david · 2013-04-22

Description

Dear Team and Users,

i would like to kow if it is possible to generate a png or jpg directly from material COLOR properties (ambiant diffuse, specular )

Will it be possible to have a script or a path pointing the right direction ?

thanks in advance

david

Comments (2)
miauu

You want to create png image with the color equal to diffuse color of material? This is possible.
Adapt this to you needs:


(
	b = bitmap 100 100 color:red
	b.filename = "C:\\qqq\\1234.png"
	save b quiet:true
)
Reply to miauu
david

image creation

Thanks alot that is wonderfull and seems super easy
from your sample the only thing to do is getting the diffuse, specular value from material? ,is it easy ?
i will dig this more.

thanks again