Team Fortress 2 Source Code as on 22/4/2020
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

85 lines
1.9 KiB

  1. /*
  2. File: CGBitmapContext.h
  3. Contains: CoreGraphics BitMapContext
  4. Version: QuickTime 7.3
  5. Copyright: (c) 2007 (c) 2000-2001 by Apple Computer, Inc., all rights reserved.
  6. Bugs?: For bug reports, consult the following page on
  7. the World Wide Web:
  8. http://developer.apple.com/bugreporter/
  9. */
  10. #ifndef CGBITMAPCONTEXT_H_
  11. #define CGBITMAPCONTEXT_H_
  12. #ifndef __CGBASE__
  13. #include <CGBase.h>
  14. #endif
  15. #ifndef __CGCONTEXT__
  16. #include <CGContext.h>
  17. #endif
  18. /* Create a bitmap context. The context draws into a bitmap which is
  19. * `width' pixels wide and `height' pixels high. The number of components
  20. * for each pixel is specified by `colorspace', which also may specify a
  21. * destination color profile. The number of bits for each component of a
  22. * pixel is specified by `bitsPerComponent', which must be 1, 2, 4, or 8.
  23. * Each row of the bitmap consists of `bytesPerRow' bytes, which must be at
  24. * least `(width * bitsPerComponent * number of components + 7)/8' bytes.
  25. * `data' points a block of memory at least `bytesPerRow * height' bytes.
  26. * `alphaInfo' specifies whether the bitmap should contain an alpha
  27. * channel, and how it's to be generated. */
  28. #if PRAGMA_ONCE
  29. #pragma once
  30. #endif
  31. #ifdef __cplusplus
  32. extern "C" {
  33. #endif
  34. #if PRAGMA_IMPORT
  35. #pragma import on
  36. #endif
  37. /*
  38. * CGBitmapContextCreate()
  39. *
  40. * Availability:
  41. * Non-Carbon CFM: not available
  42. * CarbonLib: not available
  43. * Mac OS X: in version 10.0 and later
  44. */
  45. EXTERN_API_C( CGContextRef )
  46. CGBitmapContextCreate(
  47. void * data,
  48. size_t width,
  49. size_t height,
  50. size_t bitsPerComponent,
  51. size_t bytesPerRow,
  52. CGColorSpaceRef colorspace,
  53. CGImageAlphaInfo alphaInfo);
  54. #ifdef PRAGMA_IMPORT_OFF
  55. #pragma import off
  56. #elif PRAGMA_IMPORT
  57. #pragma import reset
  58. #endif
  59. #ifdef __cplusplus
  60. }
  61. #endif
  62. #endif /* CGBITMAPCONTEXT_H_ */