I have a mediaplayer that can only read samba shared files. I would like to play http stream (from my dreambox for instance).
My idea is to share a folder on my linux. In this share, I will put a (fake?) file for each tv channel I want to be able to watch (ex : channel1.ts, channel2.ts ...).
The mediaplayer can only read these file as it should with regular files. My need : do something that "listen" for access on these files so that when my mediaplayer access it, it fires a mencoder -oac copy -ovc copy -o channel1.ts http://path.to.the.broadcast.ts.
I tried using inotify on an empty file. It fires the mencoder well BUT the mediaplayer stops before encoding starts (because the file is empty so it reaches the end before it starts). Perhaps, have to fill 5s of video in order to buffer the read ?
Could be nice to use a "fifo" => I tried it, the mediaplayer waits, when I do the mencoder, the fifo starts growing, the mediaplayer plays it ! Yeahh !!!... BUT inotify seems not to react on a fifo... so I can't fire mencoder automatically.
Every suggestions welcome.
Basic points :
The media player can ONLY reads regular files
File must be in a samba shared folder
Record must be "fired" on demand (when mediaplater try to access it)
Could be nice to watch for "inactivity" in order to stop recording / emptying buffer file
It is not easy to formalise this question. I am a bit disapointed and I even't don't know what kind of search I could googelise for that.
Hope some gurus here will find something to do the trick
Cheers.
You might want to look at the techniques Hierarchical Storage Management and on-access Virus Scanners use, as they need to do similar interruption before the normal access.
e.g. Use Talpa to intercept open operations in the selected directory, and replace the file at that point.
Related
I discovered that Windows Photo has a pretty good basic video editor hidden in it.
My wife used it to edit a family video. Then she wanted to save the project (clips and project file, not just the final product) to USB drive.
Photo only gives you one option: Save to OneDrive. The claim is that other OneDrive devices running Photo will then be able to see the Project.
However, careful inspection of OneDrive yields no file with the title of the project and nothing that obviously looks like a video editing project file.
Does anybody know how they pulled this off and where they have hidden the project information? It can't be buried in the Registry, because that wouldn't transfer through OneDrive.
Every video clip used to create a new video, no matter what the source, is first copied to my C: SSD drive into my 'Pictures' folder.
I found the program created a new folder called 'Video Projects' in my Pictures folder.
The program does not delete these videos copied to my C: SSD drive when the program is through with them.
I must go in and manually delete the working copies of videos the program makes.
C:\Users\Your_User_Name\Pictures\Video Projects
There were two reasons I was looking into this.
1) For a video project, set the duration for all the photos in a storyboard to something other than the default. (Why isn't this built in?) and;
2) On another project, reset the duration that I'd set on a bunch of photos so it could auto sync with music.
So, I looked into this a bit, and for reference the data is stored in an Sqlite database called MediaDb.v1.sqlite located by default here (replace YOURUSERNAME) C:\Users\YOURUSERNAME\AppData\Local\Packages\Microsoft.Windows.Photos_8wekyb3d8bbwe\LocalState
You can load the database using an Sqlite reader like DB Browser however you can't update it because it contains an unrecognised database collation (column character set) called NoCaseUnicode which you can about more here
There are others who are reporting similar problems trying to access this file.
I just finished a short project. I noticed an option to make a backup (click the three dots in the top right corner). That created a .vdp file. The file is 35 MB. The total size of the pictures and audio track is 30.1 MB, so it looks like it puts everything into this one .vdp file. The idea, as I understand it, is that you can take this .vdp file with you and import it into the video editor on a different computer (or same computer with new hard drive) and resume working on your video from there.
Of course relying on a proprietary file, in my opinion, is not great. You're trusting that Microsoft will continue to support the file format in the future. And as we've seen, over time, Microsoft has a habit of dropping support for popular applications that they bundle with Windows. Make sure you hang on to those original photos/videos!
My saved videos were located in c/Pictures/wallpapers/Video Projects
I am having issues with my "Automatically Add to iTunes". As a result, I am trying to make an Applescript that will be stored on my USB, and when I click on a certain Music File, I want it to launch an applescript.
I did some research, and everyone keeps telling me about Launchd. How would I use this command to run an applescript saved as .app? I want to store this Music File and the Applescript on my USB, because I have multiple computers. Can I get it to run as soon as I open a specified music file? Thank you.
I eventually figured out a way to do what I wanted, which was to somehow play a music file from inside the application. All I did was use the idea of resources because it can reference itself without having to rely on a file stored somewhere else on the system. Here's a link to essentially what I did: https://apple.stackexchange.com/questions/157724/applescript-path-to-files-in-applications-resources
in short, I contained the music file within the app itself and played it when it was needed.
I love listening to podcast-style audio while walking or in the car, and I love studying with the help of the text-to-speech feature in Mac OS Yosemite. I want to download hour-long audio files to listen to in the car (I have already been accustomed enough to sometimes robotic-sounding tts voices).
How do I download text-to-speech to an audio file such as mp3? I can "speak selected text when the key is pressed" and press option+esc, but shouldn't it be easy to just download the audio (without doing tedious stuff like recording tts audio playing)?
You can try the say command in from the CLI (e.g. via “Terminal.app”). There is a detailed description in the man-page (type in say, right-click on the word and select “Open man page”). The --output-file= option does what you want.
There also is a number of apps that wraps this functionality in one way or another.
You need to save text from "text-to-speech" into a file, then when you will have a text there, you should convert text file to audio file
More information on how to do that, you can read here:
https://cloud.google.com/text-to-speech/docs/quickstart-protocol
How decoding files, you can read here:
https://cloud.google.com/text-to-speech/docs/base64-decoding
I'm making an application that downloads video files from the internet.
The application needs to launch the system's default video player to play these files while they are being downloaded.
I'm not interested in implementing a video (or network) stream to make this work. The videos are being downloaded in sequential order. I need to simulate the process of a user clicking on the video file from file explorer while it is downloading (which always works provided that enough bytes are saved).
To achieve this I spawn a child process that runs
start filepath/filename.avi
but it fails saying the file is in use by another process.
This command also fails if I type it in the cmd while the file is downloading.
However, if I double click the file it will start to play normally in the system's default video player.
What command can I use to make the file open in the system's default video player while it is being downloaded (used by another process)?
Thanks.
Note: files may be of any type, not only .avi like in the example
Inspired by Christmas, I started writing a Linux shell script that essentially grabs today's episode of the daily children's Christmas show from a TV station's online library. My script does the following:
check how many episodes are already downloaded to identify which is next,
open the TV station's web page for that next episode,
programmatically click in the embedded streaming object to activate the stream,
programmatically click "pause" so it doesn't actually play out loud,
missing: grab the video manifest from the browser,
use the AdobeHDS script to download the fragments and join them into one FLV file,
use avconv to convert the FLV file into a friendlier MP4 format.
Well, my step "5" is broken, and that's where I need your help! My problem is that the manifest file doesn't become available until after the streaming object has been activated, and I don't know how to access that programmatically. Here's my manual workaround:
once the web page loads and the script has clicked on "play", the manifest becomes available,
I use Adblock's "open blockable items" to search for "manifest" in the page's resources,
I manually(!) copy the manifest URL into a shell read prompt. From here, the script continues automatically.
Obviously, this manual step prevents me from setting the script up as a cron task.
Here's a Pastebin snapshot of my script.
Disclaimer: I'm totally new to programming, and I realize that a shell script is not really "programming" but sort-kinda is. I am doing this as an interesting exercise and to learn some basic concepts. You can say it's not mission-critical ;-) but you know how you start doing something, only to realize you need to dig deeper into some detail, and then deeper still, and so on. This is where I am finding myself right now. I didn't expect things to become this complicated, but I guess most programmers have that experience at some point :-)
You can use
HDS Link Detector
to capture this information. Example output
http://drod01c-vh.akamaihd.net/z/all/clear/streaming/ca/547d12116187a20e4c6282ca/Jullerup-Faergeby--3-24-_ecfaae965b3344f2907ebf19d852761a_,1125,562,248,.mp4.csmil/manifest.f4m?g=REZLVPFXIRIX&hdcore=3.5.0&plugin=aasp-3.5.0.151.81