diff --git a/src-tauri/Cargo.lock b/src-tauri/Cargo.lock index 6f7297a135..b0fe5f514b 100644 --- a/src-tauri/Cargo.lock +++ b/src-tauri/Cargo.lock @@ -1913,12 +1913,6 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" -[[package]] -name = "minisign-verify" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "933dca44d65cdd53b355d0b73d380a2ff5da71f87f036053188bf1eab6a19881" - [[package]] name = "miniz_oxide" version = "0.6.2" @@ -3745,7 +3739,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9bfe673cf125ef364d6f56b15e8ce7537d9ca7e4dae1cf6fbbdeed2e024db3d9" dependencies = [ "anyhow", - "base64 0.21.2", "bytes", "cocoa", "dirs-next", @@ -3759,7 +3752,6 @@ dependencies = [ "heck 0.4.1", "http", "ignore", - "minisign-verify", "objc", "once_cell", "open", @@ -3784,14 +3776,12 @@ dependencies = [ "tauri-utils", "tempfile", "thiserror", - "time", "tokio", "url", "uuid", "webkit2gtk", "webview2-com", "windows 0.39.0", - "zip", ] [[package]] @@ -5012,14 +5002,3 @@ checksum = "56c1936c4cc7a1c9ab21a1ebb602eb942ba868cbd44a99cb7cdc5892335e1c85" dependencies = [ "linked-hash-map", ] - -[[package]] -name = "zip" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "760394e246e4c28189f19d488c058bf16f564016aefac5d32bb1f3b51d5e9261" -dependencies = [ - "byteorder", - "crc32fast", - "crossbeam-utils", -] diff --git a/src/hooks/useSetupEngineManager.ts b/src/hooks/useSetupEngineManager.ts index 3ac33b1511..3cd38c937c 100644 --- a/src/hooks/useSetupEngineManager.ts +++ b/src/hooks/useSetupEngineManager.ts @@ -82,9 +82,14 @@ export function useSetupEngineManager( } function getDimensions(streamWidth?: number, streamHeight?: number) { + const maxResolution = 2000 const width = streamWidth ? streamWidth : 0 - const quadWidth = Math.round(width / 4) * 4 const height = streamHeight ? streamHeight : 0 - const quadHeight = Math.round(height / 4) * 4 + const ratio = Math.min( + Math.min(maxResolution / width, maxResolution / height), + 1.0 + ) + const quadWidth = Math.round((width * ratio) / 4) * 4 + const quadHeight = Math.round((height * ratio) / 4) * 4 return { width: quadWidth, height: quadHeight } } diff --git a/src/lang/std/engineConnection.ts b/src/lang/std/engineConnection.ts index d37bc301e4..50422dfe35 100644 --- a/src/lang/std/engineConnection.ts +++ b/src/lang/std/engineConnection.ts @@ -633,7 +633,10 @@ export class EngineCommandManager { // If we already have an engine connection, just need to resize the stream. if (this.engineConnection) { - this.handleResize({ streamWidth: width, streamHeight: height }) + this.handleResize({ + streamWidth: width, + streamHeight: height, + }) return }