How to install GestureRecognizer component in .NET? - c#

I have built an application that uses the GestureRecognizer (System.Windows.Ink.GestureRecognizer). The problem is that when testing it on some machines, IsRecognizerAvailable returns false. These systems are running .NET 3.5 and 4, so updates shouldn't be the problem. Can anyone tell me how to specifically install the GestureRecognizer component on systems where it is missing?

What is the OS on the machines where you don't get Recognizer. What I know is that Windows Ink support is limited on Windows XP/2K (its available on XP Tablet edition) but should be present in vistas onwards. Quoting from the link: http://msdn.microsoft.com/en-us/library/ms701189(v=vs.85).aspx - essentially indicates that gestures will not be available in windows XP.
Reduced Feature Set
Ink-enabled applications treat mouse
events as pen movements to simulate
working with a tablet pen. Users can
add ink, erase ink, and save ink
documents. However, recognition and
gestures are not available for users
other than those running Windows XP
Tablet PC Edition.

Related

How to support 2 finger pinch/zoom gesture from precision touchpad in a .net wpf application?

I have .net code for a WPF app that recognizes two finger pinch to zoom or rotate and translate manipulations but only when running on a PC with a multi-touch screen (Win10 Pro 64bit Microsoft Surface), not a touchpad which is what I am trying to support. My development machine (Win10 Pro 64bit Dell Inspiron 7577) has a "precision touchpad" that supports up to 4 finger gestures. Any web browser I run on this machine responds to 2 finger zoom requests, even the VS2017 IDE itself responds to two finger zoom/scroll requests. None of the Main window touch event callbacks are executed. The code I referred to is basically listing 6.7 From Adam Nathans' WPF 4.5 Unleashed book converted to VB.net. I have also been trying to implement Florian Rappls' "Another WPF only way" approach described here WPF and multi-touch however the WndProc() is never called. Any input would be greatly appreciated

Surface SDK 2.0 touch events do not trigger on Surface Pro 2

I am trying to develop a touch-enabled application in C# that runs on Microsoft's Surface Pro 2. Searching suggests that the best tool to use for this is the Surface SDK 2.0, which I have installed on my development machine. I have also installed the Surface Runtime on the device itself.
I am able to run and use all the sample applications packaged with the Surface SDK on my Windows 7 dev machine using the Input Simulator tool, but when I attempt to run the sample apps on the Surface Pro 2, finger touches are not recognized. The only touch input that is recognized by these applications seems to be the equivalent of mouse clicks sent when I touch the screen with the stylus. Touch input of all types is recognized outside of the Surface SDK sample apps, so the hardware does not seem to be at fault.
In addition to testing the sample apps, I have created two of my own test programs that attempt to handle touch events on the Surface Pro 2. Both use the Surface SDK, and one uses the WPF framework while the other uses XNA. Both work fine on Win 7 with Input Simulator, and neither captures any touch events on the Surface Pro 2.
I found this unanswered question from someone who seems to have a similar issue.
I also found this article which describes using one of the sample apps to debug issues that sound like what I'm experiencing. However, the recommended solution, to enable SurfaceInput, doesn't work for me, as I can't find any reference to that tool / service on my device.
My questions are:
Is there something else I need to enable or install on the device to allow touch input to work with the Surface SDK 2.0?
Is the Surface Pro 2 incompatible with the Surface SDK for some reason?
Is there a better option than the Surface SDK for developing touch applications on Surface? I'm not too picky about the language; C# was most convenient for these tests.

Support for XNA in WP8?

