Video Playlist with Interruptions (Gooning Software Concept)

Webteases are great, but what if you're in the mood for a slightly more immersive experience? Chat about Tease AI and other offline tease software.

Moderator: 1885

Post Reply
User avatar
masperturbator
Explorer At Heart
Explorer At Heart
Posts: 207
Joined: Sat Jun 22, 2019 5:01 pm
Gender: Male

Video Playlist with Interruptions (Gooning Software Concept)

Post by masperturbator »

A topic derail in a Cock Hero thread lead me to prototype the idea of a video playlist that is interrupted randomly by other clips. The attached Python script does that.

Current version:
playlist_0_6.7z
(3.79 KiB) Downloaded 347 times
Old versions:
Spoiler: show
playlist_0_5.7z
(2.54 KiB) Downloaded 137 times
playlist_0_4.7z
(2 KiB) Downloaded 74 times
playlist_0_3.7z
(1.39 KiB) Downloaded 101 times
playlist_0_2.7z
(1.38 KiB) Downloaded 123 times
playlist_0_1.7z
(1.15 KiB) Downloaded 99 times
playlist.7z
(919 Bytes) Downloaded 164 times
Change log:
Spoiler: show

playlist_0_6.py:
  • Runtime configuration changes are saved.
  • First GUI usage via Tkinter library.
  • Dialog window prompts for missing and incorrect configuration variables.
  • Configuration can be made through the program without a playlist.json existing at the start.
  • Add shebang for POSIX users.
playlist_0_5.py:
  • Logging starts earlier, chooses its filename from the script's name, and is written to the script's directory.
  • Move configuration to playlist.json in the script's directory.
  • Move configuration comments to README.
  • Add exception catching for log.
playlist_0_4.py:
  • Add a check that FFprobe executable is found.
  • Add checks that configurable variables are in order and that directories exist.
  • Add logging.
playlist_0_3.py:
  • get_length() now ignores special characters in file path names.
playlist_0_2.py:
  • Selections from both video directories are randomized.
  • Playlist ends on the current interruptible video when all interruption clips have been used.
  • Interruptions are at random intervals.
  • Playlist has a maximum length.
  • Playlist finishes the current interruptible video when maximum length is reached.
playlist_0_1.py:
  • Add interruption range variables.
  • Playlist file now encoded as utf-8.
  • File paths now support NTFS hard links and symlinks.
Given two directories the script will choose a random amount of times to interrupt videos from "video_dir" with ones from "video_interruption_dir". It builds an m3u8 playlist of these videos. Playlist works in VLC Media Player. The playlist uses m3u8 extensions provided by VLC for start-time and stop-time.

The script depends on Python 3 and FFmpeg. For FFmpeg use the shared build if you're also doing other audio or video work.

You may also use file system linking, hard links or symlinks, to make your video directories for this. In Windows use Link Shell Extension to assist.

Configuration is now guided by GUI prompts when playlist.json doesn't exist, or when a variable tests invalid.

Image

Image

Image

Image

If configuring manually, these variables in playlist.json need to be set correctly:

Code: Select all

{
    "ffprobe": "ffprobe",
    "video_playlist_file": "C:/playlist/playlist.m3u8",
    "video_dir": "C:/playlist/videos",
    "video_interruption_dir": "C:/playlist/interruptions",
    "min_interruptions": 2,
    "max_interruptions": 7,
    "max_playlist_minutes": 120,
    "video_player": "vlc"
}
Windows directory paths require double backslash, or single forward slash. Python emits single forward slash paths when GUI configuration is used.
Last edited by masperturbator on Sun May 31, 2020 10:06 pm, edited 2 times in total.
User avatar
hosenguy
Explorer At Heart
Explorer At Heart
Posts: 321
Joined: Sun Jun 14, 2015 11:22 pm
Gender: Male
I am a: None of the above

Re: Video Playlist with Interruptions (Gooning Software Concept)

Post by hosenguy »

Would you be able to use video player MPC?
I understand that MPC outputs timecodes during playback that are used by the Funscript players to control the Launch, the Handy, and the OSR. Your change would be to make MPC do what you are now doing with VLC.

This would allow video playback with interruptions and the other features of your software to control these devices in a whole new way!

There are also other players that output timecodes including Deo Whirligig and Scriptplayer. I think these would all work but I have not used them all.

Thanks.
User avatar
masperturbator
Explorer At Heart
Explorer At Heart
Posts: 207
Joined: Sat Jun 22, 2019 5:01 pm
Gender: Male

Re: Video Playlist with Interruptions (Gooning Software Concept)

Post by masperturbator »

hosenguy wrote: Mon Dec 07, 2020 7:23 pm Would you be able to use video player MPC?
In principle yes, in practice no.

The useful purpose of the script depends on an extension to M3U8 playlist which only VLC has.

Code: Select all

#EXTVLCOPT:start-time=647.64
#EXTVLCOPT:stop-time=706.337
In 2019 there was a rejected ticket asking for this to be added to MPC-BE. Probably the same goes for MPC-HC. I found no evidence of it existing in MPC land.
MPC-BE don't support stop by position and there is no plan to add.
VLC has years of timecode related activity, still ongoing.
The issue is that VLC is not 100% frame-accurate. We will get there and implement timecodes.
VLC's LUA extensions can get and set the timecode of the player object since at least 2011.

If a clever person wished to put time into forcing this script's concept into working with a player like MPC, they would have to do it by writing a program that plays videos through FFMPEG with FFMPEG told to stream the video file to MPC.
Post Reply

Who is online

Users browsing this forum: No registered users and 12 guests