Go to the source code of this file.
|
static void | copy_compressed_data (char *mapPtr, DXGI_FORMAT dxgiFormat, D3D12_PLACED_SUBRESOURCE_FOOTPRINT *placedFootprints, UINT *numRows, UINT64 *rowSizeInBytes, const void *compressedData, int numMipLevels) |
|
static int | get_surface_sample_cnt (GrSurface *surf) |
|
static bool | check_resource_info (const GrD3DTextureResourceInfo &info) |
|
static bool | check_tex_resource_info (const GrD3DCaps &caps, const GrD3DTextureResourceInfo &info) |
|
static bool | check_rt_resource_info (const GrD3DCaps &caps, const GrD3DTextureResourceInfo &info, int sampleCnt) |
|
static bool | is_odd (int x) |
|
static bool | is_bgra (DXGI_FORMAT format) |
|
static bool | copy_color_data (const GrD3DCaps &caps, char *mapPtr, DXGI_FORMAT dxgiFormat, SkISize dimensions, D3D12_PLACED_SUBRESOURCE_FOOTPRINT *placedFootprints, std::array< float, 4 > color) |
|
◆ check_resource_info()
Definition at line 961 of file GrD3DGpu.cpp.
961 {
962 if (!
info.fResource.get()) {
963 return false;
964 }
965 return true;
966}
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
◆ check_rt_resource_info()
Definition at line 979 of file GrD3DGpu.cpp.
980 {
982 return false;
983 }
984 return true;
985}
bool isFormatRenderable(const GrBackendFormat &format, int sampleCount) const override
◆ check_tex_resource_info()
Definition at line 968 of file GrD3DGpu.cpp.
968 {
970 return false;
971 }
972
973 if (
info.fSampleCount != 1) {
974 return false;
975 }
976 return true;
977}
bool isFormatTexturable(const GrBackendFormat &, GrTextureType) const override
◆ copy_color_data()
static bool copy_color_data |
( |
const GrD3DCaps & |
caps, |
|
|
char * |
mapPtr, |
|
|
DXGI_FORMAT |
dxgiFormat, |
|
|
SkISize |
dimensions, |
|
|
D3D12_PLACED_SUBRESOURCE_FOOTPRINT * |
placedFootprints, |
|
|
std::array< float, 4 > |
color |
|
) |
| |
|
static |
Definition at line 1434 of file GrD3DGpu.cpp.
1439 {
1442 return false;
1443 }
1446 return false;
1447 }
1448
1449 return true;
1450}
bool GrClearImage(const GrImageInfo &dstInfo, void *dst, size_t dstRB, std::array< float, 4 > color)
static SkColorType colorType(AImageDecoder *decoder, const AImageDecoderHeaderInfo *headerInfo)
GrColorType getFormatColorType(DXGI_FORMAT) const
◆ copy_compressed_data()
static void copy_compressed_data |
( |
char * |
mapPtr, |
|
|
DXGI_FORMAT |
dxgiFormat, |
|
|
D3D12_PLACED_SUBRESOURCE_FOOTPRINT * |
placedFootprints, |
|
|
UINT * |
numRows, |
|
|
UINT64 * |
rowSizeInBytes, |
|
|
const void * |
compressedData, |
|
|
int |
numMipLevels |
|
) |
| |
|
static |
Definition at line 339 of file GrD3DGpu.cpp.
342 {
343 SkASSERT(compressedData && numMipLevels);
346
347 const char*
src =
static_cast<const char*
>(compressedData);
348 for (int currentMipLevel = 0; currentMipLevel < numMipLevels; currentMipLevel++) {
349
350 char*
dst = mapPtr + placedFootprints[currentMipLevel].Offset;
351 SkRectMemcpy(
dst, placedFootprints[currentMipLevel].Footprint.RowPitch,
352 src, rowSizeInBytes[currentMipLevel], rowSizeInBytes[currentMipLevel],
353 numRows[currentMipLevel]);
354 src += numRows[currentMipLevel] * rowSizeInBytes[currentMipLevel];
355 }
356}
bool GrDxgiFormatIsCompressed(DXGI_FORMAT format)
static void SkRectMemcpy(void *dst, size_t dstRB, const void *src, size_t srcRB, size_t trimRowBytes, int rowCount)
◆ get_surface_sample_cnt()
Definition at line 435 of file GrD3DGpu.cpp.
435 {
437 return rt->numSamples();
438 }
439 return 0;
440}
virtual GrRenderTarget * asRenderTarget()
◆ is_bgra()
static bool is_bgra |
( |
DXGI_FORMAT |
format | ) |
|
|
static |
Definition at line 1099 of file GrD3DGpu.cpp.
1099 {
1100
1101 return (
format == DXGI_FORMAT_B8G8R8A8_UNORM);
1102}
uint32_t uint32_t * format
◆ is_odd()
static bool is_odd |
( |
int |
x | ) |
|
|
static |
Definition at line 1089 of file GrD3DGpu.cpp.
1089 {
1091}
static constexpr bool SkToBool(const T &x)
◆ kConstantAlignment
constexpr int kConstantAlignment = 256 |
|
constexpr |
◆ kDefaultOutstandingAllocCnt
const int kDefaultOutstandingAllocCnt = 8 |
|
static |