-
-
Notifications
You must be signed in to change notification settings - Fork 425
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make video codec and scale configurable #833
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we make changeable the video path to an arbitrary extension like
.avi
?Since:
=> Can get broken video. We cannot play the video even we change the extension of
sample.mp4
to.avi
=> Can get playable video
=> Can get broken video, but we cannot play the video even we add
.avi
tosample
file.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm trying not to over engineer it. If the file is returned as base-64 encoded then the user is free to set any extension. And even if one sets
mp4
instead ofavi
then video players are still able to play it properly, since they only care about the header information.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understood.
It was because when I ran https://github.com/appium/ruby_lib_core/pull/164/files#diff-a09385fd21af58063384116d47f91d91R27 ,
I was not able to play
recorded_file_ios.avi
by QuickTime. The templorary file in/var/folders/y6/524wp8fx0xj5q1rf6fktjrb00000gn/T/20181021-40254-ug067c.gg8l/appium_3febaf.mp4
which created in Appium server side also was not.The
stop_and_save_recording_screen
is simply store decoded base64 data into a file as below.I was able to play the result like below under this PR.
By changing
this.videoPath
to use.avi
format instead of.mp4
in my local, I could get playable video,recorded_file_ios.avi
, with the former scenario. (ffmpeg changes headers following exported file, I guess since we can get an error likeUnable to find a suitable output format for 'sample'
when we do not set output file properly.) So, I read options like-f
if we could get a file which does not depend on the extention of file output.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Quicktime is not very smart. I'd rather use VLC or Mplayer ;)
But anyway, you see it is possible to change the extension locally in your case, so this should not be an issue.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I was able to play it by VLC.
ah..