UPDATE: This is no longer an HP TouchPad-specific port, but an updated port for all WebOS users. Please let me know if you encounter any issues!

What is this?
This started out as a TouchPad-specific port, until I started getting tweets and messages from cellular webOS device-users who said they loved the improvements on those devices as well. Now it's offered for everything . Many thanks for kayahr, m0ngr31 (nexapps), and WayneRSH's contributions, without which this update definitely wouldn't exist! You all rock my socks straight off.

Disclaimer
I touched the ScummVM source for the first time solely to build on the WebOS port for the Touchpad. I am in no way an expert on ScummVM, or a dedicated developer to the project. Generally I'm a pretty busy guy, so I'm keeping all my source public on Github just in case I get too bogged down to keep maintaining this. Just know that, while I've tested my builds on my own TouchPad and others have reported success on their other WebOS devices, there's no guarantee it won't destroy yours. Use at your own risk.

Improvements in this fork
In addition to higher resolution graphics with filtering and scaling support, there are significant changes to the control structure:

Flick two fingers downward for the menu

Flick two fingers upward for the keyboard

Flick two fingers left to emulate the Escape key

Flick two fingers right to toggle Touchpad Mode.

Flick three fingers right to toggle Auto-Drag Mode.

When this is on, put a finger on screen and hold still for half a second to start dragging.

Whether it's on or off, you can always double-tap and hold to start dragging, just like you would on a computer trackpad.

Flick three fingers down to pause and unpause (forgive the spacebar message)

Tap with one finger to click normally.

Tap a second finger with one already touching the screen for a right-click.

Tap a third finger with two already on screen for a middle-click.

Touchpad Mode is what you might be used to form the old WebOS port. This is now OFF by default. When on, you move the finger on the screen, and the mouse pointer moves relative to it -- just like using a laptop trackpad.

When Touchpad Mode is OFF (default) the pointer will move to exactly where you tap, so tapping on an object clicks that object. If you put your finger on the screen and slide it around, you can hover over objects on the screen (useful to see what they are) without risking clicking on them.

Auto-Drag Mode is useful for games like Curse of Monkey Island and Full Throttle that require you to hold down the mouse button to access the possible actions. You can still put your finger on screen and immediately slide it around to hover over things without clicking.

By far the easiest way to install this is by putting Preware on your device, and simply tapping the above link from your TouchPad browser. If you need another method, the great Google knows all.

Want to get involved with the source?Fork me (or the official scummvm repo, add mine as an external, pull it into a branch, and merge it with your branch/master if you know what you're doing with Git), follow the instructions here to build, and ignore flac if it won't compile (just use the --disable-flac parameter when you ./configure -- thanks md5!). Have fun!

Last edited by TomFrost on Mon Oct 03, 2011 3:24 am; edited 9 times in total

Mon Sep 05, 2011 6:05 pm

WayneRSH

Joined: 05 Sep 2011
Posts: 5

Hi TomFrost and thanks for your work !

I wanted to try to compile something for my brand new TouchPad, for the fun of it, and I started with ScummVM, based on your git repo, so thanks again for that !

I did some quick modifications of your code, but I'm way too lazy to create a github account.
So, I'm just gonna link the file I've touched. Feel free to do whatever you want with it !

But before that, please forgive me for my ugly code , I did that just to test and have fun with the SDK.
But hey, it's kinda working (on my TouchPad only, I don't have any other webOS platform to test), so if it can help you gain some time, that will be enough for me.

Things I've implemented :

The cursor goes where you tap and clicks. When you drag, it follows your finger.
It can be quite annoying in games like Sam & Max, as you have your finger on the cursor and can't easily figure out what's the function you've selected..)
Could shift the cursor a bit, to put it on the top left of the finger for example.

Right click : hold first tap, then tap with another finger, and you've got your right click !

Middle click : hold 1, hold 2, tap 3

Two fingers swipes for the menus and escape key (instead of one, to avoid unwanted menus when playing, and 60% of the screen instead of 90%) :

Last edited by WayneRSH on Tue Sep 06, 2011 11:31 pm; edited 1 time in total

Mon Sep 05, 2011 10:34 pm

TomFrost

Joined: 23 Apr 2007
Posts: 178

Beautiful, Wayne! The multitouch was exactly what I needed to see! I'll work on implementing that into mine, and making it toggle-able so you can choose between the mouse modes

Tue Sep 06, 2011 1:40 am

phunimator

Joined: 01 Jun 2009
Posts: 56
Location: London

Hi there,

Just tried WayneRSH's build and it is working fantastically! The multitouch menu's and escaping is very accurate and easy to trigger Thank you!!

Also I am liking the direct cursor touch and click, it is working well for games like Monkey Island. I look forward to the tog-gable controls from TomFrost.

On another note, I was wondering is a left-click + hold could be implemented some how as an option? As you may know, games like Curse of Monkey Island use an option where you have to click and hold the left mouse button to bring up another set of options, in the game it is a Verb coin that lets you pick specific actions where you just slide to where you want, and then let go of the button to select. Currently this does not work in any of the tested IPK's, but would be great if it could make its way in there somehow.

