|
![](/i/fill.gif) |
> "D103"<nomail@nomail> wrote:
>> Ok, thanks very much. :) I think I'll use the scale pigment, floating point
>> precision errors are not what I need.
>>
>> Regards,
>> D103
>
> Just realised that that would require two declarations of the image. What size
> image would cause fp errors? Current images used are at the most 4096x2048.
>
> Regards
> D103
>
>
>
Thinking about it further, you don't even need to apply the image to an
object.
#declare ColImg= pigment{ image_map {jpeg "my_image.jpg"}}
#declare Res = max_extent(ColImg);
You can now scale the pigment directly:
#declare ColImg = pigment{ ColImg scale<Res.x, Rex,y,1>}
This scales the pigment and reattribute it to the same identifier.
Then, you use eval_pigment directly on the pigment identifier.
It depends...
4096 and 2048 are exact powers of 2, and should not cause any error, or
negilgible ones.
4000 x 3000 WILL cause fp errors.
800 x 600 will also cause fp errors as those values are not powers of 2.
Post a reply to this message
|
![](/i/fill.gif) |