Some useful information I can share here.

SNES games known to use hi-res mode

Note: If the movie was done with Snes9x and you are dumping for encoding, enable Audio/Video Recording -> Simple2X Resize for AVI (for HiRes).
Possibly more out there?

PCSX-rr Cropping Automater for AviSynth

##################################
### PCSX-rr Cropping Automater ###
##################################
# Script based on NDS Layout Automater for AviSynth by Zinfidel
# and adapted by despoa

#################
### Importing ###
#################
# In the importing script, the following variables must be defined before importing:
# vid  (clip)
#   The video dump.
# resX (int)
#   Final output width.
# resY (int)
#   Final output height.
#
# NOTE: The imported video is assumed to have all its screen changes have their
# upper-left corners at coordinates (0,0) (i.e. at the top-left corner of the video).

#############
### Usage ###
#############
# The key function is ScreenChange, abbreviated to sch. This function crops
# a trimmed section from the original video while the rest of the video can be
# cropped differently by calling it again with different crop settings.
# This function automatically appends to other calls of itself and takes three
# integer parameters: the frame number where the cropping starts, the horizontal
# resolution of the crop, and the vertical resolution of the crop.
#
# The function starts with the full video being set to the last variable,
# and then is chained with other calls of the same function to create the video.
# For example:
#
# vid = AviSource("example.avi")
# resX = 640
# resY = 480
# Import("PCSXsplitting.avsi")
# last = vid
# sch(0, 640, 480)
# sch(620, 256, 240).sch(3000, 320, 240)
#
# This would create an output video that has part of the video cropped to 640x480
# and resized starting at frame 0, then has it cropped to 256x240 and resized at
# frame 620, then has it cropped to 320x240 and resized at frame 3000.
# It does not matter if there is a line break or a dot between calls, they are
# functionally equivalent in AviSynth.
#
# NOTE: The cropping parameters must not exceed the resolution of the original video.

#############
### Setup ###
#############
global screenWidth = resX
global screenHeight = resY
global original = vid

function ScreenChange(clip clips, int Xcrop, int Ycrop, int trimStart, int trimEnd) {
	return clips.Trim(trimStart, trimEnd).Crop(0, 0, Xcrop, Ycrop).PointResize(screenWidth, screenHeight)
}

function sch(clip prev, int startFrame, int Xcrop, int Ycrop) {
	ret = ScreenChange(original, Xcrop, Ycrop, startFrame, 0)
	return startFrame == 0 ? ret : prev.Trim(0, startFrame - 1) + ret
}

Nintendo 3DS Layout Automater for AviSynth

####################################
### Nintendo 3DS Layout Automater ###
####################################
# Based on layouts by Spikestuff
# Adapted from Zinfidel's Nintendo 3DS Layout Automater
# Modified by despoa

#################
### Importing ###
#################
# In the importing script, the following variables must be defined before importing:
# vid  (clip)
#   The video dump.
# resX (int)
#   Final output width.
# resY (int)
#   Final output height.
# botFocus (bool)
#   Sets the final aspect ratio and resolution depending on whether or not the encode is going to
#   use gt (Gameplay (Top)). If it does, set this to false. If not, set to true.
#	TODO: Figure out how to automate this so that this is instead set by the first presence of gt.
#
# The unequal sizes of the two 3DS screens means that the final output resolution will depend on whether
# or not the encode will have the focus on top screen at any point. This is set by botFocus.
#
# - If focus is at the top:
# -- 4K    : 3840x1646 (scaled from 1120x480)
# - If focus is at the bottom:
# -- 4K    : 3840x1772 (scaled from 1040x480)
#
# Note that the final output vertical resolution will be increased by vertGap*scaleFactor if it is greater than 0.

