Kare Kano DVDs
One day, I’ve stumbled upon Kare Kano anime, but after searching for rips for a while, I did not find a single DVDRip I would consider acceptable.
So I thought: heeey, maybe I should rip the DVD myself?
God, how wrong I was.
In this post I’m going to write about the shit I found while working with Kare Kano DVDs.
I’m writing this post not to be informative, but for myself to be done with this DVD. Forever.
Disclaimer: for all intents and purposes the reader can assume that the author of this post is a crazy uninformed lunatic.
Getting the DVDs
It turns out, there are several different releases of Kare Kano. At some point, I’ve had four different sets of DVDs downloaded: R1, R2J, Spanish, and homemade Russian.
The Spanish one turned out to be a PAL DVD, and anime is not supposed to be 25 or 50 fps.
Homemade russian release turned out to be R1 release without english streams and with additional russian subtitles and sound streams.
Now, downloading the R2J release turned out to be somehow problematic. At the time I tried to do it, in 2010, there were no seeds in any of Kare Kano R2J torrents. I could not even find it on some closed trackers.
When I finally found the torrent I’ve been looking for so long, there was only one seeder on that torrent. The download speed varied from 5 to 19 kilobytes per second. And he was not even online all the time.
When I put his IP into maxmind geoIP tool, it spewed out:
Russia, SibirTelecom, <some-small-and-distant-city>
So I’ve been downloading 45 gigabytes of Kare Kano in the course of 3 months from some guy in deep Siberia.
How do I DVDRIP?
After reading some guides on Doom9 forums and avisynth manuals, I decided to look for anime ripping communities. I found #raw-providers IRC channel on Rizon, and told them I want to rip Kare Kano.
To paraphrase modestly, they strongly dismissed the idea of ripping that DVD.
That’s a DVDRip. There are BDs that are worse than that. That release is probably the strongest argument in favor of anime upscales.
And he told me to drop the idea of ripping Kare Kano.
We might want to know how the DVD we have was made.
Anime used to be produced using cels, which were shot on 24 fps film. Kare Kano was produced this way.
A screenshot from video of Gainax burning Kare Kano cels; episode 19, ending
Then we got the
Telecine is the process of transferring motion picture film into video and is performed in a color suite.
But there is a problem: film has 24 fps, and DVD supports only 25 or 29.97 fps video, interlaced or progressive.
Wait? Not exactly 30 fps? 30000/1001 fps? What sorcery is this? We’ll look into that later.
Okay, so how does one fit 24 fps video into a 30-ish fps video?
If we look at given framerates, we’ll see that 24/30 = 4/5, so if we somehow convert 4 frames of given 24 fps video to 5 frames, we’ll get 30 fps.
It is possible with 2:3 pulldown.
2:3 pulldown, explained by a picture from Wikipedia
Pulldown is producing interlaced video meaning there will be “combs”.
I would describe the 2:3 pulldown algorithm in python pseudocode:
from itertools import cycle alternating = cycle([Even, Odd]) # alternate between even and odd output fields pattern = cycle([2, 3]) # the name comes from this field pattern for frame in input: for _ in range(next(pattern)): # output N fields yield first.field(next(alternating)) # output the corresponding field
And to get 30-ish fps, we also need to slow down the playback by a factor of 1000/1001 at some point.
The 2:3 pulldown pattern can be observed in first frames of Kare Kano:
kare kano, episode 01, first seconds; picture is anamorhpic
TFM is matching the fields, and TDecimate is throwing away unmatched and doubled frames.
Let’s see how it works:
mpeg2source("vts_01_1.d2v") tfm(pp=1) // don't interpolate unmatched frames tdecimate() trim(2518,2525) // avs2yuv ivtc.avs -o - | ffmpeg -r 3 -i - -c:v vp9 -b:v 0 -crf 18 whats-ivtc.webm
kare kano, episode 01, first seconds, IVTC; picture is anamorphic
That looks promising!
However, my hope of easy Kare Kano rip died really fast.
Gainax-style digital video effects circa 1998
For some reason, Gainax decided that adding 60-ish fps interlaced video effects to the telecined video is a good idea.
Miyazawa laughing at Gainax digital video processing; episode 01; picture is anamorphic
In the video clip above you can see that “ふ” hieroglyphs are always interlaced. It is a purely interlaced 60-ish fps effect. The “fufufu” was added in a digital way, after telecine.
This means several extremely unpleasant things.
- some parts of the video MUST be motion-interpolated and to produce constant framerate video
- some parts of the video MUST be field-interpolated to produce progressive video
- detecting digitally edited parts has to be done manually
But wait, there is more!
Temporal Scanline Blending
The term in this headline is stolen from a handy guide Analysing Your DVD Footage.
a picture of Miyazawa partially blending with the door; episode 05; picture is anamorphic
Hm, what’s that? Let’s inspect individual fields.
individual fields, upscaled to double size using nnedi; episode 05; picture is anamorphic
What we see here is film frames changing in the middle of the output field. The next field after that is slightly blended too.
I tried to fix this issue using various de-blending plugins and writing a plugin on my own, but I failed to reverse this problem. Partially, because there is an inevitable information loss involved: after fields are blended in the analog world, the pixels are quantized in 8 bit (probably?) and then lossily encoded with MPEG2. So even if I know perfect blending parameters and frame change timing, MPEG2 is introducing a lossy step, and trying to de-blend will cause artifacts from both frames to surface. The quantization step adds some problem to de-blending too.
I’ve inspected at all individual frames in the first episode and wrote down blending parameters for all required frames. Of course, there was a lot of automation involved. However, I was not happy with the final de-blending result.
Pretty early into this process I discovered why this happens. The blending pattern repeats approximately every 1000 frames. The line of the blending frames moves “up” across the whole field in a course of ~500 frames.
My hypothesis on the cause of this artifact is that during telecine process, film has been displayed at 24.00 frames per second to a telecine machine that took 59.94 fields per second, and sometimes frames were changing during the field scan. The difference in scanning speed of 1000/1001 causes the line of blending to move along the field.
Since editing was partially done in the digital world, each digital “cut” caused blend pattern to “reset”, which invalidated the simple formula for blend position.
Quoting the “Analysing Your DVD Footage” guide on how bad it is:
This is the nastiest of the nasty Telecine methods and can be seen in every Gainax production from Otaku no Video to Kare Kano and in many more late 80s to late 90s anime. It’s the reason Eva Renewal had to be made. […]
This stuff is nigh impossible to recover at the moment. There are no tools available at our level which can deal with field blending like this […]
It’s nasty stuff - especially in pans where you can end up with an IVTC process giving you a scene with horizontal motion with the top half moving in one frame and the bottom half catching it up in the next frame. Evil.
That article too has a similar explanation for how it happens.
Film editing with scissors and office tape
Kare Kano was partially edited in film and partially in the digital world.
The first one is visible as a jagged film edge sometimes getting on the screen.
The second one sometimes appears as video cut in between frame fields.
a film edge visible on the screen; episode 02, picture is upscaled from one field with nnedi
I kind of like the first artifact because it adds vintage analog feel to the video, however it is still a video artifact.
These artifacts are minor, but I decided to include them anyway.
This artifact is caused by interference between luma signal and chroma signal,
I see dots crawling in your eyes, Miyazawa; episode 01, 300% zoom with nearest point interpolation
You can observe the checkerboard pattern on the edge of colorful regions. There are avisynth plugins to deal with this, and you have to tune the “knobs” to do it right.
The process of producing Kare Kano DVDs is a disaster.
Almost every step after film is a terrible information loss.
Artifacts are clearly visible and cannot be reversed.
Several artifacts are caused by NTSC color implementation and non-integral framerate.
- film is edited with visible cuts and gluing.
- telecine is done with incorrect framerate, causing field blends and converting video to interlaced.
this step is the worst of all. Literally Hitler.
- the video is then transported using composite video signal, causing dot crawl.
- video is edited digitally, adding pure interlaced 60-ish fps effects.
- video is lossily encoded using MPEG2 and packed into DVD.
I am not going to work with Kare Kano DVDs in my life again.
Fuck. That. Shit.
If you happen to know where to get Kare Kano film/negatives, please drop an email to firstname.lastname@example.org. I am willing to scan and compile them myself.
And a comics, just for lulz:
if you ever thought I have drawing skills, you might be disappointed