YAACC - UPNP Client and Server
Loading...
Searching...
No Matches
de.yaacc.openhome.OhVolume Class Reference

The volume of the OpenHome volume service is a number from 0 to VolumeMax (the device says how many steps it has), YAACC uses percent. More...

Collaboration diagram for de.yaacc.openhome.OhVolume:
Collaboration graph

Static Public Member Functions

static int toPercent (long value, long max)
 
static long fromPercent (int percent, long max)
 

Static Public Attributes

static final long RENDERER_MAX = 100
 What the renderer reports: VolumeMax, VolumeUnity and VolumeSteps.
 

Detailed Description

The volume of the OpenHome volume service is a number from 0 to VolumeMax (the device says how many steps it has), YAACC uses percent.

The renderer is the phone's music stream: 100 steps, so the number is the percent.

Member Function Documentation

◆ fromPercent()

static long de.yaacc.openhome.OhVolume.fromPercent ( int percent,
long max )
static
Returns
the device's volume step for the percent (0 to 100)

◆ toPercent()

static int de.yaacc.openhome.OhVolume.toPercent ( long value,
long max )
static
Returns
the volume as percent of the device's scale, 0 to 100; a missing or zero maximum counts as 100

Referenced by de.yaacc.openhome.OhRemote.volumePercent().

Here is the caller graph for this function:

The documentation for this class was generated from the following file: