SlimDX from VB to C#

Started by
0 comments, last by Spazzarama 9 years, 6 months ago

Hi, I'm news to SlimDX and have this project to convert some VB code to C#.

In the VB code, there is a section that compares JoystickState.GetPointOfViewControllers but the call is

js1.GetPointOfViewControllers(0) <> js2.GetPointOfViewControllers(0)

but try as I might, I cannot translate this into C# and so far, I haven't come across any documentation that allows calling GetPointOfViewControllers with a parameter. So the only thing that I can do in C# is

js1.GetPointOfViewControllers()[0] != js2.GetPointOfViewControllers()[0]

is this right please?

Advertisement


js1.GetPointOfViewControllers()[0] != js2.GetPointOfViewControllers()[0]

is this right please?

From the SlimDX documentation


public int[] GetPointOfViewControllers()

So yes, assuming you will always have at least one result from each call, that is what you should do.

Justin Stenning | Blog | Book - Direct3D Rendering Cookbook (using C# and SharpDX)

Projects: Direct3D Hook, EasyHook, Shared Memory (IPC), SharpDisasm (x86/64 disassembler in C#)

@spazzarama

 

This topic is closed to new replies.

Advertisement