Blender V4.3
DNA_sound_types.h
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2001-2002 NaN Holding BV. All rights reserved.
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
8#pragma once
9
10#include "DNA_ID.h"
11#include "DNA_defs.h"
12
13struct Ipo;
14struct PackedFile;
15
16typedef struct bSound {
18
23 char filepath[1024];
24
29
33 void *handle;
34
39 struct Ipo *ipo;
40
41 float volume;
43 float pitch;
44 float min_gain;
45 float max_gain;
46 float distance;
47 short flags;
49 short tags;
50 char _pad[4];
52
53 /* Unused currently. */
54 // int type;
55 // struct bSound *child_sound;
56
60 void *cache;
61
65 void *waveform;
66
72
74 void *spinlock;
75 /* XXX unused currently (SOUND_TYPE_LIMITER) */
76 // float start, end;
77
78 /* Description of Audio channels, as of #eSoundChannels. */
80
82
84
85/* XXX unused currently */
86#if 0
87typedef enum eSound_Type {
88 SOUND_TYPE_INVALID = -1,
89 SOUND_TYPE_FILE = 0,
90 SOUND_TYPE_BUFFER = 1,
91 SOUND_TYPE_LIMITER = 2,
92} eSound_Type;
93#endif
94
96enum {
97#ifdef DNA_DEPRECATED_ALLOW
98 /* deprecated! used for sound actuator loading */
99 SOUND_FLAGS_3D = (1 << 3),
100#endif
103};
104
106enum {
107 /* Do not free/reset waveform on sound load, only used by undo code. */
110};
ID and Library types, which are fundamental for SDNA.
struct bSound bSound
@ SOUND_FLAGS_MONO
@ SOUND_FLAGS_CACHING
@ SOUND_TAGS_WAVEFORM_LOADING
@ SOUND_TAGS_WAVEFORM_NO_RELOAD
Definition DNA_ID.h:413
void * playback_handle
struct PackedFile * packedfile
struct PackedFile * newpackedfile
char filepath[1024]
void * handle
struct Ipo * ipo
void * cache
float min_gain
void * spinlock
void * waveform
int audio_channels
short flags
char _pad[4]
float max_gain
float distance
float pitch
float attenuation
double offset_time
float volume