#############
### Usage ###
#############
# There are 5 shortcut functions defined to change the layout. They are: gt, gb, st, sb, and tb, which are
# Gameplay (Top), Gameplay (Bottom), Single (Top), Single (Bottom), and Top and Bottom, respectively.
# These functions automatically append to the video that they build, and each takes an integer as its
# first argument: the frame number on which to change the layout.
#
# These functions start with the full video being set to the last variable, and then the functions are chained to
# create the video. For example:
#
# vid = AviSource("example.avi")
# resX = 1120
# resY = 480
# botFocus = false
# Import("3dslayout.avsi")
# last = vid
# st(0)
# tb(1000)
# gt(2000).gb(3000)
# sb(4000)
#
# This would create an output video that starts in Single (Top), changes to Top and Bottom at frame 1000,
# changes to Gameplay (Top) on frame 2000, then changes to Gameplay (Bottom) on frame 3000. On frame 4000,
# the layout is changed to Single (Bottom). It does not matter if there is a line break or a dot
# between calls, they are functionally equivalent in AviSynth.

#############
### Setup ###
#############
global top = vid.crop(0, 0, -0, -240)
global bot = vid.crop(40, 240, -40, -0)

global finalWidth = resX
global finalHeight = resY
global bottomFocus = botFocus

#############################
### Pure Layout Functions ###
#############################
function GameplayTop(clip t, clip b, int trimStart, int trimEnd) {
	t = t.Trim(trimStart, trimEnd).PointResize(t.width*2, t.height*2)
	b = b.Trim(trimStart, trimEnd).AddBorders(0, b.height, 0, 0)
	return StackHorizontal(t, b).PointResize(finalWidth, finalHeight)
}

function GameplayBottom(clip t, clip b, int trimStart, int trimEnd) {
	t = t.Trim(trimStart, trimEnd).AddBorders(0, 0, 0, t.height)
	b = b.Trim(trimStart, trimEnd).PointResize(b.width*2, b.height*2)
	borders = bottomFocus ? 0 : 40
	return StackHorizontal(b, t).AddBorders(borders, 0, borders, 0).PointResize(finalWidth, finalHeight)
}

function SingleTop(clip t, clip b, int trimStart, int trimEnd) {
	ret = t.Trim(trimStart, trimEnd).PointResize(t.width*2, t.height*2)
	borders = bottomFocus ? 120 : 160
	return ret.AddBorders(borders, 0, borders, 0).PointResize(finalWidth, finalHeight)
}

function SingleBottom(clip t, clip b, int trimStart, int trimEnd) {
	ret = b.Trim(trimStart, trimEnd).PointResize(b.width*2, b.height*2)
	borders = bottomFocus ? 200 : 240
	return ret.AddBorders(borders, 0, borders, 0).PointResize(finalWidth, finalHeight)
}

# TODO: Figure out how to automate gaps and account for borders.
function TopAndBottom(clip t, clip b, int trimStart, int trimEnd) {
	t = t.Trim(trimStart, trimEnd)
	b = b.Trim(trimStart, trimEnd).AddBorders(40, 0, 40, 0)
	borders = bottomFocus ? 320 : 360
	return StackVertical(t, b).AddBorders(borders, 0, borders, 0).PointResize(finalWidth, finalHeight)
}

#######################################
### Auto-Appending Layout Shortcuts ###
#######################################
function AutoAppend(clip prev, int startFrame, string func) {
	ret = Eval(func + "(top, bot, startFrame, 0)")
	return startFrame == 0 ? ret : prev.Trim(0, startFrame - 1) + ret
}

function gt(clip prev, int startFrame) { return AutoAppend(prev, startFrame, "GameplayTop") }
function gb(clip prev, int startFrame) { return AutoAppend(prev, startFrame, "GameplayBottom") }
function st(clip prev, int startFrame) { return AutoAppend(prev, startFrame, "SingleTop") }
function sb(clip prev, int startFrame) { return AutoAppend(prev, startFrame, "SingleBottom") }
function tb(clip prev, int startFrame) { return AutoAppend(prev, startFrame, "TopAndBottom") }
Below are links to pages that aren't as useful, but should serve as some source of amusement.
Expand/Collapse collapse-content-_479725639d5c40ada6ecbd941db0532e

HomePages/despoa last edited by despoa on 7/25/2025 11:12 AM
Page History Latest diff List referrers View Source