diff options
author | HimbeerserverDE <himbeerserverde@gmail.com> | 2023-06-08 19:10:50 +0200 |
---|---|---|
committer | HimbeerserverDE <himbeerserverde@gmail.com> | 2023-06-08 19:10:50 +0200 |
commit | cfe8019ce136e8a3df9777f71e05731ff75511a8 (patch) | |
tree | badaeaf647c4fbb5aa1f9ef3fdbc4bfe5816d5dc | |
parent | 8d324c858557608d29e17f14e75de26e7781226f (diff) |
support dynamic exposure correction in ToCltLighting
-rw-r--r-- | serialize.go | 196 | ||||
-rw-r--r-- | tocltcmds.go | 10 |
2 files changed, 196 insertions, 10 deletions
diff --git a/serialize.go b/serialize.go index 18aa18f..5d5640a 100644 --- a/serialize.go +++ b/serialize.go @@ -18582,35 +18582,215 @@ func (obj *ToCltFormspecPrepend) deserialize(r io.Reader) { func (obj *ToCltLighting) serialize(w io.Writer) { { x := (*(*(struct { - ShadowIntensity float32 - Saturation float32 + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 }))(obj)).ShadowIntensity write32(w, math.Float32bits(x)) } { x := (*(*(struct { - ShadowIntensity float32 - Saturation float32 + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 }))(obj)).Saturation write32(w, math.Float32bits(x)) } + { + x := (*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).LuminanceMin + write32(w, math.Float32bits(x)) + } + { + x := (*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).LuminanceMax + write32(w, math.Float32bits(x)) + } + { + x := (*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).ExposureCorrection + write32(w, math.Float32bits(x)) + } + { + x := (*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).SpeedDarkBright + write32(w, math.Float32bits(x)) + } + { + x := (*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).SpeedBrightDark + write32(w, math.Float32bits(x)) + } + { + x := (*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).CenterWeightPower + write32(w, math.Float32bits(x)) + } } func (obj *ToCltLighting) deserialize(r io.Reader) { { p := &(*(*(struct { - ShadowIntensity float32 - Saturation float32 + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 }))(obj)).ShadowIntensity *p = math.Float32frombits(read32(r)) } { p := &(*(*(struct { - ShadowIntensity float32 - Saturation float32 + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 }))(obj)).Saturation *p = math.Float32frombits(read32(r)) } + { + p := &(*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).LuminanceMin + *p = math.Float32frombits(read32(r)) + } + { + p := &(*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).LuminanceMax + *p = math.Float32frombits(read32(r)) + } + { + p := &(*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).ExposureCorrection + *p = math.Float32frombits(read32(r)) + } + { + p := &(*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).SpeedDarkBright + *p = math.Float32frombits(read32(r)) + } + { + p := &(*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).SpeedBrightDark + *p = math.Float32frombits(read32(r)) + } + { + p := &(*(*(struct { + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 + }))(obj)).CenterWeightPower + *p = math.Float32frombits(read32(r)) + } } func (obj *AOCmdProps) serialize(w io.Writer) { diff --git a/tocltcmds.go b/tocltcmds.go index b3dfe5a..56974e1 100644 --- a/tocltcmds.go +++ b/tocltcmds.go @@ -827,8 +827,14 @@ func (cmd *ToCltMinimapModes) deserialize(r io.Reader) { // ToCltLighting tells the client the shadow intensity of the local player. type ToCltLighting struct { - ShadowIntensity float32 - Saturation float32 + ShadowIntensity float32 + Saturation float32 + LuminanceMin float32 + LuminanceMax float32 + ExposureCorrection float32 + SpeedDarkBright float32 + SpeedBrightDark float32 + CenterWeightPower float32 } type ToCltDisco struct{} |