Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > General > DVD2AVI / DGIndex

Reply
 
Thread Tools Search this Thread Display Modes
Old 3rd November 2016, 22:26   #1  |  Link
Katie Boundary
Registered User
 
Katie Boundary's Avatar
 
Join Date: Jan 2015
Posts: 1,070
What language are DVD2AVI and DGIndex written in?

I'm interested in learning how to code. I'm also interested in creating a fork of DGIndex that's specifically optimized for generating 60hz d2v files and variable-framerate MP4 files from hybrid content. Hence, the question.

Edit: frame rate. Not bitrate.
__________________
I ask unusual questions but always give proper thanks to those who give correct and useful answers.

Last edited by Katie Boundary; 7th November 2016 at 04:39.
Katie Boundary is offline   Reply With Quote
Old 3rd November 2016, 23:30   #2  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
DGIndex / DGDecode are written mainly in C, there is some C++ in DGDecode as far as I recall and both have external Assembler modules for time critical stuff like iDCT.
__________________
Groucho's Avisynth Stuff
Groucho2004 is offline   Reply With Quote
Old 3rd November 2016, 23:38   #3  |  Link
Katie Boundary
Registered User
 
Katie Boundary's Avatar
 
Join Date: Jan 2015
Posts: 1,070
Cool, thanks. It looks like I'll be learning C...
__________________
I ask unusual questions but always give proper thanks to those who give correct and useful answers.
Katie Boundary is offline   Reply With Quote
Old 6th November 2016, 11:28   #4  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,852
It's easy enough to produce variable frame rate video now containing 23.976fps and 29.970fps sections with the TIVTC plug-in. I'm not sure how you'd go about deinterlaciing any video sections to 59.940fps rather than 29.970fps though as I haven't had a need, but does anyone know if that's currently do-able? I'd be interested to know myself for future reference.

I guess I should be expecting a PM from Katie with a heartfelt apology sometime fairly soon, given all the arguing and abuse I had to endure.
Only a few months ago......

Quote:
Originally Posted by hello_hello View Post
Other options these days might include converting to a 60fps or 120fps constant frame rate. 60fps could at least use a 3:2 progressive pattern for the "film" parts (which is what you get when watching 24fps progressive on a monitor refreshing at 60Hz anyway) rather than repeating every fourth frame at 24fps.
Quote:
Originally Posted by Katie Boundary View Post
That option isn't very useful for converting to VCD-compliant MPEG-1, or making anime music videos, or much of anything.
Quote:
Originally Posted by hello_hello View Post
You could also treat mixed frame rate content as variable frame rate.
Quote:
Originally Posted by Katie Boundary View Post
If you wanted to store everything in some obscure format like Oggmux or Matroska that only 0.1% of people have ever heard of and would be capable of watching, sure.
hello_hello is offline   Reply With Quote
Old 7th November 2016, 04:45   #5  |  Link
Katie Boundary
Registered User
 
Katie Boundary's Avatar
 
Join Date: Jan 2015
Posts: 1,070
That's right, hello! Instead of honoring pulldown flags and then relying on some algorithm's best guesses to put humpty-dumpty back together again, you'll be able to just convert VFR video natively like we should have been doing all along! Won't that be neat?
__________________
I ask unusual questions but always give proper thanks to those who give correct and useful answers.
Katie Boundary is offline   Reply With Quote
Old 7th November 2016, 10:26   #6  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,852
On your ignore list, off your ignore list...... but that wasn't much of an apology.

DecombVFRMod
I had a quick look through the manual and it also appears to be designed for outputting 23.976fps and 29.970fps combinations as VFR, much like TIVTC.
I suspect one reason for that is the de-interlacing is adaptive and in theory only de-interlaces combed frames, and even then only de-interlaces the area of those frames where combing is detected. Still, sometimes de-interlacing to 59.940fps would probably be preferable.

TIVTC's algorithms are very good at "guessing", especially in 2 pass mode.
If pulldown is hard-coded rather than applied via flags, a "best guess" still needs to be relied upon.
Your decoder would need to be able to detect and remove pulldown, detect interlacing & de-interlace to "double frame rate" and output a timecodes file. If a source has hard-coded pulldown, how do plan on bypassing the "guessing"?
Realistically, you'd have to be building algorithms similar to those already being used into the deocder.

Surely there must be a way to get TIVTC to do the work while de-interlacing to double frame rate? I've used it to output VFR several times before, and it'll take frames from an alternative clip when it detects combing so you can use any de-interlacer, but I haven't worked out if there's a way to get it to take 2 frames from a de-interlaced clip and double the frame rate. If anyone knows a way to do that, I'd be keen to learn for future reference, or is it generally accepted it's not worth the effort for hybrid sources?

Last edited by hello_hello; 7th November 2016 at 14:34.
hello_hello is offline   Reply With Quote
Old 9th November 2016, 00:46   #7  |  Link
Katie Boundary
Registered User
 
Katie Boundary's Avatar
 
Join Date: Jan 2015
Posts: 1,070
It occurred to me early on that if someone wants to export a project file in which the field operation is set to 60hz or VFR, and then frameserve that through AVIsynth, then the bob-deinterlacing algorithm(s) would need to be implemented in a very unusual place. I've been looking through the DGIndex documentation, and it says that d2v files merely store an integer value representing the field operation to perform, leaving the actual execution to mpeg2dec3.dll/mpeg2source. This means that I will need to create a fork of mpeg2dec3 that handles these additional field operations.

Also, if I allow users to pick a bobbing algorithm instead of forcing iBob or Yadif on them, then project files will need to carry an entirely new field specifying the algorithm. This might justify a different file extension: .d4v
__________________
I ask unusual questions but always give proper thanks to those who give correct and useful answers.
Katie Boundary is offline   Reply With Quote
Old 9th November 2016, 03:32   #8  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,852
Still no apology??

Quote:
Originally Posted by Katie Boundary View Post
Also, if I allow users to pick a bobbing algorithm instead of forcing iBob or Yadif on them, then project files will need to carry an entirely new field specifying the algorithm. This might justify a different file extension: .d4v
It's easy enough to let users pick a different de-interlacing method, just provide an option to take frames from a second clip, which the user can de-interlace how they like. Several de-interlacers and IVTC plugins already have this ability. Unless you plan on implementing QTGMC as part of your plugin that's the only way I'd use it, because these days I won't de-interlace video with anything else. Yadif is fairly average by comparison and I've no idea what iBob is.

It's all do-able at present, aside from being able to de-interlace video sections to 59.940fps (as far as I know). Mind you the more I think about it, the more I wonder if de-interlacing to 59.940fps is really all that important for hybrid sources. "Film" and "video" look totally different, and while the interlacing and frame rate is only part it, de-interlacing to 59.940fps would probably make the difference between them more obvious. I don't work with much NTSC and even less with hybrid NTSC but the times I have I wasn't worried about de-interlacing to 59.940fps. Combinations of 23.976 and 29.970 progressive were fine.
hello_hello is offline   Reply With Quote
Old 11th January 2017, 03:57   #9  |  Link
Katie Boundary
Registered User
 
Katie Boundary's Avatar
 
Join Date: Jan 2015
Posts: 1,070
Quote:
Originally Posted by hello_hello View Post
On your ignore list, off your ignore list......
You were never taken off it until Jan. 10,2017

Quote:
Originally Posted by hello_hello View Post
Still no apology??
I have nothing to apologize for.
__________________
I ask unusual questions but always give proper thanks to those who give correct and useful answers.
Katie Boundary is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 23:46.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.