Hash :
b8aee3bc
Author :
Date :
2015-01-27T14:42:36
Add UNPACK_ROW_LENGTH support to D3D11 renderer Change-Id: I31ccffddcb04a45f19d3c3eb9a396c30e794b218 Reviewed-on: https://chromium-review.googlesource.com/243951 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Minmin Gong <mgong@microsoft.com>
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80
//
// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// formatutils.h: Queries for GL image formats.
#ifndef LIBANGLE_FORMATUTILS_H_
#define LIBANGLE_FORMATUTILS_H_
#include "libANGLE/Caps.h"
#include "libANGLE/angletypes.h"
#include "angle_gl.h"
#include <cstddef>
#include <stdint.h>
namespace gl
{
struct Type
{
Type();
GLuint bytes;
bool specialInterpretation;
};
const Type &GetTypeInfo(GLenum type);
struct InternalFormat
{
InternalFormat();
GLuint redBits;
GLuint greenBits;
GLuint blueBits;
GLuint luminanceBits;
GLuint alphaBits;
GLuint sharedBits;
GLuint depthBits;
GLuint stencilBits;
GLuint pixelBytes;
GLuint componentCount;
bool compressed;
GLuint compressedBlockWidth;
GLuint compressedBlockHeight;
GLenum format;
GLenum type;
GLenum componentType;
GLenum colorEncoding;
typedef bool (*SupportCheckFunction)(GLuint, const Extensions &);
SupportCheckFunction textureSupport;
SupportCheckFunction renderSupport;
SupportCheckFunction filterSupport;
GLuint computeRowPitch(GLenum formatType, GLsizei width, GLint alignment, GLint rowLength) const;
GLuint computeDepthPitch(GLenum formatType, GLsizei width, GLsizei height, GLint alignment, GLint rowLength) const;
GLuint computeBlockSize(GLenum formatType, GLsizei width, GLsizei height) const;
};
const InternalFormat &GetInternalFormatInfo(GLenum internalFormat);
GLenum GetSizedInternalFormat(GLenum internalFormat, GLenum type);
typedef std::set<GLenum> FormatSet;
const FormatSet &GetAllSizedInternalFormats();
}
#endif // LIBANGLE_FORMATUTILS_H_