Lines Matching defs:mask
85 * \brief Returns the number of words needed to represent mask of given length
96 * \brief Creates sample mask with all less significant bits than nthBit set
103 std::vector<deUint32> mask (numWords);
106 mask[ndx] = 0xFFFFFFFF;
108 mask[numWords - 1] = deBitMask32(0, (int)topWordBits);
109 return mask;
387 * \brief Tests coverage mask inversion validity.
389 * Tests that the coverage masks obtained by masks set with glSampleMaski(mask)
390 * and glSampleMaski(~mask) are indeed each others' inverses.
511 const GLbitfield mask = (invert) ? (~rawMask) : (rawMask);
515 gl.sampleMaski(wordNdx, mask & maskMask);
527 * \brief Tests coverage mask generation proportionality property.
529 * Tests that the number of coverage bits in a coverage mask set with
531 * Draws multiple frames, each time increasing the number of mask bits set
579 randomizeViewport(); // \note Using the same viewport for every iteration since coverage mask may depend on window-relative pixel coordinate.
609 log << TestLog::Message << "Drawing a red quad using sample mask 0b" << sampleMaskToString(sampleMask, m_numSamples) << TestLog::EndMessage;
613 const GLbitfield mask = (wordNdx < (int)sampleMask.size()) ? ((GLbitfield)(sampleMask[wordNdx])) : (0);
615 gl.sampleMaski(wordNdx, mask);
647 // Check if coverage mask is not all-zeros if alpha or coverage value is 0 (or 1, if inverted).
670 log << TestLog::Message << "Success: Number of coverage mask bits set appears to be, on average, proportional to the number of set sample mask bits" << TestLog::EndMessage;
679 * \brief Tests coverage mask generation constancy property.
681 * Tests that the coverage mask created by GL_SAMPLE_MASK is constant at
684 * the same coverage mask value. This way, if the constancy property is
695 CASEBIT_SAMPLE_MASK = 8, //!< Use sample mask.
720 DE_ASSERT(m_isSampleMaskCase); // no point testing non-sample-mask cases, they are checked already in gles3
760 log << TestLog::Message << "Color mask is TRUE, TRUE, TRUE, FALSE" << TestLog::EndMessage;
786 << (m_isSampleMaskCase ? "sample mask" : "")
820 const GLbitfield mask = (GLbitfield)deUint32Hash((col << (m_numSamples / 2)) ^ row);
824 gl.sampleMaski(wordNdx, mask & maskMask);
850 << "Success: Coverage mask appears to be constant at a given pixel coordinate with a given "
862 * \brief Tests that unused bits of a sample mask have no effect
864 * Tests that the bits in the sample mask with positions higher than
866 * operations the sample mask is ANDed with the fragment coverage value.
870 * redrawing the quads with identical masks but with the mask's high bits
911 log << TestLog::Message << "Sample count is multiple of word size. No unused high bits in sample mask.\nSkipping." << TestLog::EndMessage;
926 log << TestLog::Message << "Drawing several green quads, each fully overlapped by a red quad with the same effective sample mask values" << TestLog::EndMessage;
947 const GLbitfield mask = (GLbitfield)deUint32Hash((col << (m_numSamples / 2)) ^ row);
952 gl.sampleMaski(wordNdx, (mask & maskMask) | (highBits & ~maskMask));
959 const GLbitfield mask = (GLbitfield)deUint32Hash((col << (m_numSamples / 2)) ^ row);
964 gl.sampleMaski(wordNdx, (mask & maskMask) | (highBits & ~maskMask));
981 m_context.getTestContext().setTestResult(QP_TEST_RESULT_FAIL, "Unused mask bits modified mask");
986 log << TestLog::Message << "Success: Coverage mask high bits appear to have no effect." << TestLog::EndMessage;
1014 // sample mask
1015 group->addChild(new MaskInvertCase (m_context, "sample_mask_sum_of_inverses", "Test that mask and its negation's sum equal the fully set mask"));
1019 "Test that coverage mask is constant at given coordinates with a given alpha or coverage value, using GL_SAMPLE_MASK",
1022 "Test that coverage mask is constant at given coordinates with a given alpha or coverage value, using GL_SAMPLE_ALPHA_TO_COVERAGE and GL_SAMPLE_MASK",
1025 "Test that coverage mask is constant at given coordinates with a given alpha or coverage value, using GL_SAMPLE_COVERAGE and GL_SAMPLE_MASK",
1028 "Test that coverage mask is constant at given coordinates with a given alpha or coverage value, using GL_SAMPLE_ALPHA_TO_COVERAGE, GL_SAMPLE_COVERAGE and GL_SAMPLE_MASK",
1031 "Test that values of unused bits of a sample mask (bit index > sample count) have no effect"));