Opened 14 years ago

Closed 14 years ago

Last modified 5 years ago

#9205 closed patch

QuickTimeDecoder: Scaling x and y separately

Reported by: SF/kreegee Owned by: SF/mthreepwood
Priority: normal Component: Video
Version: Keywords:
Cc: Game: Riven

Description

This patch allows two things:

a) scaling parameters in the transformation matrix with differ between x and y value

b) scaling parameters which aren't either 1, 2 or 4 (like its currently)

the only movie (in riven) which needs a), btw. also needs b)

Ticket imported from: #3057924. Ticket imported from: patches/1310.

Attachments (2)

qt_scaler.diff (4.9 KB ) - added by SF/kreegee 14 years ago.
qt_decoder.h and qt_decoder.cpp
qt_scaler_v2.diff (5.4 KB ) - added by SF/kreegee 14 years ago.
qt_decoder.h and qt_decoder.cpp, this time with Common::Rational

Download all attachments as: .zip

Change History (10)

by SF/kreegee, 14 years ago

Attachment: qt_scaler.diff added

qt_decoder.h and qt_decoder.cpp

comment:1 by SF/kreegee, 14 years ago

Summary: QuickTimeDecoder: Scaling x and y separatedQuickTimeDecoder: Scaling x and y separately

comment:2 by SF/mthreepwood, 14 years ago

Owner: set to SF/mthreepwood

comment:3 by SF/mthreepwood, 14 years ago

Thanks for submitting.

Took a quick look at this patch, and I see a pretty big problem with it: floating point. We try to avoid floating point at all costs. Since the values in the matrix are really fixed point and not floating point, this probably should be achieved with Common::Rational (see common/rational.h). Please rewrite the code to use this, if you are able to. Otherwise, it's looking good. :)

by SF/kreegee, 14 years ago

Attachment: qt_scaler_v2.diff added

qt_decoder.h and qt_decoder.cpp, this time with Common::Rational

comment:4 by SF/kreegee, 14 years ago

updated it to use common::rational

comment:5 by SF/mthreepwood, 14 years ago

I've tested the patch and while it no longer errors out, the image does not appear correctly. The bottom part of the image is corrupted. The x scale value is a normal 4, but the y scale value is 2.571451. Perhaps the patch just creates the scaled surface incorrectly?

comment:6 by SF/mthreepwood, 14 years ago

Applied in r52594 with some changes. Thanks to fuzzie for fixing the scaling in the whark button video (and others).

comment:7 by SF/mthreepwood, 14 years ago

Status: newclosed

comment:8 by digitall, 5 years ago

Component: Video
Game: Riven
Note: See TracTickets for help on using tickets.