Re: [cgkit-user] slparse imporvements
Brought to you by:
mbaas
|
From: Simon B. <si...@re...> - 2009-10-01 22:16:34
|
Hmm not sure about prman 14. I know 13.5 it was a separate download -
I'll have to check.
I have also noticed quite a significant precision issue with 3delight.
This shader (compiled to a sdl):
class test (
uniform float test_uniform_float = 23.6;
uniform color test_uniform_color = color(3.6, 2.1, 1.7);
uniform string test_uniform_string = "hello";
uniform vector test_uniform_vector = vector(45.3, 56.4, 73.2);
uniform point test_uniform_point = point(3.4, 88.2, 9.6);
uniform normal test_uniform_normal = normal(0.6, 0.8, 0.9);
shader test_null_shader = null;
) {
public void surface(output color Ci, Oi;) {
Ci = 1;
Oi = 1;
}
}
returns this result from slparams:
>>> from cgkit import slparams
>>> slparams.slparams("test.sdl")
[('surface', 'test', [('', 'uniform', 'float', None, 'test_uniform_float', None,
23.600000381469727), ('', 'uniform', 'color', None, 'test_uniform_color', 'rgb'
, (3.5999999046325684, 2.0999999046325684, 1.7000000476837158)), ('', 'uniform',
'string', None, 'test_uniform_string', None, 'hello'), ('', 'uniform', 'vector'
, None, 'test_uniform_vector', 'current', (45.299999237060547, 56.40000152587890
6, 73.199996948242188)), ('', 'uniform', 'point', None, 'test_uniform_point', 'c
urrent', (3.4000000953674316, 88.199996948242188, 9.6000003814697266)), ('', 'un
iform', 'normal', None, 'test_uniform_normal', 'current', (0.60000002384185791,
0.80000001192092896, 0.89999997615814209)), ('', 'uniform', 'shader', None, 'tes
t_null_shader', None, None)])]
To complicate things this is using 32 bit Python, 32 bit 3delight on
Windows Vista 64 bit.
Is this a cgkit or a 3delight problem?
Simon
On Wed, Sep 16, 2009 at 11:54 PM, Matthias Baas <mat...@gm...> wrote:
> Hi Simon,
>
> Simon Bunker wrote:
>> Being able to interrogate binary shaders with cgkit is a great new addition.
>>
>> However I was wondering if it could fall back to parsing the output
>> from sloinfo etc. The reason for this is that prman at least, normally
>> doesn't come with the devkit - it is a separate download - and so most
>> people won't have it.
>
> Oh, does that mean the prman library is not installed by default (e.g.
> $RMANTREE/lib/libprman.so on Linux)? I thought the actual renderer and
> the Python stuff would be using this shared library as well, so that it
> would always be available?
> (btw, which version of prman are you referring to? I was basically
> targetting prman 14 and above as previous versions didn't ship with a
> shared library anyway.... or is that what you mean, does prman <14 come
> with a shared library in the devkit? (I never installed prman myself)).
>
> Running and parsing sloinfo shouldn't be a problem. I just have to see
> how it's best integrated into the package so that by default, it's all
> done transparently to the user but, if necessary, the user could also
> control how the shader should be parsed and which sloinfo to use, etc.
>
>> PS good idea to switch to git - it is much nicer to work with than
>> other source control.
>
> In particular, it makes it much easier for me to support Python 2 and
> Python 3 at the same time.
>
> Cheers,
>
> - Matthias -
>
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry® Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay
> ahead of the curve. Join us from November 9-12, 2009. Register now!
> http://p.sf.net/sfu/devconf
> _______________________________________________
> cgkit-user mailing list
> cgk...@li...
> https://lists.sourceforge.net/lists/listinfo/cgkit-user
>
|