Mercurial > sdl-ios-xcode
view VisualC/tests/testgl/testgl.vcproj @ 3496:78fc8ea578b2
Joe 2009-11-23 21:31:10 PST
If type is ::SDL_HAPTIC_CARTESIAN, direction is encoded by three positions
367 * (X axis, Y axis and Z axis (with 3 axes)). ::SDL_HAPTIC_CARTESIAN
uses
368 * the first three \c dir parameters. The cardinal directions would
be:
369 * - North: 0,-1, 0
370 * - East: -1, 0, 0
371 * - South: 0, 1, 0
372 * - West: 1, 0, 0
typedef struct SDL_HapticDirection
{
Uint8 type; /**< The type of encoding. */
Uint16 dir[3]; /**< The encoded direction. */
} SDL_HapticDirection;
An unsigned int can't store negative values and I don't see an alternate way to
encode them in the docs or source. The best I have been able to come up with is
using a negative magnitude for the effect but this will only get me 2 of the 4
quadrants in the plane for 2d effects. I looked at the win32 and linux
implementations and I believe is is safe to use signed ints in the direction
struct. I am unfamiliar with the darwin haptics API so I don't know if it is
safe.
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Fri, 27 Nov 2009 19:29:27 +0000 |
parents | d63e9f5944ae |
children |
line wrap: on
line source
<?xml version="1.0" encoding="Windows-1252"?> <VisualStudioProject ProjectType="Visual C++" Version="8.00" Name="testgl" ProjectGUID="{272D976B-A1DF-4DEB-BD7F-5C0D330E0C7D}" > <Platforms> <Platform Name="Win32" /> </Platforms> <ToolFiles> </ToolFiles> <Configurations> <Configuration Name="Debug|Win32" OutputDirectory=".\Debug" IntermediateDirectory=".\Debug" ConfigurationType="1" InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC70.vsprops" UseOfMFC="0" ATLMinimizesCRunTimeLibraryUsage="false" > <Tool Name="VCPreBuildEventTool" /> <Tool Name="VCCustomBuildTool" /> <Tool Name="VCXMLDataGeneratorTool" /> <Tool Name="VCWebServiceProxyGeneratorTool" /> <Tool Name="VCMIDLTool" PreprocessorDefinitions="_DEBUG" MkTypLibCompatible="true" SuppressStartupBanner="true" TargetEnvironment="1" TypeLibraryName=".\Debug/testgl.tlb" /> <Tool Name="VCCLCompilerTool" Optimization="0" AdditionalIncludeDirectories="..\..\..\include" PreprocessorDefinitions="_DEBUG,WIN32,_WINDOWS,HAVE_OPENGL" RuntimeLibrary="2" UsePrecompiledHeader="0" PrecompiledHeaderFile=".\Debug/testgl.pch" AssemblerListingLocation=".\Debug/" ObjectFile=".\Debug/" ProgramDataBaseFileName=".\Debug/" WarningLevel="3" SuppressStartupBanner="true" DebugInformationFormat="4" CompileAs="0" /> <Tool Name="VCManagedResourceCompilerTool" /> <Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" /> <Tool Name="VCPreLinkEventTool" /> <Tool Name="VCLinkerTool" AdditionalOptions="/MACHINE:I386" AdditionalDependencies="opengl32.lib" OutputFile=".\Debug/testgl.exe" LinkIncremental="2" SuppressStartupBanner="true" GenerateDebugInformation="true" ProgramDatabaseFile=".\Debug/testgl.pdb" SubSystem="2" /> <Tool Name="VCALinkTool" /> <Tool Name="VCManifestTool" /> <Tool Name="VCXDCMakeTool" /> <Tool Name="VCBscMakeTool" /> <Tool Name="VCFxCopTool" /> <Tool Name="VCAppVerifierTool" /> <Tool Name="VCWebDeploymentTool" /> <Tool Name="VCPostBuildEventTool" /> </Configuration> <Configuration Name="Release|Win32" OutputDirectory=".\Release" IntermediateDirectory=".\Release" ConfigurationType="1" InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC70.vsprops" UseOfMFC="0" ATLMinimizesCRunTimeLibraryUsage="false" > <Tool Name="VCPreBuildEventTool" /> <Tool Name="VCCustomBuildTool" /> <Tool Name="VCXMLDataGeneratorTool" /> <Tool Name="VCWebServiceProxyGeneratorTool" /> <Tool Name="VCMIDLTool" PreprocessorDefinitions="NDEBUG" MkTypLibCompatible="true" SuppressStartupBanner="true" TargetEnvironment="1" TypeLibraryName=".\Release/testgl.tlb" /> <Tool Name="VCCLCompilerTool" InlineFunctionExpansion="1" AdditionalIncludeDirectories="..\..\..\include" PreprocessorDefinitions="NDEBUG,WIN32,_WINDOWS,HAVE_OPENGL" StringPooling="true" RuntimeLibrary="2" EnableFunctionLevelLinking="true" UsePrecompiledHeader="0" PrecompiledHeaderFile=".\Release/testgl.pch" AssemblerListingLocation=".\Release/" ObjectFile=".\Release/" ProgramDataBaseFileName=".\Release/" WarningLevel="3" SuppressStartupBanner="true" CompileAs="0" /> <Tool Name="VCManagedResourceCompilerTool" /> <Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" /> <Tool Name="VCPreLinkEventTool" /> <Tool Name="VCLinkerTool" AdditionalOptions="/MACHINE:I386" AdditionalDependencies="opengl32.lib" OutputFile=".\Release/testgl.exe" LinkIncremental="1" SuppressStartupBanner="true" ProgramDatabaseFile=".\Release/testgl.pdb" SubSystem="2" /> <Tool Name="VCALinkTool" /> <Tool Name="VCManifestTool" /> <Tool Name="VCXDCMakeTool" /> <Tool Name="VCBscMakeTool" /> <Tool Name="VCFxCopTool" /> <Tool Name="VCAppVerifierTool" /> <Tool Name="VCWebDeploymentTool" /> <Tool Name="VCPostBuildEventTool" /> </Configuration> </Configurations> <References> </References> <Files> <File RelativePath="..\..\Sdl\Debug\SDL.lib" > </File> <File RelativePath="..\..\SDLmain\Debug\SDLmain.lib" > </File> <File RelativePath="..\..\..\test\testgl.c" > </File> </Files> <Globals> </Globals> </VisualStudioProject>