Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Revert "Merge pull request #36676 from ↵ | Ryuta Kamizono | 2019-07-17 | 1 | -1/+1 |
| | | | | | | | | | | | | wjessop/change_activestorage_metadata_duration_to_bound" This reverts commit a307c697b28e3c8b2860d2274c23e4d95dc164ae, reversing changes made to f30f76af747858826d3618866676cd5a4979e64a. Reason: This assertion is not failed even without this PR since both ffprobe versions (3.2.14 and 4.1.3) return the same duration 5.166648 for `video.mp4`. So there is no need to touch this assertion at this point. | ||||
* | Different versions of ffprobe can return subtly different video lengths | Will Jessop | 2019-07-14 | 1 | -1/+1 |
| | | | | Specify a range so we can take this into account, but not get caught out by 0, nil or way too large values. | ||||
* | Fix activestorage CI failure due to ffprove version differece | Ryuta Kamizono | 2019-07-14 | 1 | -1/+0 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Our CI environment is upgraded from stretch to buster then ffprove version is also upgraded from 3.2.14 to 4.1.3. https://packages.debian.org/stretch/ffmpeg https://packages.debian.org/buster/ffmpeg Somehow those ffprove returns different metadata for `rotated_video.mp4`. ``` $ ffprobe -print_format json -show_streams -v error rotated_video.mp4 > ffprobe41.json $ diff -ub ffprobe32.json ffprobe41.json --- ffprobe32.json 2019-07-14 20:02:13.000000000 +0900 +++ ffprobe41.json 2019-07-14 19:59:08.000000000 +0900 @@ -27,8 +27,8 @@ "time_base": "1/17594", "start_pts": 3976, "start_time": "0.225986", - "duration_ts": 91981, - "duration": "5.227975", + "duration_ts": 88000, + "duration": "5.001705", "bit_rate": "321546", "bits_per_raw_sample": "8", "nb_frames": "44", @@ -78,8 +78,8 @@ "time_base": "1/44100", "start_pts": 0, "start_time": "0.000000", - "duration_ts": 227865, - "duration": "5.167007", + "duration_ts": 227850, + "duration": "5.166667", "bit_rate": "109732", "max_bit_rate": "109732", "nb_frames": "223", ``` In the case on the `test "analyzing a rotated video"`, most important part is `assert_equal 90, metadata[:angle]`, the accidental difference of duration for ffprove version is out of scope for the test. | ||||
* | Don't fail ImageAnalyzer on unsupported types | Guilherme Mansur | 2019-04-24 | 1 | -0/+8 |
| | | | | | | | | | | Fix: #36065 The IamgeAnalyzer passes a image to ImageMagick without checking if the image is supported by ImageMagick. This patch checks that image is supported and if not logs an error and returns an empty hash instead of raising an error. This is the same error handling we do when we encounter a LoadError when mini_magick is not installed. | ||||
* | Move #extract_metadata_from to ActiveStorage's TestHelper | Ricardo Díaz | 2018-04-25 | 2 | -10/+0 |
| | | | | | | ImageAnalyzerTest and VideoAnalyzerTest are defining the same helper, since both use `#create_file_blob` that is defined in TestHelper, it makes sense to move `#extract_metadata_from` to that side. | ||||
* | Correct orientation detection | George Claghorn | 2018-01-31 | 1 | -2/+2 |
| | |||||
* | Swap encoded image width and height if angle is 90 or 270 degrees | George Claghorn | 2018-01-31 | 1 | -2/+15 |
| | |||||
* | Cope with videos with undefined display aspect ratios | George Claghorn | 2018-01-20 | 1 | -0/+9 |
| | |||||
* | Use helper method | George Claghorn | 2018-01-19 | 1 | -1/+2 |
| | |||||
* | Preserve display aspect ratio for videos with rectangular samples | George Claghorn | 2018-01-19 | 1 | -4/+18 |
| | |||||
* | Extract content types from blob data | George Claghorn | 2018-01-15 | 1 | -1/+1 |
| | |||||
* | Append extension to tempfile name | George Claghorn | 2017-12-31 | 1 | -1/+9 |
| | | | | | | Fixes analyzing an SVG image without an XML declaration. ImageMagick occasionally looks to the extension when it can't discern the type of an image file from its contents. References #31356. | ||||
* | Swap raw video width and height if angle is 90 or 270 degrees | George Claghorn | 2017-12-08 | 1 | -2/+2 |
| | |||||
* | Extract metadata from images and videos | George Claghorn | 2017-10-22 | 2 | -0/+51 |