Xcode/SDLTest/TestDropFile-Info.plist
author Sam Lantinga <slouken@libsdl.org>
Tue, 25 Sep 2018 20:08:51 -0700
changeset 12224 0582b4e1fa9f
parent 8174 a8e60169b648
permissions -rw-r--r--
Fixed bug 4268 - Android_JNI_OpenAudioDevice function has error

alittle

where iscapture == 1

1.param set error

(*env)->CallStaticIntMethod(env, mAudioManagerClass, midCaptureOpen, sampleRate, audioBuffer16Bit, audioBufferStereo, desiredBufferFrames)

param:audioBuffer16Bit need change to captureBuffer16Bit

2.logic error

if (is16Bit) {
// ALITTLE Modify the source code
if (iscapture) {
audioBufferFrames = (*env)->GetArrayLength(env, (jshortArray)captureBuffer);
} else {
audioBufferPinned = (*env)->GetShortArrayElements(env, (jshortArray)audioBuffer, &isCopy);
audioBufferFrames = (*env)->GetArrayLength(env, (jshortArray)audioBuffer);
}
// if (!iscapture) {
// audioBufferPinned = (*env)->GetShortArrayElements(env, (jshortArray)audioBuffer, &isCopy);
// }
// audioBufferFrames = (*env)->GetArrayLength(env, (jshortArray)audioBuffer);
} else {
// ALITTLE Modify the source code
if (iscapture) {
audioBufferFrames = (*env)->GetArrayLength(env, (jbyteArray)captureBuffer);
} else {
audioBufferPinned = (*env)->GetByteArrayElements(env, (jbyteArray)audioBuffer, &isCopy);
audioBufferFrames = (*env)->GetArrayLength(env, (jbyteArray)audioBuffer);
}
// if (!iscapture) {
// audioBufferPinned = (*env)->GetByteArrayElements(env, (jbyteArray)audioBuffer, &isCopy);
// }
// audioBufferFrames = (*env)->GetArrayLength(env, (jbyteArray)audioBuffer);
}
     1 <?xml version="1.0" encoding="UTF-8"?>
     2 <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
     3 <plist version="1.0">
     4 <dict>
     5 	<key>CFBundleDevelopmentRegion</key>
     6 	<string>English</string>
     7 	<key>CFBundleDocumentTypes</key>
     8 	<array>
     9 		<dict>
    10 			<key>CFBundleTypeRole</key>
    11 			<string>Viewer</string>
    12 			<key>LSHandlerRank</key>
    13 			<string>Alternate</string>
    14 			<key>LSItemContentTypes</key>
    15 			<array>
    16 				<string>public.data</string>
    17 			</array>
    18 		</dict>
    19 	</array>
    20 	<key>CFBundleExecutable</key>
    21 	<string>${EXECUTABLE_NAME}</string>
    22 	<key>CFBundleIdentifier</key>
    23 	<string>org.libsdl.test-dropfile</string>
    24 	<key>CFBundleInfoDictionaryVersion</key>
    25 	<string>6.0</string>
    26 	<key>CFBundlePackageType</key>
    27 	<string>APPL</string>
    28 	<key>CFBundleShortVersionString</key>
    29 	<string>1.0</string>
    30 	<key>CFBundleVersion</key>
    31 	<string>1.0</string>
    32 	<key>LSMinimumSystemVersion</key>
    33 	<string>10.6</string>
    34 </dict>
    35 </plist>