Jose Gonzalez wrote:
> ...
>
> This is great opportunity for those who are evas engineers to start
> thinking/
> working on 'native' implementations for their engine of interest -- I can't do
> *all* engines in x amount of time.. and while a simple mechanism to implicitly
> 'fall-back' to software easily would be nice, that's not quite available right
> now and in any case the point of much of this is to have as 'native' versions
> of things as much as possible.
>
> ...
Hello, Jose!
It's about new Direct3D Evas engine for Win32, that I've developed for
Enlightenment during SoC. For now it is not yet committed to the main code
repository, but I am able to support gradient functionality that you need in
it. I suppose it is necessary to implement all of the eng_gradient2_*
functions. Please contact me and CC Vincent Torri <[EMAIL PROTECTED]> with
details.
The way of implementation of gradients in this engine is not difficult, we can
use pixel shaders capabilities easily. For each gradient type we can make own
pixel shader, for example:
Linear gradient shader:
// Input register data
float4 f4StartPoint : register(c0); // xy in [0; 1] x [0; 1]
float4 f4Direction : register(c1); // xy - normalized, w - length
float4 f4StartColor : register(c2); // rgba
float4 f4EndColor : register(c3); // rgba
float4 main(float2 uv: TEXCOORD0) : COLOR0
{
float2 pos = uv - f4StartPoint.xy;
// saturate - clamp input value in [0; 1]
float f = saturate(dot(pos, f4Direction.xy) / f4Direction.w);
return lerp(f4StartColor, f4EndColor, f);
}
And then just set proper constants when drawing the object.
This would be the most 'native' version for the engine:).
Best regards,
Dzmitry Mazouka
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
enlightenment-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel