Error "Rect" + FastExt Shadow Lod

Archives Forums/Blitz3D Bug Reports/Error "Rect" + FastExt Shadow Lod

Yue(Posted 2012) [#1]




SetBuffer TextureBuffer(SecondShadowTexture)
k# = ShadowRange(FirstShadow) /  ShadowRange(SecondShadow)
w# = k * (TextureWidth(SecondShadowTexture) - 2.0)
h# = k * (TextureHeight(SecondShadowTexture) - 2.0)
x# = (1.0-k) / 2.0 * TextureWidth(SecondShadowTexture)
y# = (1.0-k) / 2.0 * TextureWidth(SecondShadowTexture)
Color 255, 255, 255
Rect x, y, w, h, 1
SetBuffer BackBuffer()



Help me please!!

Last edited 2012

Last edited 2012


Floyd(Posted 2012) [#2]
You might try using "Color 255, 0, 255" instead of white. That should make it easy to see what Rect is doing.

Also, Rect is using x,y,w,h. Check the values of those variables. Are the numbers reasonable?


Yue(Posted 2012) [#3]
Hello, I appreciate your help with the data you have given me and the change in distance of the shadow of the line no longer appears white if a black one, I think it's better that way but do not expect to see anything.

These are the variables of valors rect, 60 and 400.

Local PrimerSombra.Shadow = CreateShadow(PCS%)
ShadowRange PrimerSombra, 60
ShadowPower PrimerSombra,.7
Local Primer_SombraTextura% = ShadowTexture(PrimerSombra)


Local SegundaSombra.Shadow = CreateShadow(PCS%)
ShadowRange SegundaSombra, 400
ShadowPower SegundaSombra,.7
Local Segunda_SombraTextura% = ShadowTexture(SegundaSombra)

Setbuffer TextureBuffer (SecondShadowTexture)
k = # ShadowRange (FirstShadow) / ShadowRange (SecondShadow)
w # = k * (TextureWidth (SecondShadowTexture) - 2,0)
H # = k * (TextureHeight (SecondShadowTexture) - 2,0)
# x = (1,0 k) / 2.0 * TextureWidth (SecondShadowTexture)
y # = (1,0 k) / 2.0 * TextureWidth (SecondShadowTexture)
Color de 255, 0, 255
Rect x, y, w, h, 1
Setbuffer BackBuffer ()







Thanks!! Help Me =)

Edit:

If I am stupid, change the color in another Rect ... the thing is well with the data you have given me.



The idea is that the difference Rect two textures, shown in the distance that is less caldiad and showing the closest shade that is of higher quality, however the idea is that white box appears .. . but I realized that if I do not use color in the Rect, get the black box, the example uses white fastext

http://youtu.be/4s6lKdUtmcs

Last edited 2012

Last edited 2012