1 // BEGIN_COPYRIGHT -*- glean -*-
3 // Copyright (C) 1999 Allen Akin All Rights Reserved.
5 // Permission is hereby granted, free of charge, to any person
6 // obtaining a copy of this software and associated documentation
7 // files (the "Software"), to deal in the Software without
8 // restriction, including without limitation the rights to use,
9 // copy, modify, merge, publish, distribute, sublicense, and/or
10 // sell copies of the Software, and to permit persons to whom the
11 // Software is furnished to do so, subject to the following
14 // The above copyright notice and this permission notice shall be
15 // included in all copies or substantial portions of the
18 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
19 // KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
20 // WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
21 // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ALLEN AKIN BE
22 // LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
23 // AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
24 // OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25 // DEALINGS IN THE SOFTWARE.
29 // tlogicop.h: Test RGBA logic op functions.
30 // Based on Allen's blendFunc test.
31 // Brian Paul 10 May 2001
33 #ifndef __tlogicop_h__
34 #define __tlogicop_h__
40 #define drawingSize 64
41 #define windowSize (drawingSize + 2)
43 class LogicopFuncResult
: public BaseResult
{
45 bool pass
; // not written to log file
47 struct PartialResult
{
48 GLenum logicop
; // The logic op
49 float rbErr
; // Max readback error, in bits.
50 float opErr
; // Max logicop error, in bits.
52 vector
<PartialResult
> results
;
54 virtual void putresults(ostream
& s
) const;
55 virtual bool getresults(istream
& s
);
58 class LogicopFuncTest
: public BaseTest
<LogicopFuncResult
> {
60 GLEAN_CLASS_WH(LogicopFuncTest
, LogicopFuncResult
,
61 windowSize
, windowSize
);
62 }; // class LogicopFuncTest
66 #endif // __tlogicop_h__