futzu / SCTE-35_HLS_x9k3

HLS and SCTE-35 x9k3 is a HLS Segmenter with SCTE 35, and Live Streaming from Non-Live Soures and Looping.
67 stars 17 forks source link

Add ad breaks to existing videos so they work with google ad manager server-side ad injection #35

Closed raggedstetson closed 2 months ago

raggedstetson commented 4 months ago

I am new to the field of video production, and I was attempting to use x9k3 to solve a problem, but I am not certain if it is the correct tool. I was hoping I might be able to contact you via email or even jump on a phone call.

I am working with a company that produces live streamed events. We save the video stream from those events, and then also make them available as VOD on different platforms. I would like to integrate with google ad manager, but google requires "preconditioning" the videos. In particular, I would like to do server-side ad injection (SSAI, also often called DAI) using a stitcher. I see that google ad manager can accept an MRSS feed (which has a google-specific namespace to identify cue-points) or they can accept files from BrightCove.

My goal is to allow my content editors to create a new piece of content (maybe an edited live stream or even a highlight reel pieced together from many streams). I would then like the editors to be able to place ad breaks (maybe cue-points, maybe SCTE 35 markers, I'm not sure) into the video at any points they choose. I attempted to do this with your x9k3 tool and adbreak tool, but it seemed as if the resultant m3u8 file was not re-encoded (but rather just split on the nearest I-Frame) - I say this because it appeared that the cue-out was not at the offset I had configured, but somewhat close.

I would like my users to be able to place ad breaks at specific locations and then have google ad manager respect those locations - possibly by having an MRSS feed that google ad manager can ingest. I am somewhat shaky on the details since it seems redundant to me that I should need cue-points in the MRSS feed but then also need the m3u8 file to reflect those same cue points.

In short, I would be very grateful for any assistance you might be able to provide to help me solve this problem. If you know how to add ad breaks to existing videos so they work with google ad manager server-side ad injection, I would love to learn how. I am also happy to compensate you for any assistance, or I would be grateful if you could refer me to another person if you are not familiar with this particular situation.

Thank you.

futzu commented 4 months ago

First thing you need to understand, splice points must be at iframes. Other types of frames that occur between iframes are modifications to the iframe and not complete images themselves. x9k3 is not an encoder, but it is a segmenter If you need to re-encode, re-encode and then pass it to x9k3 and let it segment the video. If you are accepting video from lots of different sources, you probably will need to re-encode to a standard format, and when you do that, I'd add an iframe at every second. A lot of people will balk at that, and they also miss a lot of splice points. Having an iframe every second means that in a worst case scenario, your splice point would be off by one second, and I have a technique that will reduce the worst case from 1 second down to 0.45 seconds.
This is what I do for a living. For the last four years I have done nothing except SCTE-35 and HLS. If you want to hire me, this is absolutely in my skill set and honestly I am the best person at know at this sort of thing.

Just to put things in perspective, if you hire me to do a project, let's say it takes 3 months, if you do it by yourself, it will take at least a year.

What I just told you about iframes, would have taken a couple of months to sort out, if not longer. Five years ago, it was common to see one iframe every six seconds, now that's considered insane, and most people are using two to four seconds. I spent months testing GOP sizes and that's why I say one every second.

Adrian

raggedstetson commented 4 months ago

Adrian,

Thank you for your reply. I definitely understand why splice points are at iframes; from my college days I recall p and b frames where just differentially encoded using a DCT after motion compensation. I'm not sure if that's exactly how it's still done today, but I imagine it's something similar. I'd like to speak more and discuss what we are doing and how we might be able to lay out a project where we can work together. I suspect your expertise will be important not only for our current goals, but for many future projects as well. What is the best way for us to contact each other directly?

futzu commented 4 months ago

I deleted the previous message because it has my email in it. I hope I didn't come across as rude, I was trying to say that to everyone, not just you. I used to spent 15-20 hours a week answering questions and I wasn't getting paid for it. It was driving me crazyt, I had issues turned off for months, I just turn them back on recently. 90% of the issues people we sending to me were not about my software, they were questions about SCTE-35, MPEGTS, HLS, and Multicast,

raggedstetson commented 3 months ago

No worries, I understand completely. Unfortunately, I was traveling, so I didn't get a chance to copy your email before you removed it. I did read your last post, and I just smiled, it's a normal response after being a developer for a few decades. I am still pushing forward on SSAI with GAM, along with numerous other tasks. I found a handful of great links on the topic.

https://www.youtube.com/watch?v=2xrm19ugDls https://www.unified-streaming.com/videos/ad-insertion-and-replacement-for-vod-explained https://www.youtube.com/watch?v=DMT3wxWLGfk https://www.youtube.com/watch?v=AummdshBJ5g

I am also looking forward to speaking with some vendors who specialize in MRSS feeds that work with GAM. I saw the pay rate you previously posted, and it is within range, but I would like to be certain I have exhausted a few other avenues before we start doing any custom development. I can keep in touch through this "issue" so you needn't put your email address here - I can also create a temporary email address in yahoo and post it here if we decide to pursue something together. Presently, I have to find a good react/next/mui developer to handle some contract work. After that, I will swing back around to SSAI.

futzu commented 3 months ago

No problem, it's a@slow.golf. MRSS is not a big deal. Honestly, it's probably a lot less work than you think. SCTE-35 stuff is all I've done for the last four years, most of that has been SCTE-35 and HLS.

I don't know any react/next/mui types, well I do know someone,
my second and third ex-wife, and she is really good, but she's kind of a grouch, and she hates me. :)