Skip to content

Commit

Permalink
fix(android): bad rotation handling (#4205)
Browse files Browse the repository at this point in the history
  • Loading branch information
freeboub authored Sep 29, 2024
1 parent 0c6b47f commit 3ecf324
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,7 @@ private void updateForCurrentTrackSelections(Tracks tracks) {
case 90:
case 270:
layout.setVideoAspectRatio(format.width == 0 ? 1 : (format.height * format.pixelWidthHeightRatio) / format.width);
break;
default:
layout.setVideoAspectRatio(format.height == 0 ? 1 : (format.width * format.pixelWidthHeightRatio) / format.height);
}
Expand Down
4 changes: 4 additions & 0 deletions examples/basic/src/constants/general.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ export const srcAllPlatformList = [
cropStart: 3000,
cropEnd: 10000,
},
{
description: 'video with 90° rotation',
uri: 'https://bn-dev.fra1.digitaloceanspaces.com/km-tournament/uploads/rn_image_picker_lib_temp_2ee86a27_9312_4548_84af_7fd75d9ad4dd_ad8b20587a.mp4',
},
{
description: 'local file portrait',
uri: localeVideo.portrait,
Expand Down

0 comments on commit 3ecf324

Please sign in to comment.