aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author浅倉麗子2020-04-05 12:57:55 -0400
committer浅倉麗子2020-04-05 12:57:55 -0400
commit80c7ce0e417dc4a5d5e023ac79ba06cf2f1538ca (patch)
tree0c23fd70f7b325786b0296fa0949cf17ba079163
parentInitial commit (diff)
downloadsharpscale-80c7ce0e417dc4a5d5e023ac79ba06cf2f1538ca.tar.gz
Globally disable Iftu bilinear filtering
-rw-r--r--main.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/main.c b/main.c
index 5738d2e..c16e116 100644
--- a/main.c
+++ b/main.c
@@ -72,7 +72,7 @@ static SceUID hook_export(int idx, char *mod, int libnid, int funcnid, void *fun
#define HOOK_EXPORT(idx, mod, libnid, funcnid, func)\
hook_export(idx, mod, libnid, funcnid, func##_hook)
-static int sceIftuSetInputFrameBuffer_hook(int plane, SceIftuPlaneState *state, int mask, int mode) {
+static int sceIftuSetInputFrameBuffer_hook(int plane, SceIftuPlaneState *state, int bilinear, int sync_mode) {
if (state->src_w == 0xC000 && state->src_h == 0xC16D) {
state->src_w = state->src_h = 0x10000;
state->dst_x = (1280 - 960) / 2;
@@ -80,7 +80,10 @@ static int sceIftuSetInputFrameBuffer_hook(int plane, SceIftuPlaneState *state,
} else if (state->src_w == 0x8000 && state->src_h == 0x80F3) {
state->src_h = state->src_w;
}
- return TAI_CONTINUE(int, hook_ref[0], plane, state, mask, mode);
+
+ bilinear = (bilinear == 1) ? 0 : bilinear;
+
+ return TAI_CONTINUE(int, hook_ref[0], plane, state, bilinear, sync_mode);
}
static int sceDisplaySetScaleConf_hook(float scale, int head, int index, int mode) {