[Bf-committers] Dithering
Ton Roosendaal
ton at blender.org
Mon Nov 1 16:28:43 CET 2004
Hi,
It's in CVS now. I have some remarks however;
- You used this formula:
dither_value = (BLI_frand()*2.0-1.0)*R.r.dither_intensity/255.0;
BLI_frand() however (is docced in its .h) returns 0.0-1.0, so not
needed. :)
- You applied the dither in the old renderer before color was gamma
corrected. That results in total loss of the dither then. I've added it
after, and nicely with shorts.
- Due to primitive state of old render code, the results for unified
render are much better. It can be fixed for old render too, but would
involve too many changes just before release.
Thanks!
-Ton-
On 1 Nov, 2004, at 14:34, Goran Kocov wrote:
> That's great to hear! I can't wait to see my first
> Blender experiment find it's way into CVS :)
>
> Thanks very, very much,
> Goran
>
> --- Ton Roosendaal <ton at blender.org> wrote:
>
>> Hi,
>>
>> Thanks for the update with recent cvs. :)
>> I've read the patch, and code looks clean and not
>> intrusive or risky.
>>
>> Applying & testing patch bubbled to the top of my
>> agenda, but not
>> tonight anymore... more tomorrow.
>>
>> -Ton-
>>
>>
>> On 31 Oct, 2004, at 11:58, Goran Kocov wrote:
>>
>>> A small bugfix update. The patch for the 31.10.04
>> CVS
>>> and the package containing the changed and the
>>> original sources can be downloaded from:
>>>
>>>
>>
> http://www.geocities.com/gkocov/misc/dither.patch.txt
>>>
>>
> http://www.geocities.com/gkocov/misc/blender_dither_code.tar.gz
>>>
>>> Goran
>>>
>>> --- Goran Kocov <gkocov at yahoo.com> wrote:
>>>
>>>> Hi everybody!
>>>>
>>>> One of the biggest problems I have with Blender's
>>>> internal renderer is that it doesn't do any
>>>> dithering
>>>> to the output while converting the floating point
>>>> values to 8-bit integer values, resulting in
>>>> noticable
>>>> banding in some cases.
>>>>
>>>> While it shouldn't be very hard to implement
>> this,
>>>> it
>>>> seems that it isn't high on the developers'
>> priority
>>>> list, so I decided to try and implement it
>> myself.
>>>> I've made some very simple changes to the
>> renderer,
>>>> to
>>>> the Struct-DNA and to the render output panel,
>> and
>>>> as
>>>> far as I can tell, (with dithering on) the
>> banding
>>>> is
>>>> pretty much nonexistant now. Also I've done some
>>>> basic
>>>> testing both with stills and with animations and
>> I
>>>> couldn't notice any bugs/problems. Check this
>> topic
>>>> on
>>>> the blender.org forums for example images
>>>>
>>>>
>>> http://www.blender.org/modules.php?
>>> op=modload&name=phpBB2&file=viewtopic&t=4837
>>>>
>>>> Here's a patch made from the 27.10.2004 CVS (I've
>>>> never made a patch before, so be prepared for a
>>>> bumpy
>>>> ride, sorry!).
>>>>
>>>>
>>>
>>
> http://www.geocities.com/gkocov/misc/dither.patch.txt
>>>>
>>>> If there are any problems with the patch there's
>> a
>>>> tar.gz archive containing the original sources,
>> the
>>>> changed sources and the differences between them
>>>> (it's
>>>> from a slightly older CVS - 21.10.2004, but that
>>>> shouldn't be a big problem).
>>>>
>>>>
>>>
>>
> http://www.geocities.com/gkocov/misc/blender_dither_code.tar.gz
>>>>
>>>> This is my first time working with Blender's code
>>>> and
>>>> I don't have much C/C++ experience, so please be
>>>> gentle on me. :)
>>>>
>>>> Goran
>>>>
>>>>
>>>>
>> __________________________________________________
>>>> Do You Yahoo!?
>>>> Tired of spam? Yahoo! Mail has the best spam
>>>> protection around
>>>> http://mail.yahoo.com
>>>> _______________________________________________
>>>> Bf-committers mailing list
>>>> Bf-committers at projects.blender.org
>>>>
>>>
>>
> http://projects.blender.org/mailman/listinfo/bf-committers
>>>>
>>>
>>>
>>>
>>>
>>> __________________________________
>>> Do you Yahoo!?
>>> Yahoo! Mail Address AutoComplete - You start. We
>> finish.
>>> http://promotions.yahoo.com/new_mail
>>> _______________________________________________
>>> Bf-committers mailing list
>>> Bf-committers at projects.blender.org
>>>
>>
> http://projects.blender.org/mailman/listinfo/bf-committers
>>>
>>>
>>
> -----------------------------------------------------------------------
> -
>>
>> --
>> Ton Roosendaal Blender Foundation ton at blender.org
>> http://www.blender.org
>>
>> _______________________________________________
>> Bf-committers mailing list
>> Bf-committers at projects.blender.org
>>
> http://projects.blender.org/mailman/listinfo/bf-committers
>>
>
>
>
>
> __________________________________
> Do you Yahoo!?
> Yahoo! Mail Address AutoComplete - You start. We finish.
> http://promotions.yahoo.com/new_mail
> _______________________________________________
> Bf-committers mailing list
> Bf-committers at projects.blender.org
> http://projects.blender.org/mailman/listinfo/bf-committers
>
>
------------------------------------------------------------------------
--
Ton Roosendaal Blender Foundation ton at blender.org
http://www.blender.org
More information about the Bf-committers
mailing list