MCPcopy Create free account
hub / github.com/briankendall/proxy-audio-device / SetPropertyData

Method SetPropertyData

proxyAudioDevice/ProxyAudioDevice.cpp:1058–1163  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1056}
1057
1058OSStatus ProxyAudioDevice::SetPropertyData(AudioServerPlugInDriverRef inDriver,
1059 AudioObjectID inObjectID,
1060 pid_t inClientProcessID,
1061 const AudioObjectPropertyAddress *inAddress,
1062 UInt32 inQualifierDataSize,
1063 const void *inQualifierData,
1064 UInt32 inDataSize,
1065 const void *inData) {
1066 // declare the local variables
1067 OSStatus theAnswer = 0;
1068 UInt32 theNumberPropertiesChanged = 0;
1069 AudioObjectPropertyAddress theChangedAddresses[2];
1070
1071 // check the arguments
1072 FailWithAction(inDriver != gAudioServerPlugInDriverRef,
1073 theAnswer = kAudioHardwareBadObjectError,
1074 Done,
1075 "SetPropertyData: bad driver reference");
1076 FailWithAction(
1077 inAddress == NULL, theAnswer = kAudioHardwareIllegalOperationError, Done, "SetPropertyData: no address");
1078
1079 // Note that for each object, this driver implements all the required properties plus a few
1080 // extras that are useful but not required. There is more detailed commentary about each
1081 // property in the GetPropertyData() method.
1082 switch (inObjectID) {
1083 case kObjectID_PlugIn:
1084 theAnswer = SetPlugInPropertyData(inDriver,
1085 inObjectID,
1086 inClientProcessID,
1087 inAddress,
1088 inQualifierDataSize,
1089 inQualifierData,
1090 inDataSize,
1091 inData,
1092 &theNumberPropertiesChanged,
1093 theChangedAddresses);
1094 break;
1095
1096 case kObjectID_Box:
1097 theAnswer = SetBoxPropertyData(inDriver,
1098 inObjectID,
1099 inClientProcessID,
1100 inAddress,
1101 inQualifierDataSize,
1102 inQualifierData,
1103 inDataSize,
1104 inData,
1105 &theNumberPropertiesChanged,
1106 theChangedAddresses);
1107 break;
1108
1109 case kObjectID_Device:
1110 theAnswer = SetDevicePropertyData(inDriver,
1111 inObjectID,
1112 inClientProcessID,
1113 inAddress,
1114 inQualifierDataSize,
1115 inQualifierData,

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected