[TIMOB-25916] iOS: Ti.UI.VideoPlayer ignores changes to the "scalingMode" property
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2018-05-15T07:43:21.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Release 7.3.0 |
Components | iOS |
Labels | ios, videoplayer |
Reporter | Andrea Jonus |
Assignee | Hans Knöchel |
Created | 2018-03-30T11:09:38.000+0000 |
Updated | 2018-06-21T16:43:49.000+0000 |
Description
When I try to change the property "scalingMode" of Ti.UI.VideoPlayer, the player ignores any constant and defaults to Ti.Media.VIDEO_SCALING_RESIZE ("AVLayerVideoGravityResize").
This happens both at creation time and at runtime.
Test case:
index.js
$.index.open();
index.xml
<Alloy>
<Window class="container">
<VideoPlayer class="video" />
</Window>
</Alloy>
index.tss
".container": {
backgroundColor:"#333"
}
".video": {
width: 200,
height: 300,
scalingMode: Ti.Media.VIDEO_SCALING_RESIZE_ASPECT_FILL,
url: 'http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4',
}
Expected result: the video is cropped to fill the defined size, keeping the aspect ratio.
Actual result: the video is resized and stretched to fill the defined size.
Attachments
File | Date | Size |
---|---|---|
Screenshot 2018.03.30 13.04.51.png | 2018-03-30T11:09:02.000+0000 | 1016978 |
Community PR (thanks [~ajonus]!): https://github.com/appcelerator/titanium_mobile/pull/9973 Test-Case: See above
*Closing ticket.* Fix can be seen in SDK Version:
7.3.0.v20180618182516
*FR (Passed) Test Steps:*Created an application using the code above
Ran the program
Pressed play on the Video Player
Able to see that video was cropped to fill the defined size, keeping the aspect ratio
*Test Environment*