OfCCC.c revision 61b2299d
11ab64890Smrg/* $Xorg: OfCCC.c,v 1.3 2000/08/17 19:44:47 cpqbld Exp $ */ 21ab64890Smrg 31ab64890Smrg/* 41ab64890Smrg * Code and supporting documentation (c) Copyright 1990 1991 Tektronix, Inc. 51ab64890Smrg * All Rights Reserved 661b2299dSmrg * 71ab64890Smrg * This file is a component of an X Window System-specific implementation 81ab64890Smrg * of Xcms based on the TekColor Color Management System. Permission is 91ab64890Smrg * hereby granted to use, copy, modify, sell, and otherwise distribute this 101ab64890Smrg * software and its documentation for any purpose and without fee, provided 111ab64890Smrg * that this copyright, permission, and disclaimer notice is reproduced in 121ab64890Smrg * all copies of this software and in supporting documentation. TekColor 131ab64890Smrg * is a trademark of Tektronix, Inc. 1461b2299dSmrg * 151ab64890Smrg * Tektronix makes no representation about the suitability of this software 161ab64890Smrg * for any purpose. It is provided "as is" and with all faults. 1761b2299dSmrg * 181ab64890Smrg * TEKTRONIX DISCLAIMS ALL WARRANTIES APPLICABLE TO THIS SOFTWARE, 191ab64890Smrg * INCLUDING THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A 201ab64890Smrg * PARTICULAR PURPOSE. IN NO EVENT SHALL TEKTRONIX BE LIABLE FOR ANY 211ab64890Smrg * SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER 221ab64890Smrg * RESULTING FROM LOSS OF USE, DATA, OR PROFITS, WHETHER IN AN ACTION OF 231ab64890Smrg * CONTRACT, NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 241ab64890Smrg * CONNECTION WITH THE USE OR THE PERFORMANCE OF THIS SOFTWARE. 251ab64890Smrg * 261ab64890Smrg * 271ab64890Smrg * NAME 281ab64890Smrg * XcmsOfCCC.c - Color Conversion Context Querying Routines 291ab64890Smrg * 301ab64890Smrg * DESCRIPTION 311ab64890Smrg * Routines to query components of a Color Conversion 321ab64890Smrg * Context structure. 331ab64890Smrg * 341ab64890Smrg * 351ab64890Smrg */ 361ab64890Smrg 371ab64890Smrg#ifdef HAVE_CONFIG_H 381ab64890Smrg#include <config.h> 391ab64890Smrg#endif 401ab64890Smrg#include "Xlib.h" 411ab64890Smrg#include "Xcms.h" 421ab64890Smrg 431ab64890Smrg 441ab64890Smrg 451ab64890Smrg/************************************************************************ 461ab64890Smrg * * 471ab64890Smrg * PUBLIC INTERFACES * 481ab64890Smrg * * 491ab64890Smrg ************************************************************************/ 501ab64890Smrg 511ab64890Smrg/* 521ab64890Smrg * NAME 531ab64890Smrg * XcmsDisplayOfCCC 541ab64890Smrg * 551ab64890Smrg * SYNOPSIS 561ab64890Smrg */ 571ab64890Smrg 581ab64890SmrgDisplay * 591ab64890SmrgXcmsDisplayOfCCC( 601ab64890Smrg XcmsCCC ccc) 611ab64890Smrg/* 621ab64890Smrg * DESCRIPTION 631ab64890Smrg * Queries the Display of the specified CCC. 641ab64890Smrg * 651ab64890Smrg * RETURNS 661ab64890Smrg * Pointer to the Display. 671ab64890Smrg * 681ab64890Smrg */ 691ab64890Smrg{ 701ab64890Smrg return(ccc->dpy); 711ab64890Smrg} 721ab64890Smrg 731ab64890Smrg 741ab64890Smrg/* 751ab64890Smrg * NAME 761ab64890Smrg * XcmsVisualOfCCC 771ab64890Smrg * 781ab64890Smrg * SYNOPSIS 791ab64890Smrg */ 801ab64890Smrg 811ab64890SmrgVisual * 821ab64890SmrgXcmsVisualOfCCC( 831ab64890Smrg XcmsCCC ccc) 841ab64890Smrg/* 851ab64890Smrg * DESCRIPTION 861ab64890Smrg * Queries the Visual of the specified CCC. 871ab64890Smrg * 881ab64890Smrg * RETURNS 891ab64890Smrg * Pointer to the Visual. 901ab64890Smrg * 911ab64890Smrg */ 921ab64890Smrg{ 931ab64890Smrg return(ccc->visual); 941ab64890Smrg} 951ab64890Smrg 961ab64890Smrg 971ab64890Smrg/* 981ab64890Smrg * NAME 991ab64890Smrg * XcmsScreenNumberOfCCC 1001ab64890Smrg * 1011ab64890Smrg * SYNOPSIS 1021ab64890Smrg */ 1031ab64890Smrg 1041ab64890Smrgint 1051ab64890SmrgXcmsScreenNumberOfCCC( 1061ab64890Smrg XcmsCCC ccc) 1071ab64890Smrg/* 1081ab64890Smrg * DESCRIPTION 1091ab64890Smrg * Queries the screen number of the specified CCC. 1101ab64890Smrg * 1111ab64890Smrg * RETURNS 1121ab64890Smrg * screen number. 1131ab64890Smrg * 1141ab64890Smrg */ 1151ab64890Smrg{ 1161ab64890Smrg return(ccc->screenNumber); 1171ab64890Smrg} 1181ab64890Smrg 1191ab64890Smrg 1201ab64890Smrg/* 1211ab64890Smrg * NAME 1221ab64890Smrg * XcmsScreenWhitePointOfCCC 1231ab64890Smrg * 1241ab64890Smrg * SYNOPSIS 1251ab64890Smrg */ 1261ab64890Smrg 1271ab64890SmrgXcmsColor * 1281ab64890SmrgXcmsScreenWhitePointOfCCC( 1291ab64890Smrg XcmsCCC ccc) 1301ab64890Smrg/* 1311ab64890Smrg * DESCRIPTION 1321ab64890Smrg * Queries the screen white point of the specified CCC. 1331ab64890Smrg * 1341ab64890Smrg * RETURNS 1351ab64890Smrg * Pointer to the XcmsColor containing the screen white point. 1361ab64890Smrg * 1371ab64890Smrg */ 1381ab64890Smrg{ 1391ab64890Smrg return(&ccc->pPerScrnInfo->screenWhitePt); 1401ab64890Smrg} 1411ab64890Smrg 1421ab64890Smrg 1431ab64890Smrg/* 1441ab64890Smrg * NAME 1451ab64890Smrg * XcmsClientWhitePointOfCCC 1461ab64890Smrg * 1471ab64890Smrg * SYNOPSIS 1481ab64890Smrg */ 1491ab64890Smrg 1501ab64890SmrgXcmsColor * 1511ab64890SmrgXcmsClientWhitePointOfCCC( 1521ab64890Smrg XcmsCCC ccc) 1531ab64890Smrg/* 1541ab64890Smrg * DESCRIPTION 1551ab64890Smrg * Queries the client white point of the specified CCC. 1561ab64890Smrg * 1571ab64890Smrg * RETURNS 1581ab64890Smrg * Pointer to the XcmsColor containing the client white point. 1591ab64890Smrg * 1601ab64890Smrg */ 1611ab64890Smrg{ 1621ab64890Smrg return(&ccc->clientWhitePt); 1631ab64890Smrg} 164