Cinematic.cpp 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. /*
  2. ===========================================================================
  3. Doom 3 BFG Edition GPL Source Code
  4. Copyright (C) 1993-2012 id Software LLC, a ZeniMax Media company.
  5. This file is part of the Doom 3 BFG Edition GPL Source Code ("Doom 3 BFG Edition Source Code").
  6. Doom 3 BFG Edition Source Code is free software: you can redistribute it and/or modify
  7. it under the terms of the GNU General Public License as published by
  8. the Free Software Foundation, either version 3 of the License, or
  9. (at your option) any later version.
  10. Doom 3 BFG Edition Source Code is distributed in the hope that it will be useful,
  11. but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. GNU General Public License for more details.
  14. You should have received a copy of the GNU General Public License
  15. along with Doom 3 BFG Edition Source Code. If not, see <http://www.gnu.org/licenses/>.
  16. In addition, the Doom 3 BFG Edition Source Code is also subject to certain additional terms. You should have received a copy of these additional terms immediately following the terms and conditions of the GNU General Public License which accompanied the Doom 3 BFG Edition Source Code. If not, please request a copy in writing from id Software at the address below.
  17. If you have questions concerning this license or the applicable additional terms, you may contact in writing id Software LLC, c/o ZeniMax Media Inc., Suite 120, Rockville, Maryland 20850 USA.
  18. ===========================================================================
  19. */
  20. #pragma hdrstop
  21. #include "../idlib/precompiled.h"
  22. extern idCVar s_noSound;
  23. #include "tr_local.h"
  24. //===========================================
  25. /*
  26. ==============
  27. idCinematic::InitCinematic
  28. ==============
  29. */
  30. void idCinematic::InitCinematic( void ) {
  31. }
  32. /*
  33. ==============
  34. idCinematic::ShutdownCinematic
  35. ==============
  36. */
  37. void idCinematic::ShutdownCinematic( void ) {
  38. }
  39. /*
  40. ==============
  41. idCinematic::Alloc
  42. ==============
  43. */
  44. idCinematic * idCinematic::Alloc() {
  45. return new idCinematic;
  46. }
  47. /*
  48. ==============
  49. idCinematic::~idCinematic
  50. ==============
  51. */
  52. idCinematic::~idCinematic( ) {
  53. Close();
  54. }
  55. /*
  56. ==============
  57. idCinematic::InitFromFile
  58. ==============
  59. */
  60. bool idCinematic::InitFromFile( const char *qpath, bool looping ) {
  61. return false;
  62. }
  63. /*
  64. ==============
  65. idCinematic::AnimationLength
  66. ==============
  67. */
  68. int idCinematic::AnimationLength() {
  69. return 0;
  70. }
  71. /*
  72. ==============
  73. idCinematic::GetStartTime
  74. ==============
  75. */
  76. int idCinematic::GetStartTime() {
  77. return -1;
  78. }
  79. /*
  80. ==============
  81. idCinematic::ResetTime
  82. ==============
  83. */
  84. void idCinematic::ResetTime(int milliseconds) {
  85. }
  86. /*
  87. ==============
  88. idCinematic::ImageForTime
  89. ==============
  90. */
  91. cinData_t idCinematic::ImageForTime( int milliseconds ) {
  92. cinData_t c;
  93. memset( &c, 0, sizeof( c ) );
  94. return c;
  95. }
  96. /*
  97. ==============
  98. idCinematic::ExportToTGA
  99. ==============
  100. */
  101. void idCinematic::ExportToTGA( bool skipExisting ) {
  102. }
  103. /*
  104. ==============
  105. idCinematic::GetFrameRate
  106. ==============
  107. */
  108. float idCinematic::GetFrameRate() const {
  109. return 30.0f;
  110. }
  111. /*
  112. ==============
  113. idCinematic::Close
  114. ==============
  115. */
  116. void idCinematic::Close() {
  117. }
  118. /*
  119. ==============
  120. idSndWindow::InitFromFile
  121. ==============
  122. */
  123. bool idSndWindow::InitFromFile( const char *qpath, bool looping ) {
  124. idStr fname = qpath;
  125. fname.ToLower();
  126. if ( !fname.Icmp( "waveform" ) ) {
  127. showWaveform = true;
  128. } else {
  129. showWaveform = false;
  130. }
  131. return true;
  132. }
  133. /*
  134. ==============
  135. idSndWindow::ImageForTime
  136. ==============
  137. */
  138. cinData_t idSndWindow::ImageForTime( int milliseconds ) {
  139. return soundSystem->ImageForTime( milliseconds, showWaveform );
  140. }
  141. /*
  142. ==============
  143. idSndWindow::AnimationLength
  144. ==============
  145. */
  146. int idSndWindow::AnimationLength() {
  147. return -1;
  148. }