commit | 19bfe078787c76a79f99467b791e5fe3a655bcba | [log] [tgz] |
---|---|---|
author | Jorge E. Moreira <jemoreira@google.com> | Wed Nov 20 15:25:52 2019 -0800 |
committer | Jorge E. Moreira <jemoreira@google.com> | Mon Jan 06 14:05:14 2020 -0800 |
tree | ccb264f670369348fe3d9e042dfb19d30ce6ff6d | |
parent | 1f65a4a75b2c76fb8b47fdbe1c2bf9ddf70adb6c [diff] |
Scale pointer coordinates to screen size from the webRTC client The webRTC client has a video tag with a fixed size of 360x720 and sent the pointer events to the server in that scale. The server then scaled those cordinates to a hardcoded size of 720x1440 and sent that to the guest. No further scaling was performed so other screen sizes were not properly supported. Even if the final events were to be scaled to the screen size this wouldn't work well the screen's aspect ration was other than 1:2 since the video stream in the client won't necessary occupy the entire height or width of the element capturing the events. With this change the webRTC client scales the event coordinates to the resolution of the video stream, which matches the cf screen size. By doing this in the client it can take into consideration the fact that the video won't scale evenly when it has different aspect ratios. Bug: 141887532 Test: locally Change-Id: I80ba8496bde3aceb0563876e24bee268daa4a977
git clone https://github.com/google/android-cuttlefish cd android-cuttlefish debuild -i -us -uc -b sudo dpkg -i ../cuttlefish-common_*_amd64.deb sudo apt-get install -f
aosp-master
if you don't know what you're looking foraosp_cf_x86_phone
and click on userdebug
for the latest buildArtifacts
aosp_cf_x86_phone-img-xxxxxx.zip
-- it will always have img
in the name. Download this filecvd-host_package.tar.gz
. You should always download a host package from the same build as your images.mkdir cf cd cf tar xvf /path/to/cvd-host_package.tar.gz unzip /path/to/aosp_cf_x86_phone-img-xxxxxx.zip
Launch cuttlefish with:
$ HOME=$PWD ./bin/launch_cvd
Stop cuttlefish with:
$ HOME=$PWD ./bin/stop_cvd
You can use adb
to debug it, just like a physical device:
$ ./bin/adb -e shell
You can use the TightVNC JViewer. Once you have downloaded the TightVNC Java Viewer JAR in a ZIP archive, run it with
$ java -jar tightvnc-jviewer.jar -ScalingFactor=50 -Tunneling=no -host=localhost -port=6444
Click "Connect" and you should see a lock screen!