Posts for creaothceann

creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Scepheo wrote:
So what happens if you were to hook it up to an LCD display?
The same what would happen if you run your LCD monitor not at its native resolution: depending on how it's configured, it either blurs the image over the entire area, or only a few lines are duplicated (like this (background) or this (text)).
Scepheo wrote:
You may consider "what you would see" to be the most authentic. But, considering no encode so far has used filters to make it look like it was being played on an actual television set, it appears that the main view is that the signal, as produced by the graphics card, is the most authentic. And this signal does not contain the scan lines.
On a TV there's always the NTSC standard which defines the maximum number of lines, so in the worst case parts of the recording can be upscaled to that height. Usually that's when interlaced and progressive are used in the same game, and the progressive parts can just be doubled vertically. The problem is that the PC allows very different vertical resolutions. All resolutions must be converted to a common one. (This was discussed here before.) Even DOSBox doesn't encode them into the same AVI file. You either have to apply some stretching or add black bars, and I think there is another, better alternative. If the following points apply: - the TAS is on the PC - the TAS includes [200 or 400 lines] AND [240 or 480 lines] graphics modes - the final encode will be a HD encode ...then the method posted above could be used.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Scepheo wrote:
I doubt sometimes having scan lines would improve the movie.
But that's what you see on a real CRT.
Scepheo wrote:
Also, if you're going for authenticity, how does the computer deal with it? I'm pretty sure it uses a stretching algorithm, so we should use it as well.
What computer - the emulated one? It doesn't stretch at all, it just writes to the graphic card's video memory. The graphic card generates a signal that contains the brightness information for each electron cannon (R, G & B), and the CRT distributes that evenly across the surface. The lines aren't stretched at all; they just have more or less space between them.
Scepheo wrote:
Scan lines occur due to limitations in the monitor, and don't have anything to do with the actual image displayed.
They increase the image height a bit. Without them the video would have to add black bars at the top and bottom. Just a bilinear stretching from 400 to 480 doesn't look that good, imo.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Slightly faster version:
function Add_PC_Scanlines(clip src, int LineCount, bool "spline")  {
        src
        o = PointResize(Width, Height * 6)
        BlankClip(o, 2).mt_lutspa(false, "y 6 % 0 == 255 0 ?")
        mt_merge(o, BlankClip(o), PointResize(Width, Height))
        y = LineCount
        x = y * 4 / 3
        return   default(spline, false)  ?\
                 BilinearResize(x, y)    :\
                 Spline64Resize(Width, y).Spline36Resize(x, y)
}
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Ilari wrote:
Note: Some games use different resolution in menus and in actual game. One should look what the resolution is in actual game.
Yeah, my bad. The menu was 320x200 while the game is 320x240. This also explains why some pixels in the video file seemed a bit off. So this filter doesn't have to be used for most of the run, but it might still be useful for the lower-res parts to make the video uniformly 4:3.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Aktan wrote:
Wait, how does just setting the aspect ratio flag to 4:3 not fix this?
A CRT screen has a certain look that I want to preserve/emulate. It leaves a bit of space between the drawn lines, so that the aspect ratio becomes 4:3. These "empty" lines are only 20% as high as a drawn line.
Aktan wrote:
After talking to Ilari on IRC, apparently the native resolution is 640x480. [...] There is no need to add scanlines!
Text mode is 640x400: 80x25 characters, each 8x16 pixels in size. Afaik the game runs in Mode 13h, which is 320x200. A video of the game recorded in DOSBox has that resolution.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Faster vesion, thanks to the guys at doom9.org:
DSS2("dwangoAC-WIP-Epic-Pinball-05.mkv")
Add_PC_Scanlines(960)                                           # only for 640x400


function Add_PC_Scanlines(clip src, int LineCount, bool "spline")  {
        src
        PointResize(Width, Height * 6)
        Mask = mt_lutspa(false, "y 6 % 0.01 < 0 255 ?")
        mt_lutxy(Mask, "x y * 255 /", U=2, V=2)
        y = LineCount
        x = y * 4 / 3
        return   default(spline, false)  ?  BilinearResize(x, y)  :  Spline64Resize(Width, y).Spline36Resize(x, y)
}
Needs the MaskTools plugin. Also instead of 600 MB RAM it takes much less now, though there may be a memory leak - not sure yet. EDIT: No leak, just the frame cache filling up - use SetMemoryMax to restrict it.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
To specify the correct aspect ratio. Both values will be reduced to the user's screen size anyway, unless the user has deactivated that option. (1200 is the number of encoded lines) You could also just define an aspect ratio and let the player figure out the correct width, but there was one converter (Youtube) that re-calculated the height instead when I uploaded such an MKV. :/
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Yes vote. :) (also good were Pinball Fantasies, Pinball Dreams, Pinball Illusions, Psycho Pinball)
Post subject: Re: Scanlines (maybe better than just stretching)
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
moozooh wrote:
creaothceann wrote:
EDIT: Converting a 320x200 RGB source to 320x1200 and encoding that with ZMBV could be the best solution. The user's gfx card could stretch that without speed penalty.
While I do think that scanlines are a nice alternative to the usual stretching algorithms used in media players (if only because they look closer to how it's actually supposed to be displayed), ZMBV is clearly an excessive measure. There is barely any speed penalty for hardware-accelerated stretching, and all popular systems and stand-alone devices can take advantage of this.
ZMBV was just mentioned for its potential of decreasing the file size. :)
moozooh wrote:
In any case, won't upscaling → adding scanlines → downscaling be a saner option?
Well, MKV (and maybe other containers) can specify a playback size of 1600x1200, which would be automatically reduced by sane players. It'd be the encoder's decision if s/he wants to offer these kinds of files.
Post subject: Scanlines (maybe better than just stretching)
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
In the "Epic Pinball" TAS, the blue android in the background seems to be not tall enough - the artist probably took the monitor's 4:3 screen area into account. The video is 640x400, but should be 640x480 with the correct aspect ratio. Unfortunately just adding 80 lines looks very unnatural. The correct way would be to add one blank scanline after 5 image lines, and scale the result back down to a resolution that the user's monitor can display.
DirectShowSource("dwangoAC-WIP-Epic-Pinball-05.mkv")    # YV12 640 x 400
ConvertToYUY2                                           # Crop can't do odd numbers in YV12
PointResize(Width, Height * 5).Scanlines                # add scanline after every 5 lines
#BilinearResize(1280, 960)                              # resize to final video size (optional)


