Function __global->get_video_details_from_file

Definitions

sources/galleries2.php

  • Get width,height,length of a video file. Note: unfortunately mpeg is not possible without huge amounts of code.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$file_path PATH No No required parameter N/A N/A The path to the video file
$filename ?string No No required parameter N/A N/A The original filename of the video file (so we can find the file type from the file extension) (null: derive from $file_path)
$delay_errors boolean No No False N/A N/A Whether to skip over errored files instead of dying. We don't currently make use of this as our readers aren't sophisticated enough to properly spot erroneous situations.

Returns

  • The triplet of width/height/length (possibly containing nulls for when we can't detect properties) (false: error)
  • Type: ~array
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Get width,height,length of a video file. Note: unfortunately mpeg is not possible without huge amounts of code.
 *
 * @param  PATH $file_path The path to the video file
 * @param  ?string $filename The original filename of the video file (so we can find the file type from the file extension) (null: derive from $file_path)
 * @param  boolean $delay_errors Whether to skip over errored files instead of dying. We don't currently make use of this as our readers aren't sophisticated enough to properly spot erroneous situations.
 * @return ~array The triplet of width/height/length (possibly containing nulls for when we can't detect properties) (false: error)
 */

function get_video_details_from_file(string $file_path, ?string $filename, bool $delay_errors = false)