FunscriptToolbox

thank you for your tool to synchronize the funscript with remasters! I have used it with great success.

2 Likes

I was trying to remember the name of this plugin forever as I stupidly forgot to bookmark it. Iā€™m going to try to use it now for some Naughty America Remasters.

Edit: I see it logs the offsets to the console. Is there a flag that will save these results, or, even better, output to something like a CSV? Iā€™d like to capture this in an effort to write a simple tool to modify some cuepoints (aka bookmarks). XBVR and HereSphere (and probably DeoVR) use cuepoints, which can be synced from timestamp.trade, but often I run into problems where I have the cuepoints for the original scene but not the remaster. Since your program is already doing the hard work, and cuepoints can usually be edited in simple JSON (XBVR) and something similar with Stash, I am hoping it would be somewhat trivial to shift the cuepoints as well. If this isnā€™t something that you would want to include in your app, I imagine that I could at least take the offset info and whip up a quick python script to query XBVR or Stash and generate a new set of cuepoints for the remaster.

This is a fantastic tool!

Right now, no, there isnā€™t any option to save the offsets into a structured file (but it should be possible to parse the log file). It wouldnā€™t be too hard to add an option like that thought. Iā€™ll see what I can do when I have some time.

And, sure, I wouldnā€™t mind adding the option to ā€˜transformā€™ Xbvr/HereSphere if you find out the file format. From what I remember, Heresphere is using a binary format though so it might be a bit harder to do if itā€™s not documented.

1 Like

Yes to heresphere using binary, but it also imports from XBVR and Stash so you donā€™t really have to mess with the binary ever if you are using either.

Hereā€™s an example using timestamp.trade and the XBVR (and I think Stash) format. Note that HereSphere itself is able to use cuepoints that have a duration, so advanced formats will show the beginning and end.

Title: Bye Bye Babysitter
Studio: WankzVR
Human-Readable Cuepoints: Cuepoints
XBVR Cuepoints: Import in JSON format

I realize that I can just pipe the output into a text file and then parse the text but I thought it would probably be better to dump the output via an easy-to-add option. Unfortunately I donā€™t know any C# so I canā€™t contribute a PR.

Here is an example of a different scene where the XBVR output that has multiple tracks for the cuepoints. The cuepoints also have start and end times. The tracks are used for things like adding position (sitting, standing, etc), adding which actresses are involved at which times (in MFF+ scenes), etc.

In the example below, track 0 is the ā€œnormalā€ cuepoint describing the action, and track 1 describes the camera position (important for VR).

 {
   "scene_id": "povr-2383253",
   "cuepoints": [
    {
     "time_start": 783.629,
     "time_end": 1013.016,
     "track": 0,
     "name": "cowgirl",
     "rating": 0
    },
    {
     "time_start": 1052.922,
     "time_end": 1384.325,
     "track": 0,
     "name": "reverse cowgirl",
     "rating": 0
    },
    {
     "time_start": 1561.593,
     "time_end": 1587.289,
     "track": 0,
     "name": "cumshot",
     "rating": 0
    },
    {
     "time_start": 233.189,
     "time_end": 644.2,
     "track": 1,
     "name": "sitting",
     "rating": 0
    },
    {
     "time_start": 1482.288,
     "time_end": 1561.593,
     "track": 0,
     "name": "Hand Job",
     "rating": 0
    },
    {
     "time_start": 319.243,
     "time_end": 644.241,
     "track": 0,
     "name": "Blow Job",
     "rating": 0
    },
    {
     "time_start": 644.419,
     "time_end": 779.917,
     "track": 0,
     "name": "Blow Job",
     "rating": 0
    },
    {
     "time_start": 1013.016,
     "time_end": 1052.922,
     "track": 0,
     "name": "Blow Job",
     "rating": 0
    },
    {
     "time_start": 1384.325,
     "time_end": 1482.288,
     "track": 0,
     "name": "Blow Job",
     "rating": 0
    },
    {
     "time_start": 644.4,
     "time_end": 1611,
     "track": 1,
     "name": "lying",
     "rating": 0
    }
   ]
  },

Hey @Zalunda Iā€™m trying to update a script to a remastered version, but in addition to cuts in the video, the framerate also changed between the old version I have and the remaster, and that seems to trip up FSTB. Is there a way to indicate the source framerate so itā€™s taken into account when using the audiosync.verifyfunscript action?
Or would my best option be to reencode the old version to the new framerate, fix the old funscript to the new framerate and then use FSTB from that to the remaster?

