how to create a mpd file using MP4Box - streaming

I am new to this GPAC's MP4Box tool. Using this we can create MPD(Media Presentation Description) files for DASH. I dont know how to do this.
Have anyone created a MPD for a video file using this tool?

MP4Box -dash 2000 -profile dashavc264:live -bs-switching multi -url-template sample.mp4#trackID=1:id=vid0:role=vid0 sample.mp4#trackID=2:id=aud0:role=aud0 -out sample_200.mpd
sample.mp4 is mp4 file which you want to dashing.
sample.mpd is output file

They Very basic command will do
MP4Box -dash <segment length in msec> sample.mp4
For more information read here: DASH Support in MP4Box
or
MP4Box -h dash

Related

Powershell ffmpeg

I am successfully u sing ffmpeg via powershell to compress video files, however I can't get the compression to occur in a single location, I only have success when I make separate inputs and outputs.
For example, this command will be successful:
ffmpeg -y -i \\path\$x -vf scale=1920:1080 \\diff_path\$x
this will not do anyhting or will corrupt the file:
ffmpeg -y -i \\path\$x -vf scale=1920:1080 \\path\$x
I think I understand why this doesn't work, but I'm having a hard time finding a solution. I want the script to address a file and compress it in it's current location, leaving only a single compressed video file.
Thanks all
Not possible. Not the answer you want, but FFmpeg is not able to perform in-place file editing, which means it has to make a new output file.

Rename downloaded files with Wget -i

I am trying to download bulk images from URL'S listed in text file.
The command I am using is
wget -i linksfile.txt
The url structure of images in linksfile.txt is like below
www.domainname.com/197507/1-foto-000.jpg?20180711125016
www.domainname.com/197507/2-foto-000.jpg?20180711125030
www.domainname.com/197507/3-foto-000.jpg?20180711125044
www.domainname.com/197507/4-foto-000.jpg?20180711125059
Download images are being saved with filenames as
1-foto-000.jpg?20180711125016
2-foto-000.jpg?20180711125030
3-foto-000.jpg?20180711125044
4-foto-000.jpg?20180711125059
How can I omit all the text after .jpg ? I want file names to be saved as
1-foto-000.jpg
2-foto-000.jpg
3-foto-000.jpg
4-foto-000.jpg
and If possible can filenames be saved as
197507-1-foto-000.jpg
197507-2-foto-000.jpg
197507-3-foto-000.jpg
197507-4-foto-000.jpg
197507 is the folder name where images are hosted on server
I read tutorials on file name changing, Most of them are focused on downloading single file and using wget -o to change file name,, Is there any way we implement in above scenario ?
Maybe --content-disposition would do the trick.

upload files to github directory using github api

I want to upload files from my system to a directory in github repo using the api .Is there any api endpoint which allows me to do that.
You should use the GitHub CRUD API which wans introduced in .May 2013
It includes:
File Create
PUT /repos/:owner/:repo/contents/:path
File Update
PUT /repos/:owner/:repo/contents/:path
File Delete
DELETE /repos/:owner/:repo/contents/:path
There's deffinitly a way to do it.
This is how I did it;
curl -i -X PUT -H ‘Authorization: token 9xxxxxxxxxxxxxxxxxxxxxxxe2’ -d
‘{“message”: “uploading a sample pdf”,
“content”:”bXkgbm……………………………..”
}’ https://api.github.com/repos/batman/toys/contents/sample.pdf
Where the content property is a base64 encoded string of characters. I used this tool to encode my pdf file. https://www.freeformatter.com/base64-encoder.html
Notice, "batman" is the owner, "toys" is my repo, "contents" has to be there by default, and sample.pdf would the name of the file you want to upload your file as.
In short, stick to this format: /repos/:owner/:repo/contents/:path
And you can run the identical step for any of these files:
PNG (.png)
GIF (.gif)
JPEG (.jpg)
Log files (.log)
Microsoft Word (.docx), Powerpoint (.pptx), and Excel (.xlsx) documents
Text files (.txt)
PDFs (.pdf)
ZIP (.zip, .gz)
Good luck.
Btw, I have these same details added on here: http://www.simplexanswer.com/2019/05/github-api-how-to-upload-a-file/

How to programmatically concatenate two aac files

Does any one know how concatenate two aac audio files into one. I can do this with mp3 using ffmpeg but no luck with files with an m4a extension.
I tried the following with no luck:ffmpeg -i concat:"file1.m4a\|file2.m4a" -c copy output.m4a'
Just use cat:
cat file1.m4a file2.m4a >output.m4a

ffmpeg command line tool remove all metadata information after converting a file codec

I am converting abc.flac file to abc.mp3 using ffmpeg command line tool. But when abc.mp3 is created all metadata information get clear like artist name , album name etc. all field get empty.
i am using this command
ffmpeg -i "abc.flac" -acodec mp3 -ab 256 "abc.mp3"
this give me abc.mp3 i also try -map_metadata tag but it is not working
Have you any idea about this
Thanks in advance.