Skip to content

Commit

Permalink
Events of overlapping pictures get merged #76
Browse files Browse the repository at this point in the history
  • Loading branch information
JockeJarre committed Mar 20, 2024
1 parent 6f13aef commit fedb1b0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
5 changes: 3 additions & 2 deletions b2sbackglassserver/b2sbackglassserver/Forms/formBackglass.vb
Original file line number Diff line number Diff line change
Expand Up @@ -773,6 +773,7 @@ Public Class formBackglass

' get top node
Dim topnode As Xml.XmlElement = XML.SelectSingleNode("DirectB2SData")
Dim mergeBulbs As Boolean = topnode.SelectSingleNode("MergeBulbs") IsNot Nothing AndAlso topnode.SelectSingleNode("MergeBulbs").Attributes("Value").InnerText <> "0"

' clear all data
B2SData.ClearAll(True)
Expand Down Expand Up @@ -1492,7 +1493,7 @@ Public Class formBackglass
End If

' maybe draw some light images for pretty fast image changing
If top4Authentic >= minSize4Image Then
If top4Authentic >= minSize4Image And mergeBulbs Then
' create some light images
If TopLightImage4Authentic Is Nothing Then
TopLightImage4Authentic = CreateLightImage(DarkImage4Authentic, B2SData.eDualMode.Authentic, topkey4Authentic, , TopRomID4Authentic, TopRomIDType4Authentic, TopRomInverted4Authentic)
Expand All @@ -1505,7 +1506,7 @@ Public Class formBackglass
TopAndSecondLightImage4Authentic = CreateLightImage(TopLightImage4Authentic, B2SData.eDualMode.Authentic, topkey4Authentic)
End If
End If
If B2SData.DualBackglass AndAlso top4Fantasy >= minSize4Image Then
If B2SData.DualBackglass AndAlso top4Fantasy >= minSize4Image And mergeBulbs Then
' create some light images
If TopLightImage4Fantasy Is Nothing Then
TopLightImage4Fantasy = CreateLightImage(DarkImage4Fantasy, B2SData.eDualMode.Fantasy, topkey4Fantasy, , TopRomID4Fantasy, TopRomIDType4Fantasy, TopRomInverted4Fantasy)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1799,6 +1799,7 @@ Public Class formBackglass

' get top node
Dim topnode As Xml.XmlElement = XML.SelectSingleNode("DirectB2SData")
Dim mergeBulbs As Boolean = topnode.SelectSingleNode("MergeBulbs") IsNot Nothing AndAlso topnode.SelectSingleNode("MergeBulbs").Attributes("Value").InnerText <> "0"

' clear all data
B2SData.ClearAll(True)
Expand Down Expand Up @@ -2552,7 +2553,7 @@ Public Class formBackglass
End If

' maybe draw some light images for pretty fast image changing
If top4Authentic >= minSize4Image Then
If top4Authentic >= minSize4Image And mergeBulbs Then
' create some light images
If TopLightImage4Authentic Is Nothing Then
TopLightImage4Authentic = CreateLightImage(DarkImage4Authentic, B2SData.eDualMode.Authentic, topkey4Authentic, , TopRomID4Authentic, TopRomIDType4Authentic, TopRomInverted4Authentic)
Expand All @@ -2565,7 +2566,7 @@ Public Class formBackglass
TopAndSecondLightImage4Authentic = CreateLightImage(TopLightImage4Authentic, B2SData.eDualMode.Authentic, topkey4Authentic)
End If
End If
If B2SData.DualBackglass AndAlso top4Fantasy >= minSize4Image Then
If B2SData.DualBackglass AndAlso top4Fantasy >= minSize4Image And mergeBulbs Then
' create some light images
If TopLightImage4Fantasy Is Nothing Then
TopLightImage4Fantasy = CreateLightImage(DarkImage4Fantasy, B2SData.eDualMode.Fantasy, topkey4Fantasy, , TopRomID4Fantasy, TopRomIDType4Fantasy, TopRomInverted4Fantasy)
Expand Down

0 comments on commit fedb1b0

Please sign in to comment.