Refactored frames
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import QtQuick 2.0
|
||||
import QtQuick 2.1
|
||||
|
||||
Item{
|
||||
property real ambient_light: 0.2
|
||||
|
||||
19
qml/cool-old-term/frames/BlackRoughFrame.qml
Normal file
19
qml/cool-old-term/frames/BlackRoughFrame.qml
Normal file
@@ -0,0 +1,19 @@
|
||||
import QtQuick 2.1
|
||||
import "utils"
|
||||
|
||||
TerminalFrame{
|
||||
id: frame
|
||||
z: 2.1
|
||||
anchors.fill: parent
|
||||
addedWidth: 200
|
||||
addedHeight: 370
|
||||
borderLeft: 148
|
||||
borderRight: 148
|
||||
borderTop: 232
|
||||
borderBottom: 232
|
||||
imageSource: "../images/black-frame.png"
|
||||
normalsSource: "../images/black-frame-normals.png"
|
||||
sourceRect: Qt.rect(-80, -90, terminal.width + 160, terminal.height + 180 )
|
||||
|
||||
shaderString: "WhiteFrameShader.qml"
|
||||
}
|
||||
19
qml/cool-old-term/frames/WhiteSimpleFrame.qml
Normal file
19
qml/cool-old-term/frames/WhiteSimpleFrame.qml
Normal file
@@ -0,0 +1,19 @@
|
||||
import QtQuick 2.0
|
||||
import "utils"
|
||||
|
||||
TerminalFrame{
|
||||
id: frame
|
||||
z: 2.1
|
||||
anchors.fill: parent
|
||||
addedWidth: 140
|
||||
addedHeight: 140
|
||||
borderLeft: 116
|
||||
borderRight: 116
|
||||
borderTop: 116
|
||||
borderBottom: 116
|
||||
imageSource: "../images/screen-frame.png"
|
||||
normalsSource: "../images/screen-frame-normals.png"
|
||||
sourceRect: Qt.rect(-65, -75, terminal.width + 130, terminal.height + 150)
|
||||
|
||||
shaderString: "WhiteFrameShader.qml"
|
||||
}
|
||||
BIN
qml/cool-old-term/frames/images/black-frame-normals.png
Normal file
BIN
qml/cool-old-term/frames/images/black-frame-normals.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.4 MiB |
BIN
qml/cool-old-term/frames/images/black-frame.png
Normal file
BIN
qml/cool-old-term/frames/images/black-frame.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.1 MiB |
BIN
qml/cool-old-term/frames/images/screen-frame-normals.png
Normal file
BIN
qml/cool-old-term/frames/images/screen-frame-normals.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 646 KiB |
BIN
qml/cool-old-term/frames/images/screen-frame.png
Normal file
BIN
qml/cool-old-term/frames/images/screen-frame.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 571 KiB |
@@ -180,7 +180,7 @@ ApplicationWindow{
|
||||
//vec4 color = texture2D(source, coords);
|
||||
float color = (blurredColor(source, coords).r + texture2D(source, coords).r) * 0.5;
|
||||
float scanline_alpha = getScanlineIntensity(coords) * scanlines;
|
||||
//float inside = step(0.0, coords.x) * step(-1.0, -coords.x) * step(0.0, coords.y) * step(-1.0, -coords.y);
|
||||
//float inside = step(0.0, coords.x) * step(-1.0, -coords.x) * step(0.0, coords.y) * step(-1.0, -coords.y);
|
||||
float noise = stepNoise(coords) * noise_strength;
|
||||
float randomPass = randomPass(coords) * glowing_line_strength;
|
||||
color += noise + randomPass;
|
||||
@@ -190,38 +190,14 @@ ApplicationWindow{
|
||||
}"
|
||||
}
|
||||
|
||||
// TerminalFrame{
|
||||
// id: frame
|
||||
// z: 2.1
|
||||
// anchors.fill: parent
|
||||
// addedWidth: 140
|
||||
// addedHeight: 140
|
||||
// borderLeft: 116
|
||||
// borderRight: 116
|
||||
// borderTop: 116
|
||||
// borderBottom: 116
|
||||
// imageSource: "../images/screen-frame.png"
|
||||
// normalsSource: "../images/screen-frame-normals.png"
|
||||
// sourceRect: Qt.rect(-65, -75, terminal.width + 130, terminal.height + 150)
|
||||
Loader{
|
||||
property rect sourceRect
|
||||
|
||||
// shaderString: "WhiteFrameShader.qml"
|
||||
// }
|
||||
|
||||
TerminalFrame{
|
||||
id: frame
|
||||
z: 2.1
|
||||
anchors.fill: parent
|
||||
addedWidth: 200
|
||||
addedHeight: 370
|
||||
borderLeft: 148
|
||||
borderRight: 148
|
||||
borderTop: 232
|
||||
borderBottom: 232
|
||||
imageSource: "../images/black-frame.png"
|
||||
normalsSource: "../images/black-frame-normals.png"
|
||||
sourceRect: Qt.rect(-80, -90, terminal.width + 160, terminal.height + 180 )
|
||||
|
||||
shaderString: "WhiteFrameShader.qml"
|
||||
z: 2.1
|
||||
source: "./frames/WhiteSimpleFrame.qml"
|
||||
onLoaded: sourceRect = item.sourceRect;
|
||||
}
|
||||
|
||||
TerminalScreen {
|
||||
|
||||
Reference in New Issue
Block a user