ProjectSound class¶
Bases: pytvpaint.sound.BaseSound['Project']
A Project sound.
Source code in pytvpaint/sound.py
254 255 256 257 258 259 260 261 262 | |
project: Project
property
¶
The sound's project.
refresh_on_call = True
instance-attribute
¶
is_removed: bool
property
¶
Checks if the object is removed by trying to refresh its data.
Returns:
| Name | Type | Description |
|---|---|---|
bool |
bool
|
whether if it was removed or not |
track_index: int
property
¶
Get the soundtrack index in the sound stack.
Raises:
| Type | Description |
|---|---|
ValueError
|
if sound object no longer exists |
remove() -> None
¶
Remove the sound from the project.
Source code in pytvpaint/sound.py
287 288 289 290 291 | |
reload() -> None
¶
Reload the sound from file.
Source code in pytvpaint/sound.py
293 294 295 | |
make_current() -> None
¶
Makes the sound project current.
Source code in pytvpaint/sound.py
297 298 299 | |
refresh() -> None
¶
Refreshes the sound data.
Source code in pytvpaint/sound.py
83 84 85 86 87 88 | |
mark_removed() -> None
¶
Marks the object as removed and is therefor not usable.
Source code in pytvpaint/utils.py
98 99 100 | |
iter_sounds_data(parent_id: str | int) -> Iterator[george.TVPSound]
classmethod
¶
Returns an iterator over the sound's data.
Source code in pytvpaint/sound.py
66 67 68 69 | |
new(sound_path: Path | str, parent: P) -> Self
classmethod
¶
Create a new sound from the sound path.
Source code in pytvpaint/sound.py
75 76 77 78 79 80 81 | |
offset(value: float) -> None
¶
Source code in pytvpaint/sound.py
109 110 111 | |
volume(value: float) -> None
¶
Source code in pytvpaint/sound.py
118 119 120 121 | |
is_muted(value: bool) -> None
¶
Source code in pytvpaint/sound.py
128 129 130 131 | |
fade_in_start(value: float) -> None
¶
Source code in pytvpaint/sound.py
138 139 140 141 | |
fade_in_stop(value: float) -> None
¶
Source code in pytvpaint/sound.py
148 149 150 151 | |
fade_out_start(value: float) -> None
¶
Source code in pytvpaint/sound.py
158 159 160 161 | |
fade_out_stop(value: float) -> None
¶
Source code in pytvpaint/sound.py
168 169 170 171 | |
path() -> Path
¶
The sound source file path.
Source code in pytvpaint/sound.py
173 174 175 176 | |
sound_in() -> float
¶
The start time of the sound.
Source code in pytvpaint/sound.py
178 179 180 181 | |
sound_out() -> float
¶
The end time of the sound.
Source code in pytvpaint/sound.py
183 184 185 186 | |
color_index(value: int) -> None
¶
Source code in pytvpaint/sound.py
193 194 195 196 | |