[vlc-devel] [V2 2/5] demux: mkv: reindent

Zhao Zhili quinkblack at foxmail.com
Thu May 31 09:22:05 CEST 2018


---
 modules/demux/mkv/mkv.cpp | 42 ++++++++++++++++++++++--------------------
 1 file changed, 22 insertions(+), 20 deletions(-)

diff --git a/modules/demux/mkv/mkv.cpp b/modules/demux/mkv/mkv.cpp
index f5ed6ba..4973dc4 100644
--- a/modules/demux/mkv/mkv.cpp
+++ b/modules/demux/mkv/mkv.cpp
@@ -612,18 +612,18 @@ void BlockDecode( demux_t *p_demux, KaxBlock *block, KaxSimpleBlock *simpleblock
 
         switch( track.fmt.i_codec )
         {
-        case VLC_CODEC_COOK:
-        case VLC_CODEC_ATRAC3:
-        {
-            handle_real_audio(p_demux, &track, p_block, i_pts);
-            block_Release(p_block);
-            i_pts = ( track.i_default_duration )?
-                i_pts + ( mtime_t )track.i_default_duration:
-                VLC_TS_INVALID;
-            continue;
-         }
-
-         case VLC_CODEC_WEBVTT:
+            case VLC_CODEC_COOK:
+            case VLC_CODEC_ATRAC3:
+            {
+                handle_real_audio(p_demux, &track, p_block, i_pts);
+                block_Release(p_block);
+                i_pts = ( track.i_default_duration )?
+                    i_pts + ( mtime_t )track.i_default_duration:
+                    VLC_TS_INVALID;
+                continue;
+            }
+
+            case VLC_CODEC_WEBVTT:
             {
                 p_block = block_Realloc( p_block, 16, p_block->i_buffer );
                 if( !p_block )
@@ -632,16 +632,18 @@ void BlockDecode( demux_t *p_demux, KaxBlock *block, KaxSimpleBlock *simpleblock
                 memcpy( &p_block->p_buffer[4], "vttc", 4 );
                 SetDWBE( &p_block->p_buffer[8], p_block->i_buffer - 8 );
                 memcpy( &p_block->p_buffer[12], "payl", 4 );
+                break;
             }
-            break;
 
-         case VLC_CODEC_OPUS:
-            mtime_t i_length = i_duration * track. f_timecodescale *
-                    (double) p_segment->i_timescale / 1000.0;
-            if ( i_length < 0 ) i_length = 0;
-            p_block->i_nb_samples = i_length * track.fmt.audio.i_rate
-                    / CLOCK_FREQ;
-            break;
+            case VLC_CODEC_OPUS:
+            {
+                mtime_t i_length = i_duration * track. f_timecodescale *
+                        (double) p_segment->i_timescale / 1000.0;
+                if ( i_length < 0 ) i_length = 0;
+                p_block->i_nb_samples = i_length * track.fmt.audio.i_rate
+                        / CLOCK_FREQ;
+                break;
+            }
         }
 
         if( track.fmt.i_cat != VIDEO_ES )
-- 
2.9.5





More information about the vlc-devel mailing list