v_video.h 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. // Emacs style mode select -*- C++ -*-
  2. //-----------------------------------------------------------------------------
  3. //
  4. // $Id:$
  5. //
  6. // Copyright (C) 1993-1996 by id Software, Inc.
  7. //
  8. // This source is available for distribution and/or modification
  9. // only under the terms of the DOOM Source Code License as
  10. // published by id Software. All rights reserved.
  11. //
  12. // The source is distributed in the hope that it will be useful,
  13. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. // FITNESS FOR A PARTICULAR PURPOSE. See the DOOM Source Code License
  15. // for more details.
  16. //
  17. // DESCRIPTION:
  18. // Gamma correction LUT.
  19. // Functions to draw patches (by post) directly to screen.
  20. // Functions to blit a block to the screen.
  21. //
  22. //-----------------------------------------------------------------------------
  23. #ifndef __V_VIDEO__
  24. #define __V_VIDEO__
  25. #include "doomtype.h"
  26. #include "doomdef.h"
  27. // Needed because we are refering to patches.
  28. #include "r_data.h"
  29. //
  30. // VIDEO
  31. //
  32. #define CENTERY (SCREENHEIGHT/2)
  33. // Screen 0 is the screen updated by I_Update screen.
  34. // Screen 1 is an extra buffer.
  35. extern byte* screens[5];
  36. extern int dirtybox[4];
  37. extern byte gammatable[5][256];
  38. extern int usegamma;
  39. // Allocates buffer screens, call before R_Init.
  40. void V_Init (void);
  41. void
  42. V_CopyRect
  43. ( int srcx,
  44. int srcy,
  45. int srcscrn,
  46. int width,
  47. int height,
  48. int destx,
  49. int desty,
  50. int destscrn );
  51. void
  52. V_DrawPatch
  53. ( int x,
  54. int y,
  55. int scrn,
  56. patch_t* patch);
  57. void
  58. V_DrawPatchDirect
  59. ( int x,
  60. int y,
  61. int scrn,
  62. patch_t* patch );
  63. // Draw a linear block of pixels into the view buffer.
  64. void
  65. V_DrawBlock
  66. ( int x,
  67. int y,
  68. int scrn,
  69. int width,
  70. int height,
  71. byte* src );
  72. // Reads a linear block of pixels into the view buffer.
  73. void
  74. V_GetBlock
  75. ( int x,
  76. int y,
  77. int scrn,
  78. int width,
  79. int height,
  80. byte* dest );
  81. void
  82. V_MarkRect
  83. ( int x,
  84. int y,
  85. int width,
  86. int height );
  87. #endif
  88. //-----------------------------------------------------------------------------
  89. //
  90. // $Log:$
  91. //
  92. //-----------------------------------------------------------------------------