View Issue Details

IDProjectCategoryView StatusLast Update
0004553The Dark ModSound Systempublic08.09.2017 03:35
Reporterstgatilov Assigned Tostgatilov  
PrioritynormalSeverityminorReproducibilitysometimes
Status resolvedResolutionfixed 
Product VersionSVN 
Target VersionTDM 2.06Fixed in VersionTDM 2.06 
Summary0004553: Some gameplay sounds stop playing after noclipping
Description(not sure if it can happen during normal gameplay)
Steps To Reproduce1. Start training mission.
2. Enter "noclip" into console.
3. Fly around the level LIKE MAD (i.e. in RUN mode).
4. Return to room and check if sounds still play.
5. At some moment you would notice that some sounds stop playing.
For instance, if you have a sword, it stops producing swinging sound on attack.
Save + load seems to solve the problem.
TagsNo tags attached.

Relationships

duplicate of 0004614 resolvedstgatilov Audio Loss in No Honor Among Thieves 
related to 0004540 resolvedstgatilov Sound stops playing in cinematics because of breakpoints 

Activities

stgatilov

stgatilov

07.09.2017 17:07

administrator   ~0009172

I found why sounds are muted.

In idSampleDecoderLocal::DecodeOGG, new OGG file is opened:

  // open OGG file if not yet opened
  if ( lastSample == NULL ) {
    // make sure there is enough space for another decoder
    if ( decoderMemoryAllocator.GetFreeBlockMemory() < MIN_OGGVORBIS_MEMORY ) {
      return 0;
    }
    if ( sample->nonCacheData == NULL ) {
      assert( false ); // this should never happen
      failed = true;
      return 0;
    }
    file.SetData( (const char *)sample->nonCacheData, sample->objectMemSize );
    if ( ov_openFile( &file, &ogg ) < 0 ) {

As you see, if decoderMemoryAllocator has not enough free memory, then sound data is not written (results in perfectly zero sounds). The decoderMemoryAllocator is a custom memory allocator with 10 blocks (fixed number) of size 1 MB each.

I suppose nbohr1more is right and some sound memory is not freed properly. So the samples stack indefinitely. The fact that they are muted is just a safeguard against unlimited memory growth.
nbohr1more

nbohr1more

08.09.2017 01:08

developer   ~0009177

Src Rev 7121
Binaries 14907

Issue History

Date Modified Username Field Change
03.07.2017 02:04 stgatilov New Issue
03.07.2017 02:05 stgatilov Steps to Reproduce Updated
03.07.2017 02:05 stgatilov Relationship added related to 0004540
06.09.2017 09:12 stgatilov Relationship added related to 0004614
07.09.2017 17:07 stgatilov Note Added: 0009172
07.09.2017 17:21 stgatilov Assigned To => stgatilov
07.09.2017 17:21 stgatilov Status new => assigned
08.09.2017 01:07 nbohr1more Status assigned => resolved
08.09.2017 01:07 nbohr1more Resolution open => fixed
08.09.2017 01:07 nbohr1more Fixed in Version => TDM 2.06
08.09.2017 01:07 nbohr1more Target Version => TDM 2.06
08.09.2017 01:08 nbohr1more Note Added: 0009177
08.09.2017 03:35 stgatilov Relationship replaced duplicate of 0004614