iljpgint.h 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. /*
  2. * CDE - Common Desktop Environment
  3. *
  4. * Copyright (c) 1993-2012, The Open Group. All rights reserved.
  5. *
  6. * These libraries and programs are free software; you can
  7. * redistribute them and/or modify them under the terms of the GNU
  8. * Lesser General Public License as published by the Free Software
  9. * Foundation; either version 2 of the License, or (at your option)
  10. * any later version.
  11. *
  12. * These libraries and programs are distributed in the hope that
  13. * they will be useful, but WITHOUT ANY WARRANTY; without even the
  14. * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
  15. * PURPOSE. See the GNU Lesser General Public License for more
  16. * details.
  17. *
  18. * You should have received a copy of the GNU Lesser General Public
  19. * License along with these librararies and programs; if not, write
  20. * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
  21. * Floor, Boston, MA 02110-1301 USA
  22. */
  23. /* $XConsortium: iljpgint.h /main/4 1996/01/08 12:16:39 lehors $ */
  24. /**---------------------------------------------------------------------
  25. ***
  26. *** (c)Copyright 1992 Hewlett-Packard Co.
  27. ***
  28. *** RESTRICTED RIGHTS LEGEND
  29. *** Use, duplication, or disclosure by the U.S. Government is subject to
  30. *** restrictions as set forth in sub-paragraph (c)(1)(ii) of the Rights in
  31. *** Technical Data and Computer Software clause in DFARS 252.227-7013.
  32. *** Hewlett-Packard Company
  33. *** 3000 Hanover Street
  34. *** Palo Alto, CA 94304 U.S.A.
  35. *** Rights for non-DOD U.S. Government Departments and Agencies are as set
  36. *** forth in FAR 52.227-19(c)(1,2).
  37. ***
  38. ***-------------------------------------------------------------------*/
  39. #ifndef ILJPGINT_H
  40. #define ILJPGINT_H
  41. #ifndef ILJPG_H
  42. #include "iljpg.h"
  43. #endif
  44. #ifdef TRUE
  45. #undef TRUE
  46. #endif
  47. #ifdef FALSE
  48. #undef FALSE
  49. #endif
  50. #define FALSE 0
  51. #define TRUE 1
  52. #ifndef __STDC__
  53. #ifdef NULL
  54. #undef NULL
  55. #endif
  56. #define NULL 0
  57. #endif
  58. typedef int iljpgBool;
  59. /* JPEG zigzag scanning order (64 entries) */
  60. ILJPG_PRIVATE_EXTERN
  61. int _iljpgZigzagTable[];
  62. /* Allocate _nBytes from heap and return a ptr to it. */
  63. #ifndef ILJPG_MALLOC
  64. # define ILJPG_MALLOC(_nBytes) (malloc (_nBytes))
  65. #endif
  66. /* Allocate _nBytes from heap, zero it, and return a ptr to it. */
  67. #ifndef ILJPG_MALLOC_ZERO
  68. # define ILJPG_MALLOC_ZERO(_nBytes) (calloc ((_nBytes), 1))
  69. #endif
  70. /* Free given block (*_ptr), allocated by ILJPG_MALLOC_ZERO(). */
  71. #ifndef ILJPG_FREE
  72. # define ILJPG_FREE(_ptr) (free (_ptr))
  73. #endif
  74. /* Validate the given parameter block and return true iff valid.
  75. */
  76. ILJPG_PRIVATE_EXTERN
  77. iljpgBool _iljpgValidPars (
  78. register iljpgDataPtr pData
  79. );
  80. #endif