Usually, changing the framerate of the video (ex. 30 => 60fps) wouldnā€™t change the audio track timing at all. So, itā€™s must be a ā€˜bad reencodingā€™ like VRPorn does (i.e. this).

Without knowing exactly how they ā€˜messed upā€™ the reencoding, itā€™s hard to say whatā€™s the best approach. As you said, reencoding is an option but, in that case, I would suggest extracting the audio first and ā€œexpanding/contractingā€ only the audio stream. It should be a lot faster than reencoding the whole video (which is not used by FSTB anyway).

If the output of FSTB is giving you ā€˜stepā€™ offset (like this), you might be able to estimate the expansion/contraction that need to be applied.

Itā€™s a VRBangers remaster (Morning Muffins) so it very probably something similar to the VRPorn issue.
The remaster is 59.94006 fps and the previous version I had (from SLR) was 60fps.

The logs I get are:

   From 00:00:00     to 00:00:04.933,     0 actions have been DROPPED
   From 00:00:04.933 to 00:01:43.200,   155 actions have been MOVED by -00:00:04.933
   From 00:01:43.200 to 00:01:43.208,     0 actions have been DROPPED
   From 00:01:43.208 to 00:03:04.267,   248 actions have been MOVED by -00:00:04.942
   From 00:03:04.267 to 00:03:41.750,   100 actions have been MOVED by -00:00:04.908
   From 00:03:41.750 to 00:07:07.750,   724 actions have been MOVED by -00:00:04.817
   From 00:07:07.750 to 00:07:07.783,     0 actions have been DROPPED
   From 00:07:07.783 to 00:07:07.900,     0 actions have been MOVED by -00:00:04.850
   From 00:07:07.900 to 00:09:31.800,   122 actions have been MOVED by -00:00:04.442
   From 00:09:31.800 to 00:09:31.842,     0 actions have been DROPPED
   From 00:09:31.842 to 00:10:31.492,   171 actions have been MOVED by -00:00:04.483
   From 00:10:31.492 to 00:10:34.017,     9 actions have been MOVED by -00:00:04.425
   From 00:10:34.017 to 00:10:34.083,     0 actions have been DROPPED
   From 00:10:34.083 to 00:12:07.200,   238 actions have been MOVED by -00:00:04.492
   From 00:12:07.200 to 00:12:08.075,     3 actions have been DROPPED
   From 00:12:08.075 to 00:13:43.133,   359 actions have been MOVED by -00:00:05.367
   From 00:13:43.133 to 00:15:10.275,   315 actions have been MOVED by -00:00:05.067
   From 00:15:10.275 to 00:15:41.550,    89 actions have been MOVED by -00:00:05.042
   From 00:15:41.550 to 00:15:42.225,     0 actions have been DROPPED
   From 00:15:42.225 to 00:19:48.817,     0 actions have been MOVED by -00:00:05.717
   From 00:19:48.817 to 00:19:57.517,     0 actions have been MOVED by -00:00:01.908
   From 00:19:57.517 to 00:20:00.992,     0 actions have been DROPPED
   From 00:20:00.992 to 00:22:36.083,     4 actions have been MOVED by -00:00:05.383
   From 00:22:36.083 to 00:24:35.725,   419 actions have been DROPPED
   From 00:24:35.725 to 00:26:00.867,   281 actions have been MOVED by -00:02:05.025
   From 00:26:00.867 to 00:26:52.600,   147 actions have been DROPPED
   From 00:26:52.600 to 00:27:14    ,    27 actions have been MOVED by -00:02:56.758
   From 00:27:14     to 00:30:00.258,   573 actions have been MOVED by -00:00:09.208
   From 00:30:00.258 to 00:32:55.433,   640 actions have been MOVED by -00:00:08.858

But Iā€™m not too sure how you got the offset from the values in the log in your example.

Well in the end, I just shifted the script for the new frame rate with a script and then did shifts for the cuts manually in OFS :smiley:

@MasterJ

@Zalunda Thank you again for linux compatible tools.
One question for you. After I resync for remastered, I usually delete the original video file but keep the orginal script. Do you see any benefit to making the .asig for the original video before I delete? Or just keep original video too?

Thanks!

Itā€™s up to you, but if you keep the original script, I suggest creating/keeping the .asig file. I wouldnā€™t keep the original video since it would take a lot of space for nothing.

If ā€œremaster #2ā€ is available in the future, theoretically, it would be better to synchronize it with the original script and .asig instead of ā€œremaster #1ā€'s video/script. But unless you do that often (i.e. original => remaster #1 => remaster #2 => ā€¦), it shouldnā€™t make a big difference.