Copyright © 2013-2014 MultiMedia Soft

WSCROLLER_SETTINGS structure

Previous pageReturn to chapter overviewNext page

The WSCROLLER_SETTINGS data structure describes the graphical settings applied to a specific waveform scroller. Graphical settings related to a specific waveform scroller can be retrieved and modified through the WaveformScroller.SettingsGet and WaveformScroller.SettingsSet methods.

 

For further details about methods of the Waveform scroller refer to the WaveformScroller class.

For a tutorial about the use of Waveform scrollers refer to the How to scroll the sound's waveform during playback tutorial.

 

Visual C++ definition

 

typedef struct

{

     long nStereoVisualizationMode;

     OLE_COLOR colorWaveLinePeak;

     OLE_COLOR colorWaveLineCenter;

     short nWaveLineIntensityFactor;

     OLE_COLOR colorWaveBackground;

     short bUseHalfColorsForPeaks;

     short bAppearance3d;

     OLE_COLOR colorPositionLine;

     OLE_COLOR colorBorder;

     short bPositionLineShow;

     long nPositionLineDashStyle;

     short nPositionLineWidth;

     long nPositionLineHighCap;

     long nPositionLineLowCap;

     long nPositionLineDashCap;

     short nPositionLineTranspFactor;

     long nGraphicItemsMask;

     long nUpdateSpeed;

     float fVerticalZoomFactor;

} WSCROLLER_SETTINGS;

 

 

Visual Basic definition

 

Public Type WSCROLLER_SETTINGS

    nStereoVisualizationMode as enumWaveformStereoModes

    colorWaveLinePeak as OLE_COLOR

    colorWaveLineCenter as OLE_COLOR

    nWaveLineIntensityFactor as Integer

    colorWaveBackground as OLE_COLOR

    bUseHalfColorsForPeaks as Boolean

    bAppearance3d as Boolean

    colorPositionLine as OLE_COLOR

    colorBorder as OLE_COLOR

    bPositionLineShow as Boolean

    nPositionLineDashStyle as enumWaveformLineDashStyles

    nPositionLineWidth as Integer

    nPositionLineHighCap as enumLineCaps

    nPositionLineLowCap as enumLineCaps

    nPositionLineDashCap as enumLineDashCaps

    nPositionLineTranspFactor as Integer

    nGraphicItemsMask as enumGraphicItemMaskValues

    nUpdateSpeed as enumWaveScrollerAutoUpdate

    fVerticalZoomFactor as Single

End Type

 

 

 

Member

Description

 

 

nStereoVisualizationMode

Visualization mode used for displaying stereo sounds

Supported values are the following:

Mnemonic constant

Value

Meaning

STEREO_MODE_CHANNELS_BOTH

0

Right and left channels are displayed separately

.

STEREO_MODE_CHANNELS_LEFT

1

Only the left channel content is displayed on

STEREO_MODE_CHANNELS_RIGHT

2

Only the right channel content is displayed

STEREO_MODE_CHANNELS_MIXED (default)

3

Right and left channels contents are mixed together

colorWaveLinePeak

Color used for rendering peaks of the waveform line. See screenshot above.

colorWaveLineCenter

Color used for rendering the center of the waveform line. See screenshot above.

nWaveLineIntensityFactor

Factor of gradient intensity of the waveform line.

This value can range from 0 to 100 with a default value of 50. Values outside of this range will be automatically capped to the nearest valid value.

On the screenshot below you can appreciate the difference between the default value 50 (on the left) and a value of 20 (on the right):

colorWaveBackground

The color used to render the waveform background (default is set to Black).  See screenshot above.

bUseHalfColorsForPeaks

Boolean value that specifies if waveform peaks will have a half intensity color.

This field is ignored when colors set into the colorWaveLinePeak and colorWaveLineCenter fields are different.

Supported values are the following:

Value

Meaning

False

Don't use half color for drawing waveform peaks

True (default)

Use half color for drawing waveform peaks

bAppearance3d

Boolean value that specifies if the waveform scroller is displayed with 3D borders.

Supported values are the following:

Value

Meaning

False

Doesn't display 3D borders

True (default)

Displays 3D borders

colorPositionLine

The color used to render the central playback position line (default is set to White).  See screenshot above.

colorBorder

The color used to render the border (only when the bAppearance3d parameter is set to False) (default is set to Black)

