# Automatic split output files



## un_pogaz (Aug 31, 2017)

It would be very useful to add an option that automatically divided the output file (time or file size)
There would be a lot of advantage, especially when editing (segments loading faster than one BIG file / choice of section useful or not...)

Important/Useful: FFmpeg is already able to do this ( ffmpeg.exe -i "test.mp4" -c copy -f segment -segment_time <sec> -reset_timestamps 1 "test_%02d.mp4" )[ The %02d will automatically number the output files, do not put -reset_timestamps to 0]
Ok, it only splits in second, but as OBS knows the bitrates, one can "calculated according to the size".

PS: I do not understand how to enter this command line in the "Custom Muxer Setting", Help?


----------



## Fenrir (Aug 31, 2017)

You can't.

OBS creates a single output file, and the task you're trying to accomplish is best left to post production.


----------



## Kawphydon (Nov 15, 2017)

I'm with un_pogaz... One of the things I'm trying to limit is the amount of time I spend in post. Particularly given the vulnerability of MP4 to corruption on longer files, as well as, I don't want to have to upload a 5-10 hour file to start getting clips edited out. It is extremely frustrating having both no way to easily split the files, and no documentation of the custom muxer settings to see what they even "can" do. 

This is a basic functionality of certain competing open source recording programs, and it seems a shame that it's been overlooked as a feature in OBS this long. 

So... if the final support answer is "it can't be done in the current version" and the "do it in post" is an inadequate solution for an end user ... please advise where, other than this "Feedback and Suggestions" area it would be better for submitting this automatic recorded file splitting as a feature request such that it would be given proper consideration?


----------



## Jack0r (Nov 15, 2017)

Fenrir mainly pointed out that you cannot do it at the moment as this function has not been implemented. 

The biggest problem with OBS development is that most stuff is done by a single person (we have a team of friendly helpers, but not that many programming people). So he has to give everything a priority and so far splitting by file size or time was not a high priority. The place in which you posted is correct and we try to give every suggestion a proper consideration. Many things can be done by plugins for example.

The vulnerability of mp4 files is no argument unfortunately, if you us mp4 you want to loose footage.


----------



## Fenrir (Nov 16, 2017)

You can just remux files to MP4 after recording direct to a more resilient format such as FLV or MKV, by using the remux option from the file menu in OBS.


----------



## un_pogaz (Nov 16, 2017)

Nope, bad idea. FLV can't use multi audio chanel, and MKV is not supported by all video editing software (In fact, none that I know)
To avoid file corruption problems, use MOV


----------



## RytoEX (Nov 16, 2017)

un_pogaz said:


> Nope, bad idea. FLV can't use multi audio chanel, and MKV is not supported by all video editing software (In fact, none that I know)
> To avoid file corruption problems, use MOV


That's why you remux the MKV to MP4 using File > Remux Recordings.  Of course, you can also remux an MOV to MP4.  I don't know enough about the durability or other particulars of the MOV format to discuss pros/cons of them.


----------



## FynaLyzer (Oct 5, 2018)

This is an old topic but IDK if it has been solved yet. My solution is to use the keyboard shortcuts. Find shortcuts that aren't use by the program/game you are recording and set them to start/stop recording. Then periodically start and stop to create new files.


----------



## ghostravenstorm (Aug 7, 2019)

What if we're recording to FAT32 for portability? Also if we're recording raw, a single recording session will be massive. From a data rigidity point of view, and data transfer point of view (because something could interfere and cause corruption during transfer), it's objectively better to work in many smaller files than one big one. Don't forget the seek time required for a program like Adobe Premiere to injest a single 50GB raw video file for editing. Not pratical.

A feature like this should be looked into.


----------



## dodgepong (Aug 7, 2019)

You can show your support for this feature here: https://ideas.obsproject.com/posts/111/add-a-split-file-feature


----------



## krychla (May 13, 2020)

Hi there. I'm using this solution for auto press keyboard key i mapped  (*R) for recording my videos (*.MKV - It can handle my recordings even app crashes, or going something wrong).

https://www.howtogeek.com/97998/how-to-make-your-computer-press-a-key-every-x-seconds/

*Other happy tweak tools for edit video with no encoding.
1. In OBS: Go to FILE---REMUX RECORDINGS And in popup window click on dotted pictogram *in OBS recording section* to choose file to mux.
2. Press REMUX button in bottom section of the window * It will remux your file to MP4 file. *very fast feature :))

I usually do some trimming in my mp4 files. Here is link to a very useful app i prefer :)) (*LosslessCut, NO ENCODING).

https://www.videohelp.com/software/LosslessCut


----------



## krychla (May 13, 2020)

Hi again. Here's my current setup:
Autohotkey - https://www.autohotkey.com/
List of supported keys - https://www.autohotkey.com/docs/KeyList.htm
I made two scripts and i run them manually. First I push OBS record button in OBS as usual + you need to map keys in OBS for start/stop rec (delete/insert). Than i run the obs_stop.ahk script and finally obs_rec.ahk. The delay between stop recordind and start recordind takes cca 1 - 1,5sec. I do this by manual running both of the scrips just once after running/setting OBS itself . *Maybe someone here will do this by running just one script. :)) But for my purposes it's ok.

Setup for AutoHotkey (Stop recording/delete - Start recording/insert):
1. obs_stop:

```
#Persistent
SetTimer, PressTheKey, 3600000
Return

PressTheKey:
Send, {Delete}
Return
```

2. obs_rec:

```
#Persistent
SetTimer, PressTheKey, 3600000
Return

PressTheKey:
Send, {Insert}
Return
```


----------



## krychla (Jun 3, 2020)

krychla said:


> Hi again. Here's my current setup:
> Autohotkey - https://www.autohotkey.com/
> List of supported keys - https://www.autohotkey.com/docs/KeyList.htm
> I made two scripts and i run them manually. First I push OBS record button in OBS as usual + you need to map keys in OBS for start/stop rec (delete/insert). Than i run the obs_stop.ahk script and finally obs_rec.ahk. The delay between stop recordind and start recordind takes cca 1 - 1,5sec. I do this by manual running both of the scrips just once after running/setting OBS itself . *Maybe someone here will do this by running just one script. :)) But for my purposes it's ok.
> ...


SetTimer value 3600000 = 1 hour in miliseconds. 
Timeconverter:








						Time Converter
					

Convert easily between milliseconds, seconds, minutes, hours, days, weeks, months, years and other units of time




					www.thecalculatorsite.com


----------



## mkDaniel (Aug 27, 2022)

This feature will be added in OBS version 28.


----------

