D12388: Output device color curves correction

Christoph Feck noreply at phabricator.kde.org
Fri Apr 20 19:45:29 UTC 2018


cfeck added inline comments.

INLINE COMMENTS

> outputconfiguration.h:211
> +     */
> +    void setColorCurves(OutputDevice *outputdevice, QVector<quint16> red, QVector<quint16> green, QVector<quint16> blue);
> +

The documentation could state how many elements need to be in the vectors. Ideally, every component could have any number of elements, and if there are too few, the other elements are interpolated.

But it is probably simpler to just state "The number of elements in each vector must be 256 or 1024, depending on the depth of the framebuffer (24 bits or 30 bits)."

> outputconfiguration_interface.cpp:217
> +        while((char*)pos < (char*)array->data + array->size) {
> +            // TODO: check value not bigger than size (i.e. for 8bit display < 255)?
> +            v->append(*pos);

X11 uses 16 bit values even for 24 bit screens, because the actual values that are sent to the DAC can have higher precision than the screen pixmap. I doubt that Wayland has reduced the precision, so I don't think checking values here is right.

REPOSITORY
  R127 KWayland

REVISION DETAIL
  https://phabricator.kde.org/D12388

To: romangg, #frameworks
Cc: cfeck, michaelh, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20180420/dd0c86a9/attachment-0001.html>


More information about the Kde-frameworks-devel mailing list