Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Q
qt3dstudio
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
public-demos
qt3dstudio
Commits
9786f3aa
Commit
9786f3aa
authored
Apr 25, 2018
by
Tomi Korpipää
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update kria cluster to 2.0 API
parent
8bdb8524
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
33 additions
and
57 deletions
+33
-57
kria-cluster-3d-demo/presentation/contentPresentation.uip
kria-cluster-3d-demo/presentation/contentPresentation.uip
+1
-1
kria-cluster-3d-demo/presentation/digitalSpeed.uip
kria-cluster-3d-demo/presentation/digitalSpeed.uip
+2
-2
kria-cluster-3d-demo/presentation/digitalTacho.uip
kria-cluster-3d-demo/presentation/digitalTacho.uip
+1
-1
kria-cluster-3d-demo/presentation/mainPresentation.uia
kria-cluster-3d-demo/presentation/mainPresentation.uia
+8
-7
kria-cluster-3d-demo/presentation/mainPresentation.uip
kria-cluster-3d-demo/presentation/mainPresentation.uip
+5
-5
kria-cluster-3d-demo/presentation/speedBackground.uip
kria-cluster-3d-demo/presentation/speedBackground.uip
+2
-2
kria-cluster-3d-demo/presentation/tachoBackground.uip
kria-cluster-3d-demo/presentation/tachoBackground.uip
+1
-1
kria-cluster-3d-demo/qml/OverlayContainer.qml
kria-cluster-3d-demo/qml/OverlayContainer.qml
+6
-6
kria-cluster-3d-demo/qml/SimuData.qml
kria-cluster-3d-demo/qml/SimuData.qml
+2
-2
kria-cluster-3d-demo/qml/main.qml
kria-cluster-3d-demo/qml/main.qml
+5
-30
No files found.
kria-cluster-3d-demo/presentation/contentPresentation.uip
View file @
9786f3aa
...
...
@@ -75,7 +75,7 @@
<Add
ref=
"#CarBottom"
diffuse=
"0.101961 0.101961 0.101961"
importfile=
".\Car\Car.import"
shaderlighting=
"None"
/>
<Add
ref=
"#Interior"
diffuse=
"0.0901961 0.0901961 0.0901961"
importfile=
".\Car\Car.import"
/>
<Add
ref=
"#body"
importfile=
".\Car\Car.import"
/>
<Add
ref=
"#lambert2"
bumpamount=
"1"
diffuse=
"0.870588 0 0"
fresnelPower=
"5"
importfile=
".\Car\Car.import"
normalmap=
"#lambert2_normalmap"
opacity=
"100"
specularamount=
"2"
specularmodel=
"Default"
specularroughness=
"0.001"
speculartint=
"0.298039 0.298039 0.298039"
/>
<Add
ref=
"#lambert2"
bumpamount=
"1"
controlledproperty=
"$displayColor diffuse"
diffuse=
"0.870588 0 0"
fresnelPower=
"5"
importfile=
".\Car\Car.import"
normalmap=
"#lambert2_normalmap"
opacity=
"100"
specularamount=
"2"
specularmodel=
"Default"
specularroughness=
"0.001"
speculartint=
"0.298039 0.298039 0.298039"
/>
<Add
ref=
"#lambert2_normalmap"
sourcepath=
".\Car\maps\outUV_normals.png"
/>
<Add
ref=
"#Wheel_Back_Left"
importfile=
".\Car\Car.import"
scale=
"90 38.141 38.141"
>
<AnimationTrack
property=
"rotation.x"
type=
"EaseInOut"
>
0 720 0 0 8 0 0 0
</AnimationTrack>
...
...
kria-cluster-3d-demo/presentation/digitalSpeed.uip
View file @
9786f3aa
...
...
@@ -18,8 +18,8 @@
<Add
ref=
"#Layer"
background=
"SolidColor"
/>
<Add
ref=
"#Camera"
orthographic=
"True"
/>
<State
id=
"Scene-Slide1"
name=
"Slide1"
>
<Add
ref=
"#speed"
name=
"speed"
font=
"TitilliumWeb-Regular"
position=
"0 40 0"
size=
"90"
textstring=
"0"
/>
<Add
ref=
"#kmh"
name=
"kmh"
font=
"TitilliumWeb-Regular"
position=
"0 -40 0"
size=
"30"
textstring=
"kph"
/>
<Add
ref=
"#speed"
name=
"speed"
controlledproperty=
"$speedText textstring"
font=
"TitilliumWeb-Regular"
position=
"0 40 0"
size=
"90"
textstring=
"0"
/>
<Add
ref=
"#kmh"
name=
"kmh"
controlledproperty=
"$speedUnitSlide textstring"
font=
"TitilliumWeb-Regular"
position=
"0 -40 0"
size=
"30"
textstring=
"kph"
/>
</State>
</State>
</Logic>
...
...
kria-cluster-3d-demo/presentation/digitalTacho.uip
View file @
9786f3aa
...
...
@@ -19,7 +19,7 @@
<Add
ref=
"#Camera"
orthographic=
"True"
/>
<State
id=
"Scene-Slide1"
name=
"Slide1"
>
<Add
ref=
"#rpm"
name=
"rpm"
font=
"TitilliumWeb-Regular"
position=
"0 -40 0"
rotation=
"0 0 0"
size=
"30"
textstring=
"rpm x 1000"
/>
<Add
ref=
"#tacho"
name=
"tacho"
font=
"TitilliumWeb-Regular"
opacity=
"99"
position=
"0 40 0"
size=
"90"
textstring=
"0.0"
/>
<Add
ref=
"#tacho"
name=
"tacho"
controlledproperty=
"$tachoText textstring"
font=
"TitilliumWeb-Regular"
opacity=
"99"
position=
"0 40 0"
size=
"90"
textstring=
"0.0"
/>
</State>
</State>
</Logic>
...
...
kria-cluster-3d-demo/presentation/mainPresentation.uia
View file @
9786f3aa
<?xml version="1.0" encoding="UTF-8" ?>
<application>
<assets
initial=
"mainPresentation"
>
<presentation
id=
"mainPresentation"
src=
"mainPresentation.uip"
/>
<presentation
id=
"contentPresentation"
src=
"contentPresentation.uip"
/>
<presentation
id=
"digitalSpeed"
src=
"digitalSpeed.uip"
/>
<presentation
id=
"digitalTacho"
src=
"digitalTacho.uip"
/>
<presentation
id=
"SpeedBackground"
src=
"speedBackground.uip"
/>
<presentation
id=
"TachoBackground"
src=
"tachoBackground.uip"
/>
<presentation-qml
id=
"navigationStream"
args=
"../qml/Navigation.qml"
/>
<dataInput
name=
"mainSlide"
type=
"String"
/>
<dataInput
name=
"carSlide"
type=
"String"
/>
<dataInput
name=
"colorSlide"
type=
"String"
/>
...
...
@@ -16,6 +9,14 @@
<dataInput
name=
"speed"
type=
"Ranged Number"
min=
"0"
max=
"260"
/>
<dataInput
name=
"speedText"
type=
"String"
/>
<dataInput
name=
"tachoText"
type=
"String"
/>
<dataInput
name=
"displayColor"
type=
"Vector3"
/>
<presentation
id=
"mainPresentation"
src=
"mainPresentation.uip"
/>
<presentation
id=
"contentPresentation"
src=
"contentPresentation.uip"
/>
<presentation
id=
"digitalSpeed"
src=
"digitalSpeed.uip"
/>
<presentation
id=
"digitalTacho"
src=
"digitalTacho.uip"
/>
<presentation
id=
"SpeedBackground"
src=
"speedBackground.uip"
/>
<presentation
id=
"TachoBackground"
src=
"tachoBackground.uip"
/>
<presentation-qml
id=
"navigationStream"
args=
"../qml/Navigation.qml"
/>
</assets>
<statemachine
ref=
"#logic"
>
<visual-states>
...
...
kria-cluster-3d-demo/presentation/mainPresentation.uip
View file @
9786f3aa
...
...
@@ -8,7 +8,7 @@
<Effect
id=
"VignetteEffect"
name=
"VignetteEffect"
sourcepath=
".\VignetteEffect.effect"
/>
</Classes>
<Graph
>
<Scene
id=
"Scene"
backgroundcolor=
"0 0 0"
controlledproperty=
"mainSlide @slide"
>
<Scene
id=
"Scene"
backgroundcolor=
"0 0 0"
controlledproperty=
"
$
mainSlide @slide"
>
<Layer
id=
"Layer"
>
<Camera
id=
"Camera"
/>
<Group
id=
"Gaugesvol2"
importid=
"__import__root__"
>
...
...
@@ -105,7 +105,7 @@
</Add>
<Add
ref=
"#tachomat"
bumpamount=
"1"
diffusemap=
"#tachomat_diffusemap"
emissivecolor=
"0 0 0"
fresnelPower=
"1"
importfile=
".\Gauges\Gauges.import"
shaderlighting=
"Pixel"
specularamount=
"0.2"
specularmodel=
"Default"
specularroughness=
"0.001"
speculartint=
"0.0627451 0.0627451 0.0627451"
/>
<Add
ref=
"#tachomat_diffusemap"
sourcepath=
"Gauges/maps/tacho_new.jpg"
subpresentation=
"TachoBackground"
/>
<Add
ref=
"#tachoNeedle"
name=
"tachoNeedle"
controlledproperty=
"tacho @timeline"
endtime=
"1000"
opacity=
"100"
position=
"0 1 0"
>
<Add
ref=
"#tachoNeedle"
name=
"tachoNeedle"
controlledproperty=
"
$
tacho @timeline"
endtime=
"1000"
opacity=
"100"
position=
"0 1 0"
>
<AnimationTrack
property=
"opacity"
type=
"EaseInOut"
>
0 100 0 0
</AnimationTrack>
</Add>
<Add
ref=
"#centerTacho"
endtime=
"1000"
importfile=
".\Gauges\Gauges.import"
position=
"0 1 -0"
rotation=
"0 -0 0"
sourcepath=
"GaugeCenter/meshes/centerTacho.mesh"
>
...
...
@@ -176,7 +176,7 @@
<AnimationTrack
property=
"scale.z"
type=
"EaseInOut"
>
0 1 0 0
</AnimationTrack>
</Add>
<Add
ref=
"#lambert8_001"
name=
"lambert8"
endtime=
"1000"
referencedmaterial=
"#lambert8"
/>
<Add
ref=
"#speedNeedle"
name=
"speedNeedle"
controlledproperty=
"speed @timeline"
endtime=
"1000"
opacity=
"100"
position=
"0 1 0"
scale=
"1 1 1"
>
<Add
ref=
"#speedNeedle"
name=
"speedNeedle"
controlledproperty=
"
$
speed @timeline"
endtime=
"1000"
opacity=
"100"
position=
"0 1 0"
scale=
"1 1 1"
>
<AnimationTrack
property=
"opacity"
type=
"EaseInOut"
>
0 100 0 0
</AnimationTrack>
<AnimationTrack
property=
"scale.x"
type=
"EaseInOut"
>
0 1 0 0
</AnimationTrack>
<AnimationTrack
property=
"scale.y"
type=
"EaseInOut"
>
0 1 0 0
</AnimationTrack>
...
...
@@ -201,12 +201,12 @@
<Add
ref=
"#Light_002"
name=
"Light"
brightness=
"250"
castshadow=
"True"
endtime=
"1000"
expfade=
"0"
lightambient=
"0.427451 0.427451 0.427451"
lightdiffuse=
"0.901961 0.901961 0.901961"
lightspecular=
"0.113725 0.109804 0.14902"
lighttype=
"Point"
linearfade=
"9.25926"
position=
"0 48 -110"
scale=
"4 1 1"
shdwbias=
"0.032"
shdwfactor=
"79.8333"
shdwfilter=
"4.66667"
shdwmapfar=
"1500"
shdwmapres=
"10"
/>
<Add
ref=
"#Map"
name=
"Content_Layer"
background=
"Transparent"
height=
"70"
left=
"15"
top=
"17"
width=
"72"
/>
<Add
ref=
"#Camera_002"
orthographic=
"True"
/>
<Add
ref=
"#Car"
name=
"Car"
controlledproperty=
"carSlide @slide"
/>
<Add
ref=
"#Car"
name=
"Car"
controlledproperty=
"
$
carSlide @slide"
/>
<Add
ref=
"#map"
name=
"Navigation"
opacity=
"100"
scale=
"25.9751 9.54456 1"
sourcepath=
"#Rectangle"
>
<AnimationTrack
property=
"opacity"
type=
"EaseInOut"
>
0 100 0 0
</AnimationTrack>
</Add>
<Add
ref=
"#Material_001"
diffusemap=
"#Material_001_diffusemap"
shaderlighting=
"None"
/>
<Add
ref=
"#Material_001_diffusemap"
sourcepath=
"
.\Gauges\maps\
map.jpg"
subpresentation=
"navigationStream"
/>
<Add
ref=
"#Material_001_diffusemap"
sourcepath=
"
Gauges/maps/
map.jpg"
subpresentation=
"navigationStream"
/>
<Add
ref=
"#VignetteEffect_001"
name=
"VignetteEffect"
vig_color=
"0 0 0"
vig_radius=
"1.01626"
vig_strenght=
"15"
/>
<State
id=
"Scene-2D"
name=
"2D"
playmode=
"Play Through To..."
>
<Set
ref=
"#Layer"
endtime=
"1000"
/>
...
...
kria-cluster-3d-demo/presentation/speedBackground.uip
View file @
9786f3aa
...
...
@@ -9,7 +9,7 @@
<ImageBuffer
sourcepath=
"Gauges/maps/gaugespeed_mph.png"
hasTransparency=
"True"
/>
</BufferData>
<Graph
>
<Scene
id=
"Scene"
controlledproperty=
"speedUnitSlide @slide"
>
<Scene
id=
"Scene"
controlledproperty=
"
$
speedUnitSlide @slide"
>
<Layer
id=
"Layer"
>
<Camera
id=
"Camera"
/>
<Model
id=
"speed_mph_new"
>
...
...
@@ -46,7 +46,7 @@
</Add>
<Add
ref=
"#Material_001"
diffusemap=
"#Material_001_diffusemap"
shaderlighting=
"None"
/>
<Add
ref=
"#Material_001_diffusemap"
sourcepath=
"Gauges/maps/gaugespeed_kph.png"
/>
<Add
ref=
"#gaugespeed_background"
name=
"gaugespeed_background"
controlledproperty=
"colorSlide @slide"
/>
<Add
ref=
"#gaugespeed_background"
name=
"gaugespeed_background"
controlledproperty=
"
$
colorSlide @slide"
/>
<State
id=
"Scene-kph"
name=
"kph"
playmode=
"Stop at end"
>
<Set
ref=
"#Layer"
endtime=
"1000"
/>
<Set
ref=
"#Camera"
endtime=
"1000"
/>
...
...
kria-cluster-3d-demo/presentation/tachoBackground.uip
View file @
9786f3aa
...
...
@@ -35,7 +35,7 @@
</Add>
<Add
ref=
"#Material"
diffusemap=
"#Material_diffusemap"
shaderlighting=
"None"
/>
<Add
ref=
"#Material_diffusemap"
sourcepath=
"Gauges/maps/gaugetacho.png"
/>
<Add
ref=
"#gaugespeed_background"
name=
"gaugetacho_background"
controlledproperty=
"colorSlide @slide"
/>
<Add
ref=
"#gaugespeed_background"
name=
"gaugetacho_background"
controlledproperty=
"
$
colorSlide @slide"
/>
<State
id=
"Scene-Tacho"
name=
"Tacho"
playmode=
"Stop at end"
>
<Set
ref=
"#Layer"
endtime=
"1000"
/>
<Set
ref=
"#Camera"
endtime=
"1000"
/>
...
...
kria-cluster-3d-demo/qml/OverlayContainer.qml
View file @
9786f3aa
...
...
@@ -54,12 +54,12 @@ OverlayContainerForm {
id
:
indicatorContainer
// Safety critical icons
property
bool
parkBrake
:
startupAnimation
?
true
:
false
property
bool
flatTire
:
startupAnimation
?
true
:
false
property
bool
fuelLevel
:
startupAnimation
?
true
:
false
property
bool
seatbelt
:
startupAnimation
?
true
:
false
property
bool
oilLevel
:
startupAnimation
?
true
:
false
property
bool
brakeFailure
:
startupAnimation
?
true
:
false
property
bool
parkBrake
:
mainview
.
startupAnimation
?
true
:
false
property
bool
flatTire
:
mainview
.
startupAnimation
?
true
:
false
property
bool
fuelLevel
:
mainview
.
startupAnimation
?
true
:
false
property
bool
seatbelt
:
mainview
.
startupAnimation
?
true
:
false
property
bool
oilLevel
:
mainview
.
startupAnimation
?
true
:
false
property
bool
brakeFailure
:
mainview
.
startupAnimation
?
true
:
false
// Icon colors
property
string
offIconColor
:
"
#222324
"
...
...
kria-cluster-3d-demo/qml/SimuData.qml
View file @
9786f3aa
...
...
@@ -62,7 +62,7 @@ Item {
SequentialAnimation
{
id
:
animation
running
:
!
startupAnimation
running
:
!
mainview
.
startupAnimation
loops
:
Animation
.
Infinite
PropertyAnimation
{
...
...
@@ -85,7 +85,7 @@ Item {
}
Timer
{
running
:
!
startupAnimation
running
:
!
mainview
.
startupAnimation
property
bool
turnLeft
:
true
repeat
:
true
interval
:
5000
...
...
kria-cluster-3d-demo/qml/main.qml
View file @
9786f3aa
...
...
@@ -110,42 +110,38 @@ Item {
}
DataInput
{
id
:
tachometerNeedle
name
:
"
tacho
"
value
:
simuData
.
rpm
}
DataInput
{
id
:
tachometerText
name
:
"
tachoText
"
value
:
(
simuData
.
rpm
/
1000.0
).
toFixed
(
1
)
}
DataInput
{
id
:
speedometerNeedle
name
:
"
speed
"
value
:
simuData
.
speed
}
DataInput
{
id
:
speedometerText
name
:
"
speedText
"
value
:
useMetric
?
simuData
.
speed
.
toFixed
(
0
)
:
(
simuData
.
speed
/
1.625
).
toFixed
(
0
)
}
DataInput
{
id
:
displayColor
name
:
"
colorSlide
"
value
:
redTheme
?
"
red
"
:
"
blue
"
}
DataInput
{
id
:
speedometerUnit
name
:
"
speedUnitSlide
"
value
:
useMetric
?
"
kph
"
:
"
mph
"
}
Elemen
t
{
id
:
carBodyMaterial
elementPath
:
"
contentPresentation:Scene.Layer.Car.Car.body.lambert2
"
DataInpu
t
{
name
:
"
displayColor
"
value
:
redTheme
?
Qt
.
vector3d
(
0.855
,
0.14
,
0.144
)
:
Qt
.
vector3d
(
0.08
,
0.08
,
1.0
)
}
SubPresentationSettings
{
...
...
@@ -194,27 +190,6 @@ Item {
visible
:
false
}
onRedThemeChanged
:
{
if
(
redTheme
)
{
carBodyMaterial
.
setAttribute
(
"
diffuse.r
"
,
0.855
);
carBodyMaterial
.
setAttribute
(
"
diffuse.g
"
,
0.14
);
carBodyMaterial
.
setAttribute
(
"
diffuse.b
"
,
0.144
);
displayColor
.
setValue
(
"
red
"
);
}
else
{
carBodyMaterial
.
setAttribute
(
"
diffuse.r
"
,
0.08
);
carBodyMaterial
.
setAttribute
(
"
diffuse.g
"
,
0.08
);
carBodyMaterial
.
setAttribute
(
"
diffuse.b
"
,
1.0
);
displayColor
.
setValue
(
"
blue
"
);
}
}
onUseMetricChanged
:
{
if
(
useMetric
)
speedometerUnit
.
setValue
(
"
kph
"
);
else
speedometerUnit
.
setValue
(
"
mph
"
);
}
Keys.onRightPressed
:
{
userActivity
();
menuSelect
(
true
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment