Skip to content

Commit

Permalink
feat: 🔖 Version 1.3.2
Browse files Browse the repository at this point in the history
performance stuff (mostly)
  • Loading branch information
Frontesque committed Jul 3, 2022
1 parent 48ec2b8 commit c388cc5
Show file tree
Hide file tree
Showing 6 changed files with 57 additions and 11 deletions.
6 changes: 6 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"cSpell.words": [
"getprop",
"SCRCPY"
]
}
28 changes: 28 additions & 0 deletions BUILDING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Building
## Intro
This is the guide to building the latest version of SCRCPY+ for all operating systems. Note: ***PREREQUISITES FOR RUNNING SCRCPY+ ARE DIFFERENT THAN BUILDING***

## Prerequisites
- Windows
- [Node v16](https://nodejs.org/en/)
- NPM (Comes with Node)
- Yarn for Node // run `npm i -g yarn`
- Linux / Mac
- [Node v16](https://nodejs.org/en/)
- NPM (Comes with Node)
- Yarn Package Manager // [Download](https://yarnpkg.com/) OR RUN `sudo npm i -g yarn`

## Build
- Windows
- Edit `src/renderer/nuxt.config.js` & comment the line that says `//Development` by adding 2 slashes `//` in front of the line. Uncomment the line that says `//Production` by removing the 2 slashes at the start of the line.
- run `yarn install`
- run `yarn install`
- run `yarn build`
- the output files should be in the `build` folder
- Linux / Mac
- Edit `src/renderer/nuxt.config.js` & comment the line that says `//Development` by adding 2 slashes `//` in front of the line. Uncomment the line that says `//Production` by removing the 2 slashes at the start of the line.
- Edit `src/renderer/nuxt.config.js` & change the line that says `os: "windows",` to say `os: "linux",`
***NOTE: IF YOU ARE ON MACOS, IT SHOULD STILL SAY LINUX, NOT MACOS***
- run `yarn install`
- run `yarn build`
- the output files should be in the `build` folder
8 changes: 2 additions & 6 deletions src/renderer/components/device.vue
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@
},
checkDevice() {
console.log(this.$router)
this.$scrcpy.execute("adb devices -l")
.then((data) => {
if (data.includes("device product:")) { // Device Detected
Expand All @@ -92,12 +93,7 @@
},
mounted() {
setInterval(() => {
this.checkDevice()
}, process.env.devicePollRate);
this.checkDevice()
setInterval(this.checkDevice(), process.env.devicePollRate);
}
}
Expand Down
16 changes: 14 additions & 2 deletions src/renderer/components/scrcpy.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,16 @@
<v-expansion-panel-header>Advanced</v-expansion-panel-header>
<v-expansion-panel-content>



<!-- Sliders -->
<div>Bitrate {{ bitrate }}M</div>
<v-slider v-model="bitrate" max="64" min="1" hint="A higher bitrate makes a clearer image but may increase lag" dense persistent-hint />
<!-- End Sliders -->




<!-- Advanced Actions -->
<v-list-item v-for="(item, i) in advArgs" :key="i">
<div style="display: flex;">
Expand Down Expand Up @@ -53,7 +63,7 @@
<!-- Error Dialog -->
<v-dialog v-model="dialog" width="500">
<v-card>
<v-card-title class="text-h5 grey darken-3">An error has occured</v-card-title>
<v-card-title class="text-h5 grey darken-3">An error has occurred</v-card-title>

<v-card-text v-text="dialogText" style="margin-top: 2em;" />

Expand Down Expand Up @@ -83,7 +93,7 @@ export default {
}
//console.log("scrcpy"+flags);
this.$scrcpy.execute("scrcpy"+flags)
this.$scrcpy.execute(`scrcpy --bit-rate ${this.bitrate}M`+flags)
.catch((err) => {
if (err.startsWith("INFO:")) return; // Catch information outputs
this.dialog = true;
Expand All @@ -105,6 +115,8 @@ export default {
selectedArgs: [],
bitrate: 8,
args: [
{
arg: "--turn-screen-off",
Expand Down
4 changes: 2 additions & 2 deletions src/renderer/nuxt.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
module.exports = {
env: {
version: "1.3.2",
scrcpyPath: "src/extraResources/scrcpy/", //Development
//scrcpyPath: "resources/scrcpy/", //Production
//scrcpyPath: "src/extraResources/scrcpy/", //Development
scrcpyPath: "resources/scrcpy/", //Production
os: "windows",

releasesUrl: "https://api.github.com/repos/Frontesque/scrcpy-plus/releases",
Expand Down
6 changes: 5 additions & 1 deletion src/renderer/pages/changelog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@
<ul>
<li>Make the back button more uniform throughout the app</li>
<li>Add new "Coming Soon" tool "Resource Monitor"</li>
<li>Add building guide to the github (BUILDING.md)</li>
<li>Major device polling improvements</li>
<li>Fix spelling error (im human too)</li>
<li>Finally add a bitrate slider after MANY requests</li>
</ul>
</section>

Expand Down Expand Up @@ -58,7 +62,7 @@
<li>Dynamically get the installed version of SCRCPY</li>
<li>Dynamically get the installed version of ADB</li>
<li>Minor UI Tweaks</li>
<li>Multiplatform / Linux Support</li>
<li>Multi-platform / Linux Support</li>
<li>Some Bug Fixes</li>
<li>Take 'Wireless Connection' Development Warning Away</li>
</ul>
Expand Down

0 comments on commit c388cc5

Please sign in to comment.