function Scanlines(clip)  {
        clip
        top    = Crop(0, 0, 0, 5).AddBorders(0, 0, 0, 1)
        bottom = Crop(0, 5, 0, 0)
        bottom = (bottom.Height > 5)  ?  bottom.Scanlines  :  bottom.AddBorders(0, 0, 0, 1)
        StackVertical(top, bottom)
}
This is the AviSynth version; a custom plugin could be much more optimized. EDIT: Converting a 320x200 RGB source to 320x1200 and encoding that with ZMBV could be the best solution. The user's gfx card could stretch that without speed penalty.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Flygon wrote:
makes it impossible for me to upload the movie due to being stuck on 384kbits upload ADSL
Try 80. ;_; 3 hours for 100 MB, plus overhead.
Flygon wrote:
The reason (Well, I, anyway) encode at 60fps is because I lack the computational resources to make a blended 30fps movie
Encoding speed, or tools? And yeah, it depends on the game. Super Metroid = yes, Super Mario World = no.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Well, yeah.
Bisqwit wrote:
Which makes no difference for movie timing, but all the difference for the movie author when making the movie.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
The uploader is nice, but it still restricts to 15 minutes.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
You could create a RAM drive (eg. via ImDisk) and put all files on there, including CD image(s).
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
TAS (in the loosest sense) of Super Mario Odyssey MSU1
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
I'd say only allow frequency changes if they're possible from within the game. (Turrican II was one of those games. Original ran at 50 Hz with the Amiga monitor; on the PC the default was 60 Hz, iirc. Made the space shoot'em up sequences a bit harder.)
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Aktan wrote:
HQ Stream: http://www.zexsoft.com/aktan/?AglarAndHotarubisNesGimmickbestEndingIn0744.45/gimmick-tas-bestending-aglarhotarubi_512kb
This is one of the games that benefits from blending two frames into one, imo, like this: http://www.youtube.com/watch?v=E29hcV4PNbA AviSynth script for that movie:
AVISource("00.avi")                                             # recorded with fceux-2.1.4a
TimeStretch(rate = 100.0 * 60.0 / FrameRate)                    # adjust audio speed
AssumeFPS(60)                                                   # adjust video speed
Trim(221, 0)                                                    # trim frames recorded before TAS was loaded

Intro = Trim(    2,  4687)                                      # cut & splice parts into final movie
Title = Trim( 4789,  5193)
TAS   = Trim( 5860, 40366)
Intro + Title + TAS

ConvertToRGB32                                                  # a bit faster than RGB24
   PointResize(512, 448)                                        # double width & height
BilinearResize(640, 480)                                        # 4:3, size required for YT's HQ mode
ConvertToYV12                                                   # Overlay uses YUV internally, not RGB
BlendFields




function BlendFields(clip)  {
        clip
        (FrameCount % 2 == 1)  ?  DuplicateFrame(FrameCount - 1)  :  nop
        SelectEven.Overlay(SelectOdd, opacity=0.5)
}
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Is there a script to suppress the HUD line flickering in Super Metroid when you play it with SNES9x 1.43? I think this was already mentioned somewhere, but I can't find it...
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
YT links: part 1 part 2 credits
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
320x200, 640x400 etc. should be stretched to a 4:3 ratio, but that could be done by the player.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
mz wrote:
Besides those you've already posted, I think these would be the most interesting (in order of preference): 1. Ghost in the Shell
Seconded :) Some videos: http://www.youtube.com/watch?v=mdM_jCDhFS0 http://www.youtube.com/watch?v=UH5-OqBL7bg
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
http://www.romhacking.net/?page=utilities&category=13 has hex editors. Try WindHex32 or HxD.
creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
Noob Irdoh wrote:
If resolution is 256x224, you encode at 256x224. 512x448 is the same with bigger pixels
Streaming media uses the YV12 colorspace, which encodes color at a lower resolution. Doubling each dimension fixes that.
Noob Irdoh wrote:
I will create some WMV later.
Which is a proprietary format that cannot store media in arbitrary codecs. Even AVI is better than that.