MCPcopy Create free account
hub / github.com/HandBrake/HandBrake / hb_ps_stream_init

Function hb_ps_stream_init

libhb/stream.c:2397–2480  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2395}
2396
2397static void hb_ps_stream_init(hb_stream_t *stream)
2398{
2399 int i;
2400
2401 if ( stream->pes.list )
2402 {
2403 for (i=0; i < stream->pes.alloc; i++)
2404 {
2405 stream->pes.list[i].stream_id = -1;
2406 stream->pes.list[i].next = -1;
2407 }
2408 }
2409 stream->pes.count = 0;
2410
2411 // Find the audio and video pids in the stream
2412 hb_ps_stream_find_streams(stream);
2413 hb_ps_resolve_stream_types(stream);
2414
2415 if( stream->scan )
2416 {
2417 hb_log("Found the following streams");
2418 hb_log(" Video Streams : ");
2419 for (i=0; i < stream->pes.count; i++)
2420 {
2421 if ( stream->pes.list[i].stream_kind == V )
2422 {
2423 hb_log( " 0x%x-0x%x type %s (0x%x)",
2424 stream->pes.list[i].stream_id,
2425 stream->pes.list[i].stream_id_ext,
2426 stream_type_name2(stream,
2427 &stream->pes.list[i]),
2428 stream->pes.list[i].stream_type);
2429 }
2430 }
2431 hb_log(" Audio Streams : ");
2432 for (i = 0; i < stream->pes.count; i++)
2433 {
2434 if ( stream->pes.list[i].stream_kind == A )
2435 {
2436 hb_log( " 0x%x-0x%x type %s (0x%x)",
2437 stream->pes.list[i].stream_id,
2438 stream->pes.list[i].stream_id_ext,
2439 stream_type_name2(stream,
2440 &stream->pes.list[i]),
2441 stream->pes.list[i].stream_type );
2442 }
2443 }
2444 hb_log(" Subtitle Streams : ");
2445 for (i = 0; i < stream->pes.count; i++)
2446 {
2447 if ( stream->pes.list[i].stream_kind == S )
2448 {
2449 hb_log( " 0x%x-0x%x type %s (0x%x)",
2450 stream->pes.list[i].stream_id,
2451 stream->pes.list[i].stream_id_ext,
2452 stream_type_name2(stream,
2453 &stream->pes.list[i]),
2454 stream->pes.list[i].stream_type );

Callers 1

hb_stream_get_typeFunction · 0.85

Calls 5

hb_logFunction · 0.85
stream_type_name2Function · 0.85

Tested by

no test coverage detected