Thanks again to both of you for your amazing work!!

Tue Sep 06, 2011 12:35 pm

sevScummVM Lead

Joined: 21 Sep 2005
Posts: 1945

Hi TomFrost,

This seems like a nice port. Perhaps it would be good to merge with the main WebOS port, so your changes will be in the mainline?

Eugene

Tue Sep 06, 2011 3:57 pm

TomFrost

Joined: 23 Apr 2007
Posts: 178

quote:Originally posted by phunimator

On another note, I was wondering is a left-click + hold could be implemented some how as an option?

Yessir! I'm a big fan of COMI and FT, which both use that scheme. I'm working on that now Initially, I'd like a two-finger slide to the right to toggle between Touchpad mode and Click-where-tapped, and a three-finger slide to the right to toggle between click and click+drag.

quote:Originally posted by sevHi TomFrost,

This seems like a nice port. Perhaps it would be good to merge with the main WebOS port, so your changes will be in the mainline?

Eugene

That would be fantastic! I'd definitely want to see this tested by someone with a non-TouchPad webos device, though, since I'm developing this within the same backend, but I'd be tickled if this went to mainline after I'm certain I didn't break anything with all other webos devices

Last edited by TomFrost on Tue Sep 06, 2011 11:41 pm; edited 1 time in total

Tue Sep 06, 2011 11:40 pm

WayneRSH

Joined: 05 Sep 2011
Posts: 5

@phunimator : I've added the left-click + hold : just click and hold 0.5s without moving (well, less than 5 pixels), it should be good.
Tested on Full throttle (I believe it's the same mechanism as in the Curse of Monkey Island).

@TomFrost : Tell me if you want me to push the file or something. Or just do whatever you want with this o/

[Edit] :

quote:Originally posted by TomFrost

quote:Originally posted by phunimator

On another note, I was wondering is a left-click + hold could be implemented some how as an option?

Yessir! I'm a big fan of COMI and FT, which both use that scheme. I'm working on that now

Woops, sorry about that mate
But I'd like to see how you did that one ! I used a little "trick" with your queued event, so I'm pretty sure that you have a better solution !

Last edited by WayneRSH on Tue Sep 06, 2011 11:45 pm; edited 1 time in total

Tue Sep 06, 2011 11:41 pm

TomFrost

Joined: 23 Apr 2007
Posts: 178

Nice, Wayne! Throw me a pull request and I'll merge your updates in . One thing I want to improve on is the tracking of multiple fingers. Right now it gets a bit sketchy with the finger placements (example: put one finger at the right of the screen. Next, put another finger at the bottom of the screen. Now swipe the first finger to the left. You've just triggered the escape key), which I think we'll run into trouble with when we refine this a bit. But your code will go a looong way to getting this done!

Tue Sep 06, 2011 11:44 pm

WayneRSH

Joined: 05 Sep 2011
Posts: 5

Hm, I think I messed up with my git checkout, I can't commit..
(My first time with git )

(Hell, you're right about the multitouch, could lead to some problems, nice find )

And good night.

Tue Sep 06, 2011 11:53 pm

TomFrost

Joined: 23 Apr 2007
Posts: 178

I pushed an update to my fork -- it still doesn't have the various mouse modes, but I did change how finger tracking works so that we have a much more accurate method of determining gestures. Now, a small flick left with two fingers is enough to press Escape (and it triggers when your fingers move far enough, not when they lift off the screen -- no guessing at the correct distance that way). Same with the menu and keyboard. I laid the framework for a flick right to change mouse modes, but for some reason my dialog is causing ScummVM to crash. Falling asleep as I type this, though, so I'll debug later . Worst comes to worst, I'll trigger that on mouseup... but I don't want to if I don't have to.

No new build yet since this isn't stable, but it gives us a good starting point for gestures

Wed Sep 07, 2011 3:27 am

phunimator

Joined: 01 Jun 2009
Posts: 56
Location: London

Hi All,

Just wanted to say that Curse of Monkey Island works beautifully now Thanks so much guys! I really appreciate your work.

-Edit
Sorry just wanted to say that the build are used was WayneRSH's latest one.

Wed Sep 07, 2011 12:57 pm

TomFrost

Joined: 23 Apr 2007
Posts: 178

Updated my fork -- same link as in the OP. Note the new controls . I'll try to add the auto-drag toggle tomorrow.

Thu Sep 08, 2011 3:22 am

jedinat

Joined: 08 Sep 2011
Posts: 7

The screen is squashed so there's black bars on top and bottom. When I turn on aspect ratio correction the image correctly fills the screen, but the touch controls won't work for the top and bottom.

Thu Sep 08, 2011 4:20 am

shareef68

Joined: 08 Sep 2011
Posts: 3

quote:Originally posted by jedinatThe screen is squashed so there's black bars on top and bottom. When I turn on aspect ratio correction the image correctly fills the screen, but the touch controls won't work for the top and bottom.

install internalz through preware then use internalz to delete the /media/internal/SummVM/scummvmrc file