1
0
mirror of https://github.com/Swordfish90/cool-retro-term.git synced 2025-01-18 12:15:27 +00:00

Fix input redirection

This commit is contained in:
Filippo Scognamiglio 2014-06-07 11:33:37 +02:00
parent bd0938610f
commit 25ed5db324
2 changed files with 13 additions and 2 deletions

View File

@ -30,6 +30,8 @@ Item{
property variant bloomSource: bloomSourceLoader.item
property variant scanlineSource: scanlineSourceLoader.item
property alias kterminal: kterminal
//The blur effect has to take into account the framerate
property real fpsAttenuation: 60 / shadersettings.fps
property real mBlur: shadersettings.motion_blur
@ -161,10 +163,19 @@ Item{
}
}
function correctDistortion(x, y){
//Frame displacement properties
property real dtop: frame.item.displacementTop
property real dleft:frame.item.displacementLeft
property real dright: frame.item.displacementRight
property real dbottom: frame.item.displacementBottom
function correctDistortion(x, y){
x = x / width;
y = y / height;
x = (-dleft + x * (width + dleft + dright)) / width
y = (-dtop + y * (height + dtop + dbottom)) / height
var cc = Qt.size(0.5 - x, 0.5 - y);
var distortion = (cc.height * cc.height + cc.width * cc.width) * shadersettings.screen_distortion;

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE QtCreatorProject>
<!-- Written by QtCreator 3.0.1, 2014-06-07T01:48:03. -->
<!-- Written by QtCreator 3.0.1, 2014-06-07T10:59:29. -->
<qtcreator>
<data>
<variable>ProjectExplorer.Project.ActiveTarget</variable>