Feature requests, bug reports and related discussion
-
MSUdom5
- Posts: 159
- Joined: Sun Jul 20, 2008 6:04 am
- Location: Mississippi, USA
-
Contact:
Post
by MSUdom5 » Sat Nov 08, 2008 6:03 am
Indigo doesn't parse the following:
Code: Select all
def blend(vec3 tex1, vec3 tex2, real blendamt) vec3: (tex1*blendamt)+(tex2*(1.0-blendamt))
def eval(vec3 pos) vec3 : blend(sample2DTextureVec3(0,getTexCoords(0)),
sample2DTextureVec3(1,getTexCoords(0)),
doti(sample2DTextureVec3(2, getTexCoords(0))))
Gives the message:
Fatal Error: IndigoDriverExcep: SceneLoaderExcep: Lexer: Failed to parse int Line 1, column 41 (In element 'shader', around line 66, column 13)
-
Onfame
- Posts: 82
- Joined: Wed Mar 12, 2008 12:32 pm
Post
by Onfame » Sat Nov 08, 2008 7:18 am
This how it works:
def blend(vec3 tex1, vec3 tex2, real blendamt) vec3 : (tex1 * blendamt) + (tex2 * (1.0 - blendamt))
def eval(vec3 pos) vec3 : blend(sample2DTextureVec3(0,getTexCoords(0)),
sample2DTextureVec3(1,getTexCoords(0)),
doti(sample2DTextureVec3(2, getTexCoords(0))))
-
Attachments
-
- thatstheresult.jpg (78.32 KiB) Viewed 2069 times
-
MSUdom5
- Posts: 159
- Joined: Sun Jul 20, 2008 6:04 am
- Location: Mississippi, USA
-
Contact:
Post
by MSUdom5 » Sat Nov 08, 2008 8:06 am
Ah, so you have to have spaces in certain places? Hmm.. tisk tisk...
-
CTZn
- Posts: 7240
- Joined: Thu Nov 16, 2006 4:34 pm
- Location: Paris, France
Post
by CTZn » Sat Nov 08, 2008 8:10 am
You mean blank spaces matters, Onfame ?
obsolete asset
-
Onfame
- Posts: 82
- Joined: Wed Mar 12, 2008 12:32 pm
Post
by Onfame » Sat Nov 08, 2008 8:20 am
YES allways the blank spaces are the bad
AND i changed this:
def blend(vec3 tex1, vec3 tex2, real blendamt) vec3:
to this
def blend(vec3 tex1, vec3 tex2, real blendamt) vec3 :
Ok i tested again the last is not necessary, but if you use +-*/ allways use Blanks.
-
CTZn
- Posts: 7240
- Joined: Thu Nov 16, 2006 4:34 pm
- Location: Paris, France
Post
by CTZn » Sat Nov 08, 2008 8:36 am
AND i changed this:
def blend(vec3 tex1, vec3 tex2, real blendamt) vec3:
to this
def blend(vec3 tex1, vec3 tex2, real blendamt) vec3 :
Do you want to drive me crazy
? Ah no I see it now
Many thanks for the hint, and nice "rojulero" mat !
obsolete asset
-
Onfame
- Posts: 82
- Joined: Wed Mar 12, 2008 12:32 pm
Post
by Onfame » Sat Nov 08, 2008 8:42 am
Sorry my english isn´t that good, what exactly does "rojulero" mean
Who is online
Users browsing this forum: No registered users and 42 guests