public RESULT getGroup(int index, ref ChannelGroup group) { RESULT rESULT = RESULT.OK; IntPtr raw = IntPtr.Zero; try { rESULT = ChannelGroup.FMOD_ChannelGroup_GetGroup(channelgroupraw, index, ref raw); } catch { rESULT = RESULT.ERR_INVALID_PARAM; } RESULT result; if (rESULT != RESULT.OK) { result = rESULT; } else { if (group == null) { ChannelGroup channelGroup = new ChannelGroup(); channelGroup.setRaw(raw); group = channelGroup; } else { group.setRaw(raw); } result = rESULT; } return(result); }