Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(815)

Issue 304743004: Move ETC1 and LATC enums value to GrPixelConfig (Closed)

Created:
6 years, 6 months ago by krajcevski
Modified:
6 years, 6 months ago
CC:
skia-review_googlegroups.com
Base URL:
https://skia.googlesource.com/skia.git@master
Visibility:
Public.

Description

Move the LATC and ETC1 enum values to GrPixelConfig. I also tried to put in checks in a few places to make sure that we weren't using these pixel configurations in places that we shouldn't be. LATC is a DXT-esque alpha compression format that goes by a few other names (RGTC, 3DC). It might be useful to investigate using it to compress the alpha masks that we get from software rasterization. This patch set adds enums for that and recognition whether or not the device can support it. Committed: http://code.google.com/p/skia/source/detail?r=14991

Patch Set 1 #

Patch Set 2 : Added LATC define #

Patch Set 3 : Add LATC checks #

Total comments: 14

Patch Set 4 : Code review changes #

Patch Set 5 : Add isConfigTexturable() #

Total comments: 2

Patch Set 6 : Remove some duplicated flags in (GL)DrawTargetCaps #

Total comments: 13

Patch Set 7 : A few more small fixes #

Patch Set 8 : Only generate mipmaps for uncompressed textures. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+236 lines, -128 lines) Patch
M include/gpu/GrColor.h View 1 2 3 2 chunks +4 lines, -0 lines 0 comments Download
M include/gpu/GrTypes.h View 1 2 3 4 chunks +22 lines, -15 lines 0 comments Download
M src/gpu/GrAtlas.cpp View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M src/gpu/GrContext.cpp View 1 2 3 4 5 6 7 2 chunks +5 lines, -1 line 0 comments Download
M src/gpu/GrDrawTarget.cpp View 1 2 3 4 5 6 6 chunks +18 lines, -27 lines 0 comments Download
M src/gpu/GrDrawTargetCaps.h View 1 2 3 4 5 3 chunks +4 lines, -7 lines 0 comments Download
M src/gpu/GrTexture.cpp View 1 2 3 4 5 6 7 1 chunk +19 lines, -0 lines 0 comments Download
M src/gpu/gl/GrGLCaps.h View 1 2 3 4 5 4 chunks +15 lines, -6 lines 0 comments Download
M src/gpu/gl/GrGLCaps.cpp View 1 2 3 4 5 6 10 chunks +89 lines, -51 lines 0 comments Download
M src/gpu/gl/GrGLDefines.h View 1 2 1 chunk +13 lines, -0 lines 0 comments Download
M src/gpu/gl/GrGpuGL.cpp View 1 2 3 4 5 6 7 11 chunks +44 lines, -21 lines 0 comments Download

Messages

