|
|
I'm trying to use the HF_ functions in shapes.inc to generate a mesh from a
small .png file.
I simply added a new funtion to the example file given in the include files
demo. When I did, I got an error.
//==============================
#declare MyFunction = function{pattern {bumps scale 0.2}}
// MyFunction above works...
#declare MyTest = function
{ pigment
{ image_map
{png "testHF.png"
map_type 0 interpolate 2
}
}
} // <- this replacement produces an error.
// shapes.inc pops up and marks the bit of code named above
object {
HF_Square
( MyTest, // MyFunction was here, but I replaced it.
off,
off,
<60,60>,
on,
"",
<0.0, 0.1, 0.0>,
<1.5, 0.5, 1.5>
)
texture {
pigment {color rgb 1}
finish {ShinyFinish}
}
translate <-3.0, 0.0,-3.2>
}
// ===========
// The error that happens pops up shapes.inc and a line in the
// HFCreate_() macro gets marked. See note below.
// ====
#local J = 1;
#while (J<=xRes)
#local K = 1;
#while (K<=zRes)
PArr[J][K], // <-- this code gets highlited in yellow
#declare K = K+1;
#end
#declare J = J+1;
#end
//====================================
What do I do to get an image file used as a function?
normdoering
Post a reply to this message
|
|
|
|
On Fri, 8 Nov 2002 02:16:40 EST, "normdoering" <nor### [at] yahoocom> wrote:
> PArr[J][K], // <-- this code gets highlited in yellow
You are trying to put color as float, try pattern as pigment in your function
definition.
Moreover read rules about crossposting posted in faq droup.
ABX
Post a reply to this message
|
|
|
|
On Fri, 08 Nov 2002 05:59:38 -0500, ABX quoth:
> Moreover read rules about crossposting posted in faq droup.
You need to work on your spelling. Everyone *knows* it's "froup", not
"droup". :-)
--
Mark
Post a reply to this message
|
|