After watching a little bit of the summit keynote I kind of heard conflicting reports about it, but is it official that XNA is being dropped for WP8? I'm guessing since the future version of WP supports previous generation of apps that this is probably not true.
If it is though is using C# even an option for games or is C++ with DirectX the only way to go?
the official wp7dev twitter account had this to say too
"XNA Framework apps are fully supported in WP8. The new WP SDK will support building XNA Framework games for both WP7.x & for WP8"
https://twitter.com/wp7dev/status/215513026374270977
Personally given the lack of XNA updates or information and the lack of any Metro support on windows 8 I'm staying a little skeptical until I see an SDK and the publishing rules.
Mary Jo Foley had this to say about that:
Microsoft officials have said the XNA tools/runtime environment used primarily by game developers isn't supported on Windows 8. On Windows Phone 8, XNA is "supported," so existing Windows Phone games will run. But Microsoft's advice to phone developers going forward, just like it is for Windows 8, is to use native code, meaning C and C++, to write games.
As the public WP8 SDK is now available, I can confirm that you cannot develop XNA apps for the #WP8 platform directly. You can only target the WP7 platform with your XNA apps and they will run on WP8 devices just fine.
I'm sure it's too early to speculate on this at this point, we'll see when the SDK is released. But from what I've seen so far - I would say yes, XNA might not be officially supported WP8 and onwards (read - new features will probably only be available via the DirectX interface, but existing features will continue to be supported). However, according to this thread, games that use Monogame to run on Windows 8 metro will pass certification. So in one way or the other, the platform will not die.
Edit: I just noticed this tweet from Shawn Hargreaves: Windows Phone 8 runs all 7 apps including XNA ones. We're adding new features (native code, D3D) not taking away old ones
I've been working on and off on an XNA game that I had started with VS2010 & WP 7 SDK, and later upgraded to 7.5 (Mango). I loaded up that project in VS2012 and the WP8 SDK and it ran just fine, compiled with no errors and ran smoothly.
As previously stated, XNA projects in VS2012 and the WP8 SDK can only target the WP 7.1 platform. On the upside, all phones running WP 7.5, the upcoming 7.8 and WP8 will run your game without any issues. From that point of view, XNA is fully supported in the WP8 SDK, on WP8 devices, but these WILL NOT be WP8 projects.
By not being WP8 projects, the downside is that you CANNOT use WP8-exclusive features, such as:
In-app purchasing / micro-transactions (this one hurts XNA devs the
most)
Your games will always be 800x480 since you need WP8 projects to support higher resolutions. Your XNA games should automatically scale up when run on devices with a higher res
Exclusive WP8 networking features & APIs, including Bluetooth and NFC
Speech and voice recognition APIs
Your XNA game cannot register a protocol extension for app-to-app communications
New Live Tile templates
The dev highlights for WP8 are on the wpdev blog at http://blogs.windows.com/windows_phone/b/wpdev/archive/2012/11/05/windows-phone-8-developer-platform-highlights.aspx.

Creating a universal video player (XP, vista, 7)

Im trying to create a media player (in C# .net 4.0) that will work on windows XP (SP3), vista and 7. Normally I would just go the easy way and use WPF's own MediaElement, but since that relies on Windows Media Player 10 or newer, that wont work as Windows XP SP3 may only have WPM9.
First I tried downloading Jerimiah Morill's WPF MediaKit sample application, but this used the EVR which wont show on my test machine (a Windows xp SP3 only with default codecs and default programs, plus the various .Net framework installations). I also downloaded the binaries and tore these apart, creating a new project only with reference to the DirectShow-dll and the bare minimums from the WPF mediakit, this time with no reference whatsoever to EVR. Still no luck. This i'm having a hard time understanding - should'nt even Windows XP be able to play movies using VMR stright out of the box?
I found some samples of media players where one of these works. This one is called DxPlay and uses directshow's graphbuilder, but is built in winforms, has some rather raw-looking code, and will not scale, seek, handle audio, and in general seems rather sketchy.
So, Is there any easy way to create a media player that will play on all the mentioned platforms without pushing WMP10+? I had high hopes for WPF MediaKit, but something is preventing it from playing on Windows XP SP3 (any solution to this would be very interesting).
Thank you very much in advance!
-ruNury
I would try to wrap VLC media player in your .Net project.
Here are some .Net projects that might help you:
http://vlcdotnet.codeplex.com/
http://sourceforge.net/projects/libvlcnet/
http://www.codeproject.com/Articles/109639/nVLC
MSDN suggest EVR (Enhanced Video Renderer) for video output in systems where it is supported: Windows Vista and later. With its introduction, its predecessors - Video Mixing Renderer filter (versions 7 and 9) were cut on smooth scaling of video. Video Mixing Renderer 7 is also less capable in terms of customization, however it consumes far less resources (does not use Direct 3D) and you can output way more videos at once.
Your standard solution here is to support both VMR and EVR output and use the latter starting Windows Vista, fall back to the former otherwise.
EVR is "unofficially" installed in Windows XP with .NET runtime and can be used with an instantiation trick: you the respective DLL is not COM registered and you cannot create an instance using CoCreateInstance API, however you succeed if you do CoLoadLibrary, DllGetClassObject and friends.
For C# development you typically consume DirectShow through DirectShow.NET Library.

Windows Mobile 6.5 modern GUI development

How to approach a modern GUI development in Windows Mobile 6.5. I can see in .NET CF 2.0/3.5 only legacy common controls, no alpha blended controls, no fading etc. Comparing to Android or Symbian, Windows Mobile 6.5 look-a-like of applications is very elderly.
Is there support for WPF in Windows Mobile 6.5?
Thanks and Regards
Dominik
WPF is not supported. Silverlight is not supported in current phones but will be supported with Windows Phone 7. XNA will be supported on Windows Phone 7.
For the current phones on the market you really have to abandon the idea that you're going to get a decent UI by simply dragging controls out of the toolbox. That simply is not going to happen. You can still create compelling UI, but you have to do custom/manual drawing of your controls.
Never heard of WPF development for WM.
But there is Silverlight 4 and (theoretically) Windows Phone 7... So if you want to develop for Windows platform you'd probably target Silverlight technology, not WPF. And Windows Phone 7, not WM 6.5

Categories

Resources