08 02


Delphi Graphics and Game Programming Exposed! with DirectX For versions 5.0-7.0:Force Feedback                       Search Tips   Advanced Search        Title Author Publisher ISBN    Please Select ----------- Artificial Intel Business & Mgmt Components Content Mgmt Certification Databases Enterprise Mgmt Fun/Games Groupware Hardware IBM Redbooks Intranet Dev Middleware Multimedia Networks OS Productivity Apps Programming Langs Security Soft Engineering UI Web Services Webmaster Y2K ----------- New Arrivals









Delphi Graphics and Game Programming Exposed with DirectX 7.0

by John Ayres

Wordware Publishing, Inc.

ISBN: 1556226373   Pub Date: 12/01/99














Search this book:
 



Previous Table of Contents Next kinetic force: An active push on one or more axes on a force feedback device. Note: Force feedback devices are required to have a safety feature installed that prevents the playback of effects unless the user is actively gripping the device. This helps avoid potential injury that might occur if the user is trying to pick up the device while a kinetic force effect is playing. Condition Unlike a kinetic force, a condition is a resistance or force that is applied to one or more axes in response to their movement or position. For example, the self-centering effect that a force feedback joystick automatically exhibits is a condition that tries to move the stick back to its center position. Another example would be to apply a dampening effect to the stick in order to re-create the resistance of moving around in an underwater environment. There are currently four different types of conditions, which we’ll cover in more detail shortly. condition: A resistant force applied to one or more axes on a force feedback device in response to the movement or position of those axes. Magnitude Magnitude is a measurement of the strength of a kinetic force, relative to the total maximum force that can be output by the device. The magnitude of a force can be expressed as an integer value between 10,000 and 10,000, where positive values represent a force in one direction and negative values represent the same force in the opposite direction. The DI_FFNOMINALMAX constant defined by the DInput unit, initialized to 10,000, represents the total maximum force that can be exerted by the device on any given axis. This constant allows the developer to define the magnitude of a force as a percentage of the total maximum force available on the device (i.e., DI_FFNOMINALMAX div 2 would be 50 percent of the maximum available force). magnitude: A measurement of the strength of a kinetic force output by a force feedback device, relative to the total maximum force available on the device itself. Coefficient Coefficient is conceptually similar to magnitude, except that it is a measurement of the strength of resistance to movement along an axis. Like magnitude, this value is expressed as an integer between 10,000 and 10,000, where positive values represent resistance and negative values represent acceleration (i.e., it has the effect of pulling along the direction of motion). Again, it is best to use the DI_FFNOMINALMAX constant to define a coefficient as a percentage of the total maximum force. coefficient: A measurement of the strength of resistance output by a force feedback device in response to the movement of an axis, relative to the total maximum force available on the device itself. Note: In the case of a spring condition (discussed later in this chapter), a negative coefficient has the effect of pushing the axis away from the defined neutral point. Duration Duration defines how long the effect will play, measured in microseconds. The constant DI_SECONDS, found in the DInput unit, can be used to define the duration in terms of one-second intervals (or fractions thereof). The constant INFINITE can also be used to indicate an effect with no duration. This type of effect will play until explicitly stopped or the IDirectInputEffect object is freed. In the case of triggered effects, playback is stopped when the duration expires or the button is released. Tip: An infinite duration is typically used for condition effects or periodic forces; it typically doesn’t make sense to specify an infinite duration for a constant or ramp force. Sample Period Sample period defines the interval between actual changes in the strength of a force, measured in microseconds. Setting this to a large value will cause the strength of the effect to be adjusted fewer times over the course of its duration, which may cause a ratcheting sensation. Setting this value to zero allows for the smoothest change in relative force strength. Gain Gain acts as a scaling factor for magnitudes and coefficients. It is expressed as a value between 0 and 10,000, indicating the percentage by which to scale the magnitude or coefficient. For example, 10,000 indicates no scaling, whereas 5,000 indicates 50 percent of the specified magnitude or coefficient. Gain can be applied to the entire device or only to individual effects. The DI_FFNOMINALMAX constant can again be used here to easily define a scaling factor as a percentage of the nominal value. gain: A scaling factor for magnitudes and coefficients, measured in hundredths of a percent. Note: Use the SetProperty method of the IDirectInputDevice interface in order to set the gain for the entire device. Axes Axes determine what axis (or axes) of movement on the force feedback device will be affected by the force feedback effect. This also indirectly determines the available directions for an effect, depending on how many axes will be affected by the force feedback output. Of course, the axes available are totally dependent on the type of device. For example, most force feedback joysticks allow output along the x and y axes, as shown below. Other devices, such as steering wheels, may define these axes differently. Axes can be identified by using the DIJOFS_* constants. Figure 8-1:  Axes of force feedback output Previous Table of Contents Next Products |  Contact Us |  About Us |  Privacy  |  Ad Info  |  Home Use of this site is subject to certain Terms & Conditions, Copyright © 1996-2000 EarthWeb Inc. All rights reserved. Reproduction whole or in part in any form or medium without express written permission of EarthWeb is prohibited. Read EarthWeb's privacy statement.

Wyszukiwarka

Podobne podstrony:
SERWIS 2010 08 02
08 02 KPGO Prognoza ooś
08 02
MegaDance Vol 18 (08 02 2015) Tracklista
pdm? 2016 08 02
08 02
Pisemny egzamin pa pilota wycieczek 08 02 2007
08 02 Remonty i usuwanie usterek
technik elektryk11[08] o3 02 n
TI 02 05 08 T pl(1)
TI 99 02 08 T B M pl(1)

więcej podobnych podstron