Xonotic
Sound Class Reference
+ Inheritance diagram for Sound:
+ Collaboration diagram for Sound:

Public Member Functions

 ATTRIB (Sound, sound_str, string())
 
 ATTRIB (Sound, sound_str_, string)
 
 Sound ::Sound (string() path)
 
virtual void Sound ::sound_precache ()
 

Public Attributes

int m_id = 0
 

Detailed Description

Definition at line 119 of file sound.qh.

Member Function Documentation

◆ ATTRIB() [1/2]

Sound::ATTRIB ( Sound  ,
sound_str  ,
string()   
)

◆ ATTRIB() [2/2]

Sound::ATTRIB ( Sound  ,
sound_str_  ,
string   
)

◆ Sound ::Sound()

Sound::Sound ::Sound ( string()  path)
inline

Definition at line 123 of file sound.qh.

References CONSTRUCT.

124  {
125  CONSTRUCT(Sound);
126  this.sound_str = path;
127  }
#define CONSTRUCT(cname,...)
Definition: oo.qh:111
Definition: sound.qh:119

◆ Sound ::sound_precache()

virtual void Sound::Sound ::sound_precache ( )
inlinevirtual

Definition at line 128 of file sound.qh.

References _Sound_fixpath(), ENDCLASS, precache_sound(), strcpy, and TC.

129  {
130  TC(Sound, this);
131  string s = _Sound_fixpath(this.sound_str());
132  if (!s) return;
133  //profile(sprintf("precache_sound(\"%s\")", s));
134  precache_sound(s);
135  strcpy(this.sound_str_, s);
136  }
string _Sound_fixpath(string base)
Definition: sound.qh:94
#define strcpy(this, s)
Definition: string.qh:49
#define TC(T, sym)
Definition: _all.inc:82
Definition: sound.qh:119
+ Here is the call graph for this function:

Member Data Documentation

◆ m_id

int Sound::m_id = 0

Definition at line 120 of file sound.qh.


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