bPositionLineShow

Boolean value that specifies if the central playback position line must be shown or hidden.

Supported values are the following:

Value

Meaning

False

Hides the playback position line

True (default)

Shows the playback position line

nPositionLineDashStyle

Dash style of the line that indicates a selected position on the waveform.

Supported values are the following:

Mnemonic constant

Value

Meaning

LINE_DASH_STYLE_SOLID

0

Solid line.

LINE_DASH_STYLE_DASH

1

Dashed line.

LINE_DASH_STYLE_DOT

2

Dotted line.

LINE_DASH_STYLE_DASH_DOT

3

Alternating dash-dot line line.

LINE_DASH_STYLE_DASH_DOT_DOT

4

Alternating dash-dot-dot line line.

nPositionLineWidth

Width in pixels of the position line.

nPositionLineHighCap

Type of cap for the high end of the position line.

Supported values are the following:

Mnemonic constant

Value

Meaning

LINE_CAP_SQUARE

0

Specifies a square cap.

LINE_CAP_ROUND

1

Specifies a circular cap.

LINE_CAP_TRIANGLE

2

Specifies a triangular cap.

LINE_CAP_SQUARE_ANCHOR

3

Specifies that the line ends are anchored with a square.

LINE_CAP_ROUND_ANCHOR

4

Specifies that the line ends are anchored with a circle.

LINE_CAP_DIAMOND_ANCHOR

5

Specifies that the line ends are anchored with a diamond.

LINE_CAP_ARROW_ANCHOR

6

Specifies that the line ends are anchored with arrowheads.

nPositionLineLowCap

Type of cap for the low end of the position line.

Supported values are the same as seen for the nPositionLineHighCap field above.

nPositionLineDashCap

Type of dash/dot cap for the position line.

Supported values are the following:

Mnemonic constant

Value

Meaning

LINE_DASH_CAP_FLAT

0

Specifies a square cap that squares off both ends of each dash.

LINE_DASH_CAP_ROUND

1

Specifies a circular cap that rounds off both ends of each dash.

LINE_DASH_CAP_TRIANGLE

2

Specifies a triangular cap that points both ends of each dash.

nPositionLineTranspFactor

Transparent factor applied to the position line.

This value can range from 0 (total opacity) to 255 (total transparency). Values outside of this range will be automatically capped to the nearest valid value.

nGraphicItemsMask

Combination of values determining the mask of graphic items that must be drawn over the waveform scroller.

Supported values are the following:

Mnemonic constant

Value

Meaning

MASK_GRAPHIC_ITEM_NONE

0

No graphic item is drawn

MASK_GRAPHIC_ITEM_VERTICAL_LINE (default)

1

Draws vertical lines

MASK_GRAPHIC_ITEM_HORIZONTAL_LINE

2

Draws horizontal lines

MASK_GRAPHIC_ITEM_WAVE_RANGE

4

Draw wave ranges

nUpdateSpeed

Value that determines how much frequently the waveform is updated during playback. The higher the update speed, the higher the needed CPU amount.

Supported values are the following:

Mnemonic constant

Value

Meaning

WAVEFORMSCROLLER_UPDATE_ULTRA_FAST

0

.Update occurs every 15 milliseconds

WAVEFORMSCROLLER_UPDATE_VERY_FAST

1

.Update occurs every 30 milliseconds

WAVEFORMSCROLLER_UPDATE_FAST (default)

2

.Update occurs every 45 milliseconds

WAVEFORMSCROLLER_UPDATE_MIDDLE

3

.Update occurs every 60 milliseconds

WAVEFORMSCROLLER_UPDATE_SLOW

4

.Update occurs every 75 milliseconds

WAVEFORMSCROLLER_UPDATE_VERY_SLOW

5

.Update occurs every 90 milliseconds

WAVEFORMSCROLLER_UPDATE_ULTRA_SLOW

6

.Update occurs every 105 milliseconds

fVerticalZoomFactor

Factor applied to vertical zooming operations. can assume values ranging from 0.5 to 5. Values outside of this range will be automatically capped to the nearest valid value. The default value is set to 1.

- Values smaller than 1 will vertically zoom-out the waveform, reducing its vertical size

- Value 1 will display the waveform without zooming

- Values higher than 1 will vertically zoom-in the waveform, increasing its vertical size