mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-07-04 09:47:33 +08:00
初步完成Windows下的移植
This commit is contained in:
@@ -2,8 +2,6 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <stdint.h> /* for uint32_t, etc */
|
||||
#include <pthread.h>
|
||||
|
||||
#include "SPSParser.h"
|
||||
|
||||
/********************************************
|
||||
|
||||
@@ -173,7 +173,7 @@ return kInvalidStream; \
|
||||
start += subsamples[i].clear_bytes;
|
||||
|
||||
const uint8_t* end =
|
||||
std::min(start + subsamples[i].cypher_bytes, stream_end);
|
||||
min(start + subsamples[i].cypher_bytes, stream_end);
|
||||
encrypted_ranges_.Add(start, end);
|
||||
start = end;
|
||||
}
|
||||
@@ -311,7 +311,7 @@ return kInvalidStream; \
|
||||
// The start code is inside an encrypted section so we need to scan
|
||||
// for another start code.
|
||||
*start_code_size = 0;
|
||||
start += std::min(*offset + 1, bytes_left);
|
||||
start += min(*offset + 1, bytes_left);
|
||||
}
|
||||
} while (*start_code_size == 0);
|
||||
|
||||
|
||||
@@ -113,7 +113,7 @@ namespace media {
|
||||
// (assuming no interlacing).
|
||||
int32_t top_foc = pic_order_cnt_msb + slice_hdr.pic_order_cnt_lsb;
|
||||
int32_t bottom_foc = top_foc + slice_hdr.delta_pic_order_cnt_bottom;
|
||||
*pic_order_cnt = std::min(top_foc, bottom_foc);
|
||||
*pic_order_cnt = min(top_foc, bottom_foc);
|
||||
|
||||
// Store state.
|
||||
prev_frame_num_ = slice_hdr.frame_num;
|
||||
@@ -182,7 +182,7 @@ namespace media {
|
||||
int32_t top_foc = expected_pic_order_cnt + slice_hdr.delta_pic_order_cnt0;
|
||||
int32_t bottom_foc = top_foc + sps->offset_for_top_to_bottom_field +
|
||||
slice_hdr.delta_pic_order_cnt1;
|
||||
*pic_order_cnt = std::min(top_foc, bottom_foc);
|
||||
*pic_order_cnt = min(top_foc, bottom_foc);
|
||||
|
||||
// Store state.
|
||||
prev_frame_num_ = slice_hdr.frame_num;
|
||||
|
||||
Reference in New Issue
Block a user