public RESULT getChannelGroup (ref ChannelGroup channelgroup) { RESULT result = RESULT.OK; IntPtr channelgroupraw = new IntPtr(); ChannelGroup channelgroupnew = null; try { result = FMOD_Channel_GetChannelGroup(channelraw, ref channelgroupraw); } catch { result = RESULT.ERR_INVALID_PARAM; } if (result != RESULT.OK) { return result; } if (channelgroup == null) { channelgroupnew = new ChannelGroup(); channelgroupnew.setRaw(channelgroupraw); channelgroup = channelgroupnew; } else { channelgroup.setRaw(channelgroupraw); } return result; }
public RESULT createChannelGroup (string name, ref ChannelGroup channelgroup) { RESULT result = RESULT.OK; IntPtr channelgroupraw = new IntPtr(); ChannelGroup channelgroupnew = null; try { result = FMOD_System_CreateChannelGroup(systemraw, name, ref channelgroupraw); } catch { result = RESULT.ERR_INVALID_PARAM; } if (result != RESULT.OK) { return result; } if (channelgroup == null) { channelgroupnew = new ChannelGroup(); channelgroupnew.setRaw(channelgroupraw); channelgroup = channelgroupnew; } else { channelgroup.setRaw(channelgroupraw); } return result; }