• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mosra / magnum / 962 / 1
20%
master: 20%

Build:
DEFAULT BRANCH: master
Ran 21 Aug 2017 09:11PM UTC
Files 325
Run time 25s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

21 Aug 2017 08:17PM UTC coverage: 77.549%. Remained the same
TARGET=desktop

push

travis-ci

mosra
<a href="https://github.com/mosra/magnum/commit/<a class=hub.com/mosra/magnum/commit/929329b1f8363ac5e6f8688423c6c6854014865e">929329b1f<a href="https://github.com/mosra/magnum/commit/929329b1f8363ac5e6f8688423c6c6854014865e">&quot;&gt;Fix the ability to create sRGB textures on ES2/WebGL1.

Since </a><a class="double-link" href="https://github.com/mosra/magnum/commit/<a class="double-link" href="https://github.com/mosra/magnum/commit/98a676ef653fc956b375712bc7765e622a6dd2e9">98a676ef6</a>">98a676ef6</a><a href="https://github.com/mosra/magnum/commit/929329b1f8363ac5e6f8688423c6c6854014865e">, on ES2 and WebGL1 the
Texture::setStorage() emulation passes the pixel format to both &lt;format&gt;
and &lt;internalFormat&gt; of glTexImage() APIs. On desktop the go-to way to
create a sRGB texture is by passing GL_SRGB to &lt;internalFormat&gt; and
GL_RGB to &lt;format&gt;, but here GL_RGB was passed to both and thus the
information about sRGB was lost.

With the new PixelFormat::SRGB and PixelFormat::SRGBAlpha enums that
are present only on ES2/WebGL1 this case is fixed -- sRGB texture format
will get translated to sRGB pixel format and that used for both
&lt;format&gt; and &lt;internalFormat&gt;.

Another case is when EXT_texture_storage is available -- passing unsized
GL_SRGB_EXT or GL_SRGB_ALPHA_EXT to glTexStorageEXT() is an error and
there&#39;s apparently no mention of this in any extension, making it
impossible to create sRGB textures using EXT_texture_storage. I bit the
bullet and tried passing the (numerical value of) GL_SRGB8 and
GL_SRGB8_ALPHA8 to it. At least on my NV it worked, so I enabled these
two in TextureFormat for ES2. No EXT_texture_storage is on WebGL1, so
they are only on ES2.

These two sized TextureFormat::SRGB8 and TextureFormat::SRGB8Alpha8
formats are translated to GL_SRGB and GL_SRGB_ALPHA and so using them
unconditionally for all platforms (except WebGL1) "just works".

5720 of 7376 relevant lines covered (77.55%)

437605.61 hits per line

Source Files on job 962.1 (TARGET=desktop)
  • Tree
  • List 0
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 962
  • Travis Job 962.1
  • 929329b1 on github
  • Prev Job for TARGET=desktop on master (#960.1)
  • Next Job for TARGET=desktop on master (#965.1)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc