al_set_haptic_gain(3)
πΈ NAME πΈ
al_set_haptic_gain β Allegro 5 API. This is the Allegro 5 API manual page for setting a haptic deviceβs gain, bestie. π
β¨ SYNOPSIS β¨
#include <allegro5/allegro.h>
bool al_set_haptic_gain(ALLEGRO_HAPTIC *hap, double gain)
π DESCRIPTION π
Okay so al_set_haptic_gain sets the gain of the haptic device β but only if the device supports it. Gain is much like volume for sound: itβs as if every effectβs intensity is multiplied by it. Gain is a value between 0.0 and 1.0. It returns true if set successfully, false if not. π«Ά
It only works if al_get_haptic_capabilities(3) returns a value that has ALLEGRO_HAPTIC_GAIN(3)ALLEGRO_HAPTIC_CONSTANTS(3) set. If not, this function returns false, and all effects will be played without any gain influence. No cap, thatβs just the vibe. π
π¦ SINCE π¦
5.1.8
[Unstable API]: this might get simplified, because support for all the exposed features is limited across all of the platforms, and the team is awaiting feedback from users. π
source/version: Allegro reference manual β date: not listed on this footer, bestie. π
π¦ where this page comes from
- arch rolling: allegro 5.2.11.3-2 Β· Zlib AND BSD-3-Clause AND OFL-1.1 AND LicenseRef-Custom
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms