Questions tagged [gamma]

Gamma questions pertain to non-linear responses in the display chain. The application, adjustment or compensation for gamma, as well as the consequences of doing or not doing so are common subjects.

164 questions
48
votes
2 answers

gamma correction formula : .^(gamma) or .^(1/gamma)?

I'm looking for a simple gamma correction formula for grayscale images with values between 0 and 255. Let's say that the gamma of my screen is 2.2 (it's an LCD screen so I would probably need to estimate it with a more complicated procedure, but…
user42174
  • 695
  • 1
  • 6
  • 11
27
votes
2 answers

Do I need to gamma correct the final color output on a modern computer/monitor

I've been under the assumption that my gamma correction pipeline should be as follows: Use sRGB format for all textures loaded in (GL_SRGB8_ALPHA8) as all art programs pre-gamma correct their files. When sampling from a GL_SRGB8_ALPHA8 texture in a…
Peter Clark
  • 2,863
  • 3
  • 23
  • 37
15
votes
3 answers

Color spaces, gamma and image enhancement

Color space. Well, everybody knows about RGB: three values normalized in the range [0.0,1.0], which have the meaning of the intensity of the color components Red Green Blue; this intensity is meant as linear, isn't? Gamma. As far I can understand,…
Luca
  • 11,646
  • 11
  • 70
  • 125
12
votes
2 answers

Correct usage of SetDeviceGammaRamp

I'd like to add the ability to adjust screen gamma at application startup and reset it at exit. While it's debatable whether one should tamper with gamma at all (personal I find it useless and detrimental), but hey, some people expect being able to…
Damon
  • 67,688
  • 20
  • 135
  • 185
12
votes
4 answers

How can I make Internet Explorer not change the colors in my PNG images

When using PNG files (made with Paint.NET) as background images on my web site, IE7 is changing the colors and actually displaying a darker version of my images, as seen here. In this image, the dark background and background image should be both…
Martin Plante
  • 4,553
  • 3
  • 33
  • 45
12
votes
2 answers

Should WebGL shader output be adjusted for gamma?

Should a WebGL fragment shader output gl_FragColor RGB values which are linear, or to some 1⁄γ power in order to correct for display gamma? If the latter, is there a specific value to use or must a complete application be configurable? The WebGL…
Kevin Reid
  • 37,492
  • 13
  • 80
  • 108
9
votes
1 answer

Formula to increase brightness of RGB?

Quick question! I have an R G B value and I want to convert to convert it to be 50% brighter. I found a gamma formula but I'm unsure if gamma is the correct way to go. So far, I'm using: r = 255*((R/255.0)^ (1/1.5)); g =…
UnseededAndroid
  • 527
  • 4
  • 8
  • 15
9
votes
3 answers

What exactly is the need for gamma correction?

I have problems to fully understand the need for gamma correction. I hope you guys can help me. Let’s assume we want to display 256 neighboring pixels. These pixels should be a smooth gradient from black to white. To denote theirs colors, we use…
user1494080
  • 2,064
  • 2
  • 17
  • 36
8
votes
1 answer

How can I get image data from QTKit without color or gamma correction in Snow Leopard?

Since Snow Leopard, QTKit is now returning color corrected image data from functions like QTMovies frameImageAtTime:withAttributes:error:. Given an uncompressed AVI file, the same image data is displayed with larger pixel values in Snow Leopard vs.…
Nick Haddad
  • 8,767
  • 3
  • 34
  • 38
8
votes
2 answers

Correct conversion from rec. 709 to sRGB

How do I correctly convert colors stored as Y'CrCb (using rec. 709) to sRGB? I'm working with HDTV video and I'm extracting the raw data using libavcodec. While I have succeeded in making the conversion, I have yet to be confident that I'm doing it…
Sebastian Wahl
  • 324
  • 4
  • 11
7
votes
4 answers

Antialiasing and gamma compensation

The luminence of pixels on a computer screen is not usually linearly related to the digital RGB triplet values of a pixel. The nonlinear response of early CRTs required a compensating nonlinear encoding and we continue to use such encodings…
Brian
  • 8,454
  • 5
  • 27
  • 30
6
votes
1 answer

Does OpenGL framebuffer blitting take into account gamma correction when enabled?

Here is my problem, when I load in textures I load them in as SRGB to convert them into linear space. When I was writing to the default frame buffer provided by the windowing system I enabled GL_FRAMEBUFFER_SRGB so that writing to the framebuffer…
Zebrafish
  • 11,682
  • 3
  • 43
  • 119
5
votes
1 answer

Is there a standard sequence for gamma, brightness & contrast corrections?

In my application I'm doing gamma, brightness and contrast corrections defined by the user. Now I was wondering whether there is a standard order of doing this or not. It may sound trivial but I couldn't find anything regarding this. I guess it's…
user238801
5
votes
2 answers

How to convert decimal to Variable Byte code & gamma code

How do you convert the decimal number 777 to the equivalent VB & gamma codes? I've been reading up on gamma codes. I see where they get the unary codes from the decimal but not where the length & offset comes from. I also understand that the gamma…
Adam Lynch
  • 3,341
  • 5
  • 36
  • 66
5
votes
1 answer

Running a GLM with a Gamma distribution, but data includes zeros

I'm trying to run a GLM in R for biomass data (reductive biomass and ratio of reproductive biomass to vegetative biomass) as a function of habitat type ("hab"), year data was collected ("year"), and site of data collection ("site"). My data looks…
Laura
  • 63
  • 1
  • 2
  • 7
1
2 3
10 11