<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Jan 23, 2014 at 2:24 AM, Marek Olšák <span dir="ltr"><<a href="mailto:maraeo@gmail.com" target="_blank">maraeo@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Thu, Jan 23, 2014 at 4:17 AM, Mark Mueller <<a href="mailto:markkmueller@gmail.com">markkmueller@gmail.com</a>> wrote:<br>
> Hi Merek,<br>
<br>
I'm Marek.<br>
<div><div class="h5"><br>
><br>
><br>
><br>
><br>
><br>
> On Wed, Jan 22, 2014 at 2:49 PM, Marek Olšák <<a href="mailto:maraeo@gmail.com">maraeo@gmail.com</a>> wrote:<br>
>><br>
>> Hi Mark,<br>
>><br></div></div><div class="im">
><br></div></blockquote><div>[...] </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
><br>
><br>
>> Also, I have a proposal for SRGB formats. MESA_FORMAT_SRGB_UNORM8 and<br>
>> MESA_FORMAT_SA8B8G8R8_UNORM<br>
>> look weird, because they are not really UNORM and there is also no<br>
>> stencil. :) How about this: MESA_FORMAT_RGB_SRGB8 (denoting an array<br>
>> format of the SRGB type and 8 bits per channel) and<br>
>> MESA_FORMAT_A8B8G8R8_SRGB (denoting a packed format of the SRGB type).<br>
><br>
><br>
</div>> I agree it could be better. My reasoning for avoiding what you suggested is<br>
> that it creates an ambiguity between color information and storage type. For<br>
> instance, sRBG color space values could feasibly be stored as floats, half<br>
> floats, snorms, or unorms, could they not? Thus the S is a color component<br>
<br>
I don't think so. An sRGB channel is always a byte. You cannot store<br>
both linear and sRGB values in an 8-bit format without losing<br>
precision for either one of them, which I think is why there are sRGB<br>
formats for sRGB values and other formats for linear values. Bigger<br>
texture types do not suffer from this limitation so much. Also, sRGB<br>
is not very well defined outside of the range [0, 1], which leaves<br>
UNORM as the only suitable type.<br></blockquote><div><br></div><div>That works for sRGB, but what about other color spaces that may be added in the future? I'm fine with leaving that to another day and with using the _SRGB decoration, as you say.</div>
<div> </div></div></div></div>