wip
This commit is contained in:
Generated
+29
-363
@@ -39,7 +39,7 @@ dependencies = [
|
|||||||
"proc-macro2",
|
"proc-macro2",
|
||||||
"quote",
|
"quote",
|
||||||
"regex",
|
"regex",
|
||||||
"rustc-hash",
|
"rustc-hash 1.1.0",
|
||||||
"shlex",
|
"shlex",
|
||||||
"syn 1.0.109",
|
"syn 1.0.109",
|
||||||
"which",
|
"which",
|
||||||
@@ -47,9 +47,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "bindgen"
|
name = "bindgen"
|
||||||
version = "0.70.1"
|
version = "0.72.1"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "f49d8fed880d473ea71efb9bf597651e77201bdd4893efe54c9e5d65ae04ce6f"
|
checksum = "993776b509cfb49c750f11b8f07a46fa23e0a1386ffc01fb1e7d343efc387895"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bitflags 2.10.0",
|
"bitflags 2.10.0",
|
||||||
"cexpr",
|
"cexpr",
|
||||||
@@ -58,7 +58,7 @@ dependencies = [
|
|||||||
"proc-macro2",
|
"proc-macro2",
|
||||||
"quote",
|
"quote",
|
||||||
"regex",
|
"regex",
|
||||||
"rustc-hash",
|
"rustc-hash 2.1.1",
|
||||||
"shlex",
|
"shlex",
|
||||||
"syn 2.0.108",
|
"syn 2.0.108",
|
||||||
]
|
]
|
||||||
@@ -134,17 +134,6 @@ dependencies = [
|
|||||||
"cfg-if",
|
"cfg-if",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "displaydoc"
|
|
||||||
version = "0.2.5"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0"
|
|
||||||
dependencies = [
|
|
||||||
"proc-macro2",
|
|
||||||
"quote",
|
|
||||||
"syn 2.0.108",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "dump"
|
name = "dump"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
@@ -170,9 +159,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "ffmpeg-next"
|
name = "ffmpeg-next"
|
||||||
version = "7.1.0"
|
version = "8.0.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "da02698288e0275e442a47fc12ca26d50daf0d48b15398ba5906f20ac2e2a9f9"
|
checksum = "d658424d233cbd993a972dd73a66ca733acd12a494c68995c9ac32ae1fe65b40"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bitflags 2.10.0",
|
"bitflags 2.10.0",
|
||||||
"ffmpeg-sys-next",
|
"ffmpeg-sys-next",
|
||||||
@@ -181,11 +170,11 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "ffmpeg-sys-next"
|
name = "ffmpeg-sys-next"
|
||||||
version = "7.1.3"
|
version = "8.0.1"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "f9e9c75ebd4463de9d8998fb134ba26347fe5faee62fabf0a4b4d41bd500b4ad"
|
checksum = "9bca20aa4ee774fe384c2490096c122b0b23cf524a9910add0686691003d797b"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"bindgen 0.70.1",
|
"bindgen 0.72.1",
|
||||||
"cc",
|
"cc",
|
||||||
"libc",
|
"libc",
|
||||||
"num_cpus",
|
"num_cpus",
|
||||||
@@ -210,22 +199,13 @@ dependencies = [
|
|||||||
"miniz_oxide",
|
"miniz_oxide",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "form_urlencoded"
|
|
||||||
version = "1.2.2"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf"
|
|
||||||
dependencies = [
|
|
||||||
"percent-encoding",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "genvideo"
|
name = "genvideo"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"retro-rs",
|
"ffmpeg-next",
|
||||||
|
"retro-rs 0.5.4",
|
||||||
"rply-codec",
|
"rply-codec",
|
||||||
"video-rs",
|
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@@ -261,108 +241,6 @@ dependencies = [
|
|||||||
"windows-sys 0.61.2",
|
"windows-sys 0.61.2",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "icu_collections"
|
|
||||||
version = "2.1.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "4c6b649701667bbe825c3b7e6388cb521c23d88644678e83c0c4d0a621a34b43"
|
|
||||||
dependencies = [
|
|
||||||
"displaydoc",
|
|
||||||
"potential_utf",
|
|
||||||
"yoke",
|
|
||||||
"zerofrom",
|
|
||||||
"zerovec",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "icu_locale_core"
|
|
||||||
version = "2.1.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "edba7861004dd3714265b4db54a3c390e880ab658fec5f7db895fae2046b5bb6"
|
|
||||||
dependencies = [
|
|
||||||
"displaydoc",
|
|
||||||
"litemap",
|
|
||||||
"tinystr",
|
|
||||||
"writeable",
|
|
||||||
"zerovec",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "icu_normalizer"
|
|
||||||
version = "2.1.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "5f6c8828b67bf8908d82127b2054ea1b4427ff0230ee9141c54251934ab1b599"
|
|
||||||
dependencies = [
|
|
||||||
"icu_collections",
|
|
||||||
"icu_normalizer_data",
|
|
||||||
"icu_properties",
|
|
||||||
"icu_provider",
|
|
||||||
"smallvec",
|
|
||||||
"zerovec",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "icu_normalizer_data"
|
|
||||||
version = "2.1.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "7aedcccd01fc5fe81e6b489c15b247b8b0690feb23304303a9e560f37efc560a"
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "icu_properties"
|
|
||||||
version = "2.1.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "e93fcd3157766c0c8da2f8cff6ce651a31f0810eaa1c51ec363ef790bbb5fb99"
|
|
||||||
dependencies = [
|
|
||||||
"icu_collections",
|
|
||||||
"icu_locale_core",
|
|
||||||
"icu_properties_data",
|
|
||||||
"icu_provider",
|
|
||||||
"zerotrie",
|
|
||||||
"zerovec",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "icu_properties_data"
|
|
||||||
version = "2.1.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "02845b3647bb045f1100ecd6480ff52f34c35f82d9880e029d329c21d1054899"
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "icu_provider"
|
|
||||||
version = "2.1.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "85962cf0ce02e1e0a629cc34e7ca3e373ce20dda4c4d7294bbd0bf1fdb59e614"
|
|
||||||
dependencies = [
|
|
||||||
"displaydoc",
|
|
||||||
"icu_locale_core",
|
|
||||||
"writeable",
|
|
||||||
"yoke",
|
|
||||||
"zerofrom",
|
|
||||||
"zerotrie",
|
|
||||||
"zerovec",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "idna"
|
|
||||||
version = "1.1.0"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de"
|
|
||||||
dependencies = [
|
|
||||||
"idna_adapter",
|
|
||||||
"smallvec",
|
|
||||||
"utf8_iter",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "idna_adapter"
|
|
||||||
version = "1.2.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "3acae9609540aa318d1bc588455225fb2085b9ed0c4f6bd0d9d5bcd86f1a0344"
|
|
||||||
dependencies = [
|
|
||||||
"icu_normalizer",
|
|
||||||
"icu_properties",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "itertools"
|
name = "itertools"
|
||||||
version = "0.13.0"
|
version = "0.13.0"
|
||||||
@@ -425,12 +303,6 @@ version = "0.4.15"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab"
|
checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "litemap"
|
|
||||||
version = "0.8.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "6373607a59f0be73a39b6fe456b8192fcc3585f602af20751600e974dd455e77"
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "log"
|
name = "log"
|
||||||
version = "0.4.28"
|
version = "0.4.28"
|
||||||
@@ -512,33 +384,12 @@ version = "0.1.2"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099"
|
checksum = "19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "percent-encoding"
|
|
||||||
version = "2.3.2"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220"
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "pin-project-lite"
|
|
||||||
version = "0.2.16"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b"
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "pkg-config"
|
name = "pkg-config"
|
||||||
version = "0.3.32"
|
version = "0.3.32"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c"
|
checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "potential_utf"
|
|
||||||
version = "0.1.4"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "b73949432f5e2a09657003c25bca5e19a0e9c84f8058ca374f49e0ebe605af77"
|
|
||||||
dependencies = [
|
|
||||||
"zerovec",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "proc-macro2"
|
name = "proc-macro2"
|
||||||
version = "1.0.103"
|
version = "1.0.103"
|
||||||
@@ -601,9 +452,18 @@ checksum = "7a2d987857b319362043e95f5353c0535c1f58eec5336fdfcf626430af7def58"
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "retro-rs"
|
name = "retro-rs"
|
||||||
version = "0.5.2"
|
version = "0.5.3"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "656d99fcb289714d4b7e294187c09fa8d0563414b8b3f1dca2f5d258bd221441"
|
checksum = "cb116c907a72a722faf31bc45293bd4748a85109807ae5334001c7c74e188be2"
|
||||||
|
dependencies = [
|
||||||
|
"libc",
|
||||||
|
"libloading",
|
||||||
|
"rust-libretro-sys",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "retro-rs"
|
||||||
|
version = "0.5.4"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"libc",
|
"libc",
|
||||||
"libloading",
|
"libloading",
|
||||||
@@ -664,6 +524,12 @@ version = "1.1.0"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2"
|
checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "rustc-hash"
|
||||||
|
version = "2.1.1"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "rustix"
|
name = "rustix"
|
||||||
version = "0.38.44"
|
version = "0.38.44"
|
||||||
@@ -677,36 +543,6 @@ dependencies = [
|
|||||||
"windows-sys 0.59.0",
|
"windows-sys 0.59.0",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "serde"
|
|
||||||
version = "1.0.228"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e"
|
|
||||||
dependencies = [
|
|
||||||
"serde_core",
|
|
||||||
"serde_derive",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "serde_core"
|
|
||||||
version = "1.0.228"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad"
|
|
||||||
dependencies = [
|
|
||||||
"serde_derive",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "serde_derive"
|
|
||||||
version = "1.0.228"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79"
|
|
||||||
dependencies = [
|
|
||||||
"proc-macro2",
|
|
||||||
"quote",
|
|
||||||
"syn 2.0.108",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "shlex"
|
name = "shlex"
|
||||||
version = "1.3.0"
|
version = "1.3.0"
|
||||||
@@ -725,12 +561,6 @@ version = "1.15.1"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "67b1b7a3b5fe4f1376887184045fcf45c69e92af734b7aaddc05fb777b6fbd03"
|
checksum = "67b1b7a3b5fe4f1376887184045fcf45c69e92af734b7aaddc05fb777b6fbd03"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "stable_deref_trait"
|
|
||||||
version = "1.2.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596"
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "syn"
|
name = "syn"
|
||||||
version = "1.0.109"
|
version = "1.0.109"
|
||||||
@@ -753,17 +583,6 @@ dependencies = [
|
|||||||
"unicode-ident",
|
"unicode-ident",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "synstructure"
|
|
||||||
version = "0.13.2"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2"
|
|
||||||
dependencies = [
|
|
||||||
"proc-macro2",
|
|
||||||
"quote",
|
|
||||||
"syn 2.0.108",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "thiserror"
|
name = "thiserror"
|
||||||
version = "2.0.17"
|
version = "2.0.17"
|
||||||
@@ -784,47 +603,6 @@ dependencies = [
|
|||||||
"syn 2.0.108",
|
"syn 2.0.108",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "tinystr"
|
|
||||||
version = "0.8.2"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "42d3e9c45c09de15d06dd8acf5f4e0e399e85927b7f00711024eb7ae10fa4869"
|
|
||||||
dependencies = [
|
|
||||||
"displaydoc",
|
|
||||||
"zerovec",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "tracing"
|
|
||||||
version = "0.1.41"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "784e0ac535deb450455cbfa28a6f0df145ea1bb7ae51b821cf5e7927fdcfbdd0"
|
|
||||||
dependencies = [
|
|
||||||
"pin-project-lite",
|
|
||||||
"tracing-attributes",
|
|
||||||
"tracing-core",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "tracing-attributes"
|
|
||||||
version = "0.1.30"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "81383ab64e72a7a8b8e13130c49e3dab29def6d0c7d76a03087b3cf71c5c6903"
|
|
||||||
dependencies = [
|
|
||||||
"proc-macro2",
|
|
||||||
"quote",
|
|
||||||
"syn 2.0.108",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "tracing-core"
|
|
||||||
version = "0.1.34"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "b9d12581f227e93f094d3af2ae690a574abb8a2b9b7a96e7cfe9647b2b617678"
|
|
||||||
dependencies = [
|
|
||||||
"once_cell",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "unicode-ident"
|
name = "unicode-ident"
|
||||||
version = "1.0.22"
|
version = "1.0.22"
|
||||||
@@ -835,45 +613,16 @@ checksum = "9312f7c4f6ff9069b165498234ce8be658059c6728633667c526e27dc2cf1df5"
|
|||||||
name = "upgradev0"
|
name = "upgradev0"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"retro-rs",
|
"retro-rs 0.5.3",
|
||||||
"rply-codec",
|
"rply-codec",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "url"
|
|
||||||
version = "2.5.7"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "08bc136a29a3d1758e07a9cca267be308aeebf5cfd5a10f3f67ab2097683ef5b"
|
|
||||||
dependencies = [
|
|
||||||
"form_urlencoded",
|
|
||||||
"idna",
|
|
||||||
"percent-encoding",
|
|
||||||
"serde",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "utf8_iter"
|
|
||||||
version = "1.0.4"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be"
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "vcpkg"
|
name = "vcpkg"
|
||||||
version = "0.2.15"
|
version = "0.2.15"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426"
|
checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "video-rs"
|
|
||||||
version = "0.10.5"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "859aad7261bac267f90f9635ec9addba3b4bcb4bbb2edb03fec3e6b765657bee"
|
|
||||||
dependencies = [
|
|
||||||
"ffmpeg-next",
|
|
||||||
"tracing",
|
|
||||||
"url",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "wasip2"
|
name = "wasip2"
|
||||||
version = "1.0.1+wasi-0.2.4"
|
version = "1.0.1+wasi-0.2.4"
|
||||||
@@ -989,95 +738,12 @@ version = "0.46.0"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "f17a85883d4e6d00e8a97c586de764dabcc06133f7f1d55dce5cdc070ad7fe59"
|
checksum = "f17a85883d4e6d00e8a97c586de764dabcc06133f7f1d55dce5cdc070ad7fe59"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "writeable"
|
|
||||||
version = "0.6.2"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "9edde0db4769d2dc68579893f2306b26c6ecfbe0ef499b013d731b7b9247e0b9"
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "xxhash-rust"
|
name = "xxhash-rust"
|
||||||
version = "0.8.15"
|
version = "0.8.15"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "fdd20c5420375476fbd4394763288da7eb0cc0b8c11deed431a91562af7335d3"
|
checksum = "fdd20c5420375476fbd4394763288da7eb0cc0b8c11deed431a91562af7335d3"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "yoke"
|
|
||||||
version = "0.8.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "72d6e5c6afb84d73944e5cedb052c4680d5657337201555f9f2a16b7406d4954"
|
|
||||||
dependencies = [
|
|
||||||
"stable_deref_trait",
|
|
||||||
"yoke-derive",
|
|
||||||
"zerofrom",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "yoke-derive"
|
|
||||||
version = "0.8.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "b659052874eb698efe5b9e8cf382204678a0086ebf46982b79d6ca3182927e5d"
|
|
||||||
dependencies = [
|
|
||||||
"proc-macro2",
|
|
||||||
"quote",
|
|
||||||
"syn 2.0.108",
|
|
||||||
"synstructure",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "zerofrom"
|
|
||||||
version = "0.1.6"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "50cc42e0333e05660c3587f3bf9d0478688e15d870fab3346451ce7f8c9fbea5"
|
|
||||||
dependencies = [
|
|
||||||
"zerofrom-derive",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "zerofrom-derive"
|
|
||||||
version = "0.1.6"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "d71e5d6e06ab090c67b5e44993ec16b72dcbaabc526db883a360057678b48502"
|
|
||||||
dependencies = [
|
|
||||||
"proc-macro2",
|
|
||||||
"quote",
|
|
||||||
"syn 2.0.108",
|
|
||||||
"synstructure",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "zerotrie"
|
|
||||||
version = "0.2.3"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "2a59c17a5562d507e4b54960e8569ebee33bee890c70aa3fe7b97e85a9fd7851"
|
|
||||||
dependencies = [
|
|
||||||
"displaydoc",
|
|
||||||
"yoke",
|
|
||||||
"zerofrom",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "zerovec"
|
|
||||||
version = "0.11.5"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "6c28719294829477f525be0186d13efa9a3c602f7ec202ca9e353d310fb9a002"
|
|
||||||
dependencies = [
|
|
||||||
"yoke",
|
|
||||||
"zerofrom",
|
|
||||||
"zerovec-derive",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "zerovec-derive"
|
|
||||||
version = "0.11.2"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "eadce39539ca5cb3985590102671f2567e659fca9666581ad3411d59207951f3"
|
|
||||||
dependencies = [
|
|
||||||
"proc-macro2",
|
|
||||||
"quote",
|
|
||||||
"syn 2.0.108",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "zlib-rs"
|
name = "zlib-rs"
|
||||||
version = "0.5.2"
|
version = "0.5.2"
|
||||||
|
|||||||
+2
-2
@@ -5,5 +5,5 @@ edition = "2024"
|
|||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
rply-codec = { path = "../codec" }
|
rply-codec = { path = "../codec" }
|
||||||
retro-rs = { version = "0.5.2", default-features=false }
|
retro-rs = { version = "0.5.4", default-features=false, path = "../../retro-rs" }
|
||||||
video-rs = "0.10.5"
|
ffmpeg-next = "8.0.0"
|
||||||
+212
-1
@@ -1 +1,212 @@
|
|||||||
fn main() {}
|
use ffmpeg_next::{
|
||||||
|
codec::Debug,
|
||||||
|
util::frame::{Audio as FFAFrame, Video as FFVFrame},
|
||||||
|
};
|
||||||
|
use retro_rs::Emulator;
|
||||||
|
use rply_codec::{Frame, decode};
|
||||||
|
use std::path::Path;
|
||||||
|
|
||||||
|
fn copy_audio(samples: &[i16], frame: &mut FFAFrame) {
|
||||||
|
println!(
|
||||||
|
"Copy {} samples into {}",
|
||||||
|
samples.len() / 2,
|
||||||
|
frame.samples()
|
||||||
|
);
|
||||||
|
for (i, pair) in samples.chunks_exact(2).enumerate() {
|
||||||
|
let [l, r] = pair else {
|
||||||
|
unreachable!();
|
||||||
|
};
|
||||||
|
frame.plane_mut(0)[i] = f32::from(*l) / 65535.0;
|
||||||
|
frame.plane_mut(1)[i] = f32::from(*r) / 65535.0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fn copy_video(fb: &[u8], frame: &mut FFVFrame) {
|
||||||
|
let w = i32::try_from(frame.width()).unwrap();
|
||||||
|
let h = i32::try_from(frame.height()).unwrap();
|
||||||
|
let fmt: ffmpeg_next::ffi::AVPixelFormat = frame.format().into();
|
||||||
|
unsafe {
|
||||||
|
let frame_ptr = frame.as_mut_ptr();
|
||||||
|
let ret = ffmpeg_next::ffi::av_image_fill_arrays(
|
||||||
|
(*frame_ptr).data.as_mut_ptr(),
|
||||||
|
(*frame_ptr).linesize.as_mut_ptr(),
|
||||||
|
fb.as_ptr(),
|
||||||
|
fmt,
|
||||||
|
w,
|
||||||
|
h,
|
||||||
|
1,
|
||||||
|
);
|
||||||
|
assert!(ret > 0, "av_image_fill_arrays returned {ret}");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
ffmpeg_next::init().unwrap();
|
||||||
|
ffmpeg_next::log::set_level(ffmpeg_next::log::Level::Trace);
|
||||||
|
let args: Vec<_> = std::env::args().collect();
|
||||||
|
let file =
|
||||||
|
std::fs::File::open(args.get(1).unwrap_or(&"examples/bobl.replay".to_string())).unwrap();
|
||||||
|
let outfile = std::path::PathBuf::from(args.get(2).unwrap_or(&"examples/bobl.mp4".to_string()));
|
||||||
|
let corefile = args
|
||||||
|
.get(3)
|
||||||
|
.unwrap_or(&"cores/fceumm_libretro".to_string())
|
||||||
|
.clone();
|
||||||
|
let romfile = args.get(4).unwrap_or(&"roms/bobl.nes".to_string()).clone();
|
||||||
|
let mut emu = Emulator::create(Path::new(&corefile), Path::new(&romfile));
|
||||||
|
let file = std::io::BufReader::new(file);
|
||||||
|
let mut rply = decode(file).unwrap();
|
||||||
|
let header = &rply.header;
|
||||||
|
println!("Header in: {header:?}");
|
||||||
|
if header.version() == 0 {
|
||||||
|
println!("Only use this program for v1+ replays!");
|
||||||
|
std::process::exit(-1);
|
||||||
|
}
|
||||||
|
// run emu a tick to make sure we have right frame sizes, etc
|
||||||
|
emu.run([retro_rs::Buttons::default(); 2]);
|
||||||
|
|
||||||
|
let (w, h) = emu.framebuffer_size();
|
||||||
|
|
||||||
|
let mut output = ffmpeg_next::format::output(&outfile).unwrap();
|
||||||
|
let emu_time_base = ffmpeg_next::util::rational::Rational::new(1, emu.get_video_fps() as i32);
|
||||||
|
let out_video_codec = ffmpeg_next::encoder::find(ffmpeg_next::codec::Id::H264).unwrap();
|
||||||
|
let mut out_video_ctx = ffmpeg_next::codec::context::Context::new_with_codec(out_video_codec);
|
||||||
|
let mut video_params = ffmpeg_next::codec::Parameters::new();
|
||||||
|
unsafe {
|
||||||
|
let vps = video_params.as_mut_ptr();
|
||||||
|
(*vps).width = i32::try_from(w).unwrap();
|
||||||
|
(*vps).height = i32::try_from(h).unwrap();
|
||||||
|
(*vps).codec_id = out_video_codec.id().into();
|
||||||
|
(*vps).framerate = ffmpeg_next::util::rational::Rational::from(emu.get_video_fps()).into();
|
||||||
|
};
|
||||||
|
out_video_ctx.set_parameters(video_params).unwrap();
|
||||||
|
out_video_ctx.set_time_base(emu_time_base);
|
||||||
|
out_video_ctx.debug(Debug::all());
|
||||||
|
dbg!(out_video_ctx.codec().unwrap().id());
|
||||||
|
let mut out_video = output.add_stream_with(&out_video_ctx).unwrap();
|
||||||
|
out_video.set_time_base(emu_time_base);
|
||||||
|
let video_time_base = out_video.time_base();
|
||||||
|
let mut out_video_enc = out_video_ctx.encoder().video().unwrap();
|
||||||
|
out_video_enc.debug(Debug::all());
|
||||||
|
out_video_enc.set_format(ffmpeg_next::format::Pixel::YUV420P);
|
||||||
|
out_video_enc.set_width(u32::try_from(w).unwrap());
|
||||||
|
out_video_enc.set_height(u32::try_from(h).unwrap());
|
||||||
|
out_video_enc.set_time_base(video_time_base);
|
||||||
|
let mut out_video_enc = out_video_enc.open().unwrap();
|
||||||
|
let out_audio_codec = ffmpeg_next::encoder::find(ffmpeg_next::codec::Id::AAC).unwrap();
|
||||||
|
let mut out_audio_ctx = ffmpeg_next::codec::context::Context::new_with_codec(out_audio_codec);
|
||||||
|
out_audio_ctx.debug(Debug::all());
|
||||||
|
let mut audio_params = ffmpeg_next::codec::Parameters::new();
|
||||||
|
unsafe {
|
||||||
|
let aps = audio_params.as_mut_ptr();
|
||||||
|
(*aps).codec_id = out_audio_codec.id().into();
|
||||||
|
(*aps).sample_rate = emu.get_audio_sample_rate() as i32;
|
||||||
|
(*aps).channels = 2;
|
||||||
|
};
|
||||||
|
out_audio_ctx.set_parameters(audio_params).unwrap();
|
||||||
|
out_audio_ctx.set_time_base(ffmpeg_next::util::rational::Rational::new(
|
||||||
|
1,
|
||||||
|
emu.get_audio_sample_rate() as i32,
|
||||||
|
));
|
||||||
|
let mut out_audio = output.add_stream_with(&out_audio_ctx).unwrap();
|
||||||
|
out_audio.set_time_base(ffmpeg_next::util::rational::Rational::new(
|
||||||
|
1,
|
||||||
|
emu.get_audio_sample_rate() as i32,
|
||||||
|
));
|
||||||
|
let audio_time_base = out_audio.time_base();
|
||||||
|
dbg!(audio_time_base);
|
||||||
|
let mut out_audio_enc = out_audio_ctx.encoder().audio().unwrap();
|
||||||
|
out_audio_enc.set_channels(2);
|
||||||
|
out_audio_enc.set_format(ffmpeg_next::format::Sample::F32(
|
||||||
|
ffmpeg_next::format::sample::Type::Planar,
|
||||||
|
));
|
||||||
|
out_audio_enc.set_channel_layout(ffmpeg_next::ChannelLayout::STEREO);
|
||||||
|
out_audio_enc.set_time_base(audio_time_base);
|
||||||
|
out_audio_enc.set_rate(emu.get_audio_sample_rate() as i32);
|
||||||
|
let mut out_audio_enc = out_audio_enc.open().unwrap();
|
||||||
|
let mut out_vframe = FFVFrame::new(
|
||||||
|
out_video_enc.format(),
|
||||||
|
out_video_enc.width(),
|
||||||
|
out_video_enc.height(),
|
||||||
|
);
|
||||||
|
let mut out_aframe = FFAFrame::new(
|
||||||
|
out_audio_enc.format(),
|
||||||
|
out_audio_enc.frame_size() as usize,
|
||||||
|
out_audio_enc.channel_layout(),
|
||||||
|
);
|
||||||
|
dbg!(
|
||||||
|
out_audio_enc.channels(),
|
||||||
|
out_audio_enc.channel_layout(),
|
||||||
|
out_audio_enc.format()
|
||||||
|
);
|
||||||
|
dbg!(out_aframe.samples());
|
||||||
|
dbg!(out_aframe.data(0).len(), out_aframe.data(1).len());
|
||||||
|
output.write_header().unwrap();
|
||||||
|
assert!(emu.load(&rply.initial_state));
|
||||||
|
let mut frame = Frame::default();
|
||||||
|
let mut fb = vec![0_u8; w * h * 3];
|
||||||
|
|
||||||
|
while let Ok(()) = rply
|
||||||
|
.read_frame(&mut frame)
|
||||||
|
.inspect_err(|e| println!("Err: {e}"))
|
||||||
|
{
|
||||||
|
use ffmpeg_next::util::mathematics::Rescale;
|
||||||
|
//println!("FRAME");
|
||||||
|
let buttons = frame_to_buttons(&frame);
|
||||||
|
emu.run(buttons);
|
||||||
|
emu.copy_framebuffer_rgb888(&mut fb).unwrap();
|
||||||
|
// output one frame of video/audio, set_pts
|
||||||
|
// copy video to out_vframe
|
||||||
|
copy_video(&fb, &mut out_vframe);
|
||||||
|
let frame_num = i64::try_from(rply.frame_number).unwrap();
|
||||||
|
out_vframe.set_pts(Some(
|
||||||
|
frame_num.rescale(emu_time_base, out_video_enc.time_base()),
|
||||||
|
));
|
||||||
|
out_video_enc.send_frame(&out_vframe).unwrap();
|
||||||
|
// copy audio to out_aframe, set_pts
|
||||||
|
// maybe in a loop?
|
||||||
|
#[allow(unused_must_use)]
|
||||||
|
emu.peek_audio_sample(|samples| {
|
||||||
|
copy_audio(samples, &mut out_aframe);
|
||||||
|
});
|
||||||
|
out_aframe.set_pts(Some(
|
||||||
|
frame_num.rescale(emu_time_base, out_audio_enc.time_base()),
|
||||||
|
));
|
||||||
|
println!(
|
||||||
|
"vtime {} atime {}",
|
||||||
|
out_vframe.pts().unwrap() as f64 / 60.0,
|
||||||
|
out_aframe.pts().unwrap() as f64 / 48000.0
|
||||||
|
);
|
||||||
|
out_audio_enc.send_frame(&out_aframe).unwrap();
|
||||||
|
let mut encoded = ffmpeg_next::Packet::empty();
|
||||||
|
while out_video_enc.receive_packet(&mut encoded).is_ok() {
|
||||||
|
encoded.set_stream(0);
|
||||||
|
encoded.rescale_ts(out_video_enc.time_base(), video_time_base);
|
||||||
|
encoded.write_interleaved(&mut output).unwrap();
|
||||||
|
}
|
||||||
|
while out_audio_enc.receive_packet(&mut encoded).is_ok() {
|
||||||
|
encoded.set_stream(1);
|
||||||
|
encoded.rescale_ts(out_audio_enc.time_base(), audio_time_base);
|
||||||
|
encoded.write_interleaved(&mut output).unwrap();
|
||||||
|
}
|
||||||
|
if !frame.checkpoint_bytes.is_empty() {
|
||||||
|
assert!(emu.load(&frame.checkpoint_bytes));
|
||||||
|
}
|
||||||
|
if Some(rply.frame_number) == rply.header.frame_count() {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
out_video_enc.send_eof().unwrap();
|
||||||
|
out_audio_enc.send_eof().unwrap();
|
||||||
|
output.write_trailer().unwrap();
|
||||||
|
}
|
||||||
|
|
||||||
|
fn frame_to_buttons(frame: &Frame) -> [retro_rs::Buttons; 2] {
|
||||||
|
use retro_rs::Buttons;
|
||||||
|
let mut buttons = [Buttons::default(); 2];
|
||||||
|
for inp in &frame.input_events {
|
||||||
|
let port = usize::from(inp.port);
|
||||||
|
if port < buttons.len() && inp.device == 1 {
|
||||||
|
buttons[port] = Buttons::from(inp.val);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
buttons
|
||||||
|
}
|
||||||
|
|||||||
@@ -5,4 +5,4 @@ edition = "2024"
|
|||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
rply-codec = { path = "../codec" }
|
rply-codec = { path = "../codec" }
|
||||||
retro-rs = { version = "0.5.2", default-features=false }
|
retro-rs = { version = "0.5.3", default-features=false }
|
||||||
|
|||||||
Reference in New Issue
Block a user