Lines Matching full:blockmode
1353 ASTCBlockMode blockMode;
1354 blockMode.isError = true; // \note Set to false later, if not error.
1356 blockMode.isVoidExtent = getBits(blockModeData, 0, 8) == 0x1fc;
1358 if (!blockMode.isVoidExtent)
1361 return blockMode; // Invalid ("reserved").
1377 blockMode.weightGridWidth = i5 ? 10 : 6;
1378 blockMode.weightGridHeight = i5 ? 6 : 10;
1385 case 0: blockMode.weightGridWidth = 12; blockMode.weightGridHeight = a + 2; break;
1386 case 1: blockMode.weightGridWidth = a + 2; blockMode.weightGridHeight = 12; break;
1387 case 2: blockMode.weightGridWidth = a + 6; blockMode.weightGridHeight = getBits(blockModeData, 9, 10) + 6; break;
1406 blockMode.weightGridWidth = i8 ? b+2 : a+2;
1407 blockMode.weightGridHeight = i8 ? a+2 : b+6;
1415 case 0: blockMode.weightGridWidth = b + 4; blockMode.weightGridHeight = a + 2; break;
1416 case 1: blockMode.weightGridWidth = b + 8; blockMode.weightGridHeight = a + 2; break;
1417 case 2: blockMode.weightGridWidth = a + 2; blockMode.weightGridHeight = b + 8; break;
1425 blockMode.isDualPlane = zeroDH ? 0 : isBitSet(blockModeData, 10);
1428 ISEMode& m = blockMode.weightISEParams.mode;
1429 int& b = blockMode.weightISEParams.numBits;
1462 blockMode.isError = false;
1463 return blockMode;
2253 static void unquantizeWeights (deUint32* dst, const ISEDecodedResult* weightGrid, const ASTCBlockMode& blockMode)
2255 const int numWeights = computeNumWeights(blockMode);
2256 const ISEParams& iseParams = blockMode.weightISEParams;
2309 static void interpolateWeights (TexelWeightPair* dst, const deUint32* unquantizedWeights, int blockWidth, int blockHeight, const ASTCBlockMode& blockMode)
2311 const int numWeightsPerTexel = blockMode.isDualPlane ? 2 : 1;
2319 const deUint32 gX = (scaleX*texelX*(blockMode.weightGridWidth-1) + 32) >> 6;
2320 const deUint32 gY = (scaleY*texelY*(blockMode.weightGridHeight-1) + 32) >> 6;
2329 const deUint32 v0 = jY*blockMode.weightGridWidth + jX;
2335 const deUint32 p10 = unquantizedWeights[(v0 + blockMode.weightGridWidth) * numWeightsPerTexel + texelWeightNdx];
2336 const deUint32 p11 = unquantizedWeights[(v0 + blockMode.weightGridWidth + 1) * numWeightsPerTexel + texelWeightNdx];
2344 static void computeTexelWeights (TexelWeightPair* dst, const Block128& blockData, int blockWidth, int blockHeight, const ASTCBlockMode& blockMode)
2349 BitAccessStream dataStream(blockData, 127, computeNumRequiredBits(blockMode.weightISEParams, computeNumWeights(blockMode)), false);
2350 decodeISE(&weightGrid[0], computeNumWeights(blockMode), dataStream, blockMode.weightISEParams);
2355 unquantizeWeights(&unquantizedWeights[0], &weightGrid[0], blockMode);
2356 interpolateWeights(dst, &unquantizedWeights[0], blockWidth, blockHeight, blockMode);
2495 const ASTCBlockMode blockMode = getASTCBlockMode(blockData.getBits(0, 10));
2499 if (blockMode.isError)
2507 if (blockMode.isVoidExtent)
2515 const int numWeights = computeNumWeights(blockMode);
2516 const int numWeightDataBits = computeNumRequiredBits(blockMode.weightISEParams, numWeights);
2524 blockMode.weightGridWidth > blockWidth ||
2525 blockMode.weightGridHeight > blockHeight ||
2526 (numPartitions == 4 && blockMode.isDualPlane))
2536 (blockMode.isDualPlane ? 2 : 0);
2567 computeTexelWeights(&texelWeights[0], blockData, blockWidth, blockHeight, blockMode);
2571 const int ccs = blockMode.isDualPlane ? (int)blockData.getBits(extraCemBitsStart-2, extraCemBitsStart-1) : -1;