php获取flv时间!有源码!拿来就可以使用!超级简单。
$flv_header_frame_length) { fseek($fp, $frame_size_data_length - $flv_header_frame_length, seek_cur); } $duration = 0; while ((ftell($fp) + 1) $flv_data_length) { $this_tag_header = fread($fp, 16); $data_length = bigendian2int(substr($this_tag_header, 5, 3)); $timestamp = bigendian2int(substr($this_tag_header, 8, 3)); $next_offset = ftell($fp) - 1 + $data_length; if ($timestamp > $duration) { $duration = $timestamp; } fseek($fp, $next_offset, seek_set);
http://www.bkjia.com/phpjc/486304.htmlwww.bkjia.comtruehttp://www.bkjia.com/phpjc/486304.htmltecharticlephp获取flv时间!有源码!拿来就可以使用!超级简单。 ?php function bigendian2int( $byte_word , $signed =false){ $int_value =0; $byte_wordlen = strlen ( $byte_word...