Total messages: 17 (0 generated)
krajcevski
I added LATC in this patch set because after adding only ETC1, clang bots failed ...
6 years, 6 months ago (2014-05-28 22:09:39 UTC) #1
robertphillips
lgtm + nits/questions. https://codereview.chromium.org/304743004/diff/40001/include/gpu/GrColor.h File include/gpu/GrColor.h (right): https://codereview.chromium.org/304743004/diff/40001/include/gpu/GrColor.h#newcode135 include/gpu/GrColor.h:135: kRGB_GrColorComponentFlags, // kETC1_GrPixelConfig align kLATC comment ...
6 years, 6 months ago (2014-05-29 12:53:18 UTC) #2
bsalomon
How do we know at runtime if there is support for the compressed formats? We've ...
6 years, 6 months ago (2014-05-29 13:10:30 UTC) #3
krajcevski
Re isConfigRenderable: Is this function meant to mean "This pixel config can be rendered into" ...
6 years, 6 months ago (2014-05-29 14:28:22 UTC) #4
bsalomon
On 2014/05/29 14:28:22, krajcevski wrote: > Re isConfigRenderable: > > Is this function meant to ...
6 years, 6 months ago (2014-05-29 15:28:18 UTC) #5
krajcevski
Hrm, I added the isConfigTexturable() command because having the logic that detects whether or not ...
6 years, 6 months ago (2014-05-29 17:10:52 UTC) #6
bsalomon
https://codereview.chromium.org/304743004/diff/70001/src/gpu/gl/GrGLCaps.cpp File src/gpu/gl/GrGLCaps.cpp (right): https://codereview.chromium.org/304743004/diff/70001/src/gpu/gl/GrGLCaps.cpp#newcode471 src/gpu/gl/GrGLCaps.cpp:471: fConfigTextureSupport[kBGRA_8888_GrPixelConfig] = true; I think this needs to duplicate ...
6 years, 6 months ago (2014-05-29 19:11:29 UTC) #7
krajcevski
https://codereview.chromium.org/304743004/diff/70001/src/gpu/gl/GrGLCaps.cpp File src/gpu/gl/GrGLCaps.cpp (right): https://codereview.chromium.org/304743004/diff/70001/src/gpu/gl/GrGLCaps.cpp#newcode471 src/gpu/gl/GrGLCaps.cpp:471: fConfigTextureSupport[kBGRA_8888_GrPixelConfig] = true; On 2014/05/29 19:11:29, bsalomon wrote: > ...
6 years, 6 months ago (2014-05-29 19:46:42 UTC) #8
bsalomon
lgtm
6 years, 6 months ago (2014-05-29 19:59:10 UTC) #9
robertphillips
https://codereview.chromium.org/304743004/diff/90001/src/gpu/GrContext.cpp File src/gpu/GrContext.cpp (right): https://codereview.chromium.org/304743004/diff/90001/src/gpu/GrContext.cpp#newcode615 src/gpu/GrContext.cpp:615: const GrDrawTargetCaps* caps = fGpu->caps(); Wrong config? https://codereview.chromium.org/304743004/diff/90001/src/gpu/GrDrawTarget.cpp File ...
6 years, 6 months ago (2014-05-29 20:08:43 UTC) #10
krajcevski
https://codereview.chromium.org/304743004/diff/90001/src/gpu/GrContext.cpp File src/gpu/GrContext.cpp (right): https://codereview.chromium.org/304743004/diff/90001/src/gpu/GrContext.cpp#newcode615 src/gpu/GrContext.cpp:615: const GrDrawTargetCaps* caps = fGpu->caps(); On 2014/05/29 20:08:43, robertphillips ...
6 years, 6 months ago (2014-05-29 20:31:27 UTC) #11
bsalomon
https://codereview.chromium.org/304743004/diff/90001/src/gpu/GrTexture.cpp File src/gpu/GrTexture.cpp (right): https://codereview.chromium.org/304743004/diff/90001/src/gpu/GrTexture.cpp#newcode66 src/gpu/GrTexture.cpp:66: if (GrPixelConfigIsCompressed(fDesc.fConfig)) { On 2014/05/29 20:31:28, krajcevski wrote: > ...
6 years, 6 months ago (2014-05-29 20:38:19 UTC) #12
krajcevski
I added a check at the last minute (right before the call to glGenerateMipmap).
6 years, 6 months ago (2014-05-29 21:03:20 UTC) #13
bsalomon
lgtm
6 years, 6 months ago (2014-05-29 21:05:36 UTC) #14
krajcevski
The CQ bit was checked by krajcevski@google.com
6 years, 6 months ago (2014-05-30 13:46:37 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://skia-tree-status.appspot.com/cq/krajcevski@google.com/304743004/130001
6 years, 6 months ago (2014-05-30 13:46:59 UTC) #16
commit-bot: I haz the power
6 years, 6 months ago (2014-05-30 13:56:03 UTC) #17
Message was sent while issue was closed.
Change committed as 14991

Powered by Google App Engine
This is Rietveld 408576698