mirror of
https://github.com/Armored-Dragon/overte.git
synced 2025-03-11 16:13:16 +01:00
Fix the linux build and correct the name of the property Intensity to Opacity
This commit is contained in:
parent
429d54d65d
commit
eec4e966a7
3 changed files with 14 additions and 12 deletions
|
@ -410,19 +410,19 @@ bool SelectionHighlightStyle::fromVariantMap(const QVariantMap& properties) {
|
|||
}
|
||||
}
|
||||
|
||||
auto intensityVariant = properties["outlineUnoccludedIntensity"];
|
||||
auto intensityVariant = properties["outlineUnoccludedOpacity"];
|
||||
if (intensityVariant.isValid()) {
|
||||
_style._outlineUnoccluded.alpha = intensityVariant.toFloat();
|
||||
}
|
||||
intensityVariant = properties["outlineOccludedIntensity"];
|
||||
intensityVariant = properties["outlineOccludedOpacity"];
|
||||
if (intensityVariant.isValid()) {
|
||||
_style._outlineOccluded.alpha = intensityVariant.toFloat();
|
||||
}
|
||||
intensityVariant = properties["fillUnoccludedIntensity"];
|
||||
intensityVariant = properties["fillUnoccludedOpacity"];
|
||||
if (intensityVariant.isValid()) {
|
||||
_style._fillUnoccluded.alpha = intensityVariant.toFloat();
|
||||
}
|
||||
intensityVariant = properties["fillOccludedIntensity"];
|
||||
intensityVariant = properties["fillOccludedOpacity"];
|
||||
if (intensityVariant.isValid()) {
|
||||
_style._fillOccluded.alpha = intensityVariant.toFloat();
|
||||
}
|
||||
|
@ -447,10 +447,10 @@ QVariantMap SelectionHighlightStyle::toVariantMap() const {
|
|||
properties["fillUnoccludedColor"] = xColorToVariant(xColorFromGlm(_style._fillUnoccluded.color));
|
||||
properties["fillOccludedColor"] = xColorToVariant(xColorFromGlm(_style._fillOccluded.color));
|
||||
|
||||
properties["outlineUnoccludedIntensity"] = _style._outlineUnoccluded.alpha;
|
||||
properties["outlineOccludedIntensity"] = _style._outlineOccluded.alpha;
|
||||
properties["fillUnoccludedIntensity"] = _style._fillUnoccluded.alpha;
|
||||
properties["fillOccludedIntensity"] = _style._fillOccluded.alpha;
|
||||
properties["outlineUnoccludedOpacity"] = _style._outlineUnoccluded.alpha;
|
||||
properties["outlineOccludedOpacity"] = _style._outlineOccluded.alpha;
|
||||
properties["fillUnoccludedOpacity"] = _style._fillUnoccluded.alpha;
|
||||
properties["fillOccludedOpacity"] = _style._fillOccluded.alpha;
|
||||
|
||||
properties["outlineWidth"] = _style._outlineWidth;
|
||||
properties["isOutlineSmooth"] = _style._isOutlineSmooth;
|
||||
|
|
|
@ -23,6 +23,8 @@ namespace render {
|
|||
struct RGBA {
|
||||
glm::vec3 color{ 1.f, 0.7f, 0.2f };
|
||||
float alpha{ 0.9f };
|
||||
|
||||
RGBA(const glm::vec3& c, float a) : color(c), alpha(a) {}
|
||||
};
|
||||
|
||||
RGBA _outlineUnoccluded{ { 1.f, 0.7f, 0.2f }, 0.9f };
|
||||
|
|
|
@ -64,10 +64,10 @@ Item {
|
|||
|
||||
Repeater {
|
||||
model: [
|
||||
"Outline Unoccluded:outlineUnoccludedColor:outlineUnoccludedIntensity",
|
||||
"Outline Occluded:outlineOccludedColor:outlineOccludedIntensity",
|
||||
"Fill Unoccluded:fillUnoccludedColor:fillUnoccludedIntensity",
|
||||
"Fill Occluded:fillOccludedColor:fillOccludedIntensity"]
|
||||
"Outline Unoccluded:outlineUnoccludedColor:outlineUnoccludedOpacity",
|
||||
"Outline Occluded:outlineOccludedColor:outlineOccludedOpacity",
|
||||
"Fill Unoccluded:fillUnoccludedColor:fillUnoccludedOpacity",
|
||||
"Fill Occluded:fillOccludedColor:fillOccludedOpacity"]
|
||||
Column {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
|
|
Loading…
Reference in a new issue