Task that plays one narration stream of a StreamQueue.
More...
#include <streamtask.h>
|
| | ~StreamTask () override=default |
| | Destroy the object.
|
| | StreamTask (const char *pszName, const char *pszDirectory) |
| | Construct a task for a stream file.
|
| void | SetWaitingTask (Task *pTask) |
| | Set the task that learns when the stream is done.
|
| void | SetPaused (bool bPaused) |
| | Pause or resume the stream.
|
| const char * | GetName () const |
| StreamPlayer * | GetPlayer () const |
| | Task () |
| | Construct an idle task.
|
| virtual | ~Task () |
| | Release the task.
|
| int | Poll () |
| | Report the state after giving a running task one poll.
|
| void | Start () |
| | Enter the running state and call OnStart(), unless the task is already running.
|
| void | Stop () |
| | Call OnStop() when the task is running, and return to the idle state.
|
| void | Finish (bool bSucceeded) |
| | End the task from outside its poll, and call OnStop() when it was running.
|
| int | GetState () const |
| | Report mState.
|
|
| void | OnStart () override |
| | Open the stream file and give it to the sound output to play.
|
| void | OnStop () override |
| | Stop the stream and release it.
|
| void | OnPoll () override |
| | Once the stream has ended, release it, finish the task, and report to the waiting task.
|
Task that plays one narration stream of a StreamQueue.
The RTTI includes the class name and records Task as the base. The task is done once the stream has played to its end, and it then reports to the task waiting for the stream, if any.
◆ ~StreamTask()
| StreamTask::~StreamTask |
( |
| ) |
|
|
overridedefault |
Destroy the object.
- Ghidra address:
- NTSC-U/C: 0x00344028
- Ghidra address:
- PAL: 0x003b1560
◆ StreamTask()
| StreamTask::StreamTask |
( |
const char * | pszName, |
|
|
const char * | pszDirectory ) |
Construct a task for a stream file.
The task records the pointers and does not copy the text.
- Parameters
-
| pszName | The stream name, the file name within the directory. |
| pszDirectory | The directory the stream file is read from. |
- Ghidra address:
- NTSC-U/C: 0x001416a0
- Ghidra address:
- PAL: 0x00143060
◆ SetWaitingTask()
| void StreamTask::SetWaitingTask |
( |
Task * | pTask | ) |
|
Set the task that learns when the stream is done.
- Parameters
-
- Ghidra address:
- NTSC-U/C: 0x001416c8
- Ghidra address:
- PAL: 0x00143088
◆ SetPaused()
| void StreamTask::SetPaused |
( |
bool | bPaused | ) |
|
Pause or resume the stream.
- Parameters
-
- Ghidra address:
- NTSC-U/C: 0x001417f0
- Ghidra address:
- PAL: 0x00143190
◆ GetName()
| const char * StreamTask::GetName |
( |
| ) |
const |
|
inline |
◆ GetPlayer()
- Returns
- The playing stream, or null.
◆ OnStart()
| void StreamTask::OnStart |
( |
| ) |
|
|
overrideprotectedvirtual |
Open the stream file and give it to the sound output to play.
- Ghidra address:
- NTSC-U/C: 0x001416d0
- Ghidra address:
- PAL: 0x00143090
Reimplemented from Task.
◆ OnStop()
| void StreamTask::OnStop |
( |
| ) |
|
|
overrideprotectedvirtual |
Stop the stream and release it.
- Ghidra address:
- NTSC-U/C: 0x00141780
- Ghidra address:
- PAL: 0x00143120
Reimplemented from Task.
◆ OnPoll()
| void StreamTask::OnPoll |
( |
| ) |
|
|
overrideprotectedvirtual |
Once the stream has ended, release it, finish the task, and report to the waiting task.
- Ghidra address:
- NTSC-U/C: 0x00141810
- Ghidra address:
- PAL: 0x001431b0
Reimplemented from Task.
The documentation for this class was generated from the following file: