modules: camera: Write back stream parameters
max_buffers and usage are read by the framework inside the struct used
to pass the stream configuration parameters; scribble our new
calculated values whever they are updated internally.
Adds logging to stream creation method (reuse/new).
Change-Id: I04e12880820571900f2ae80c27100f8aedcf9d02
diff --git a/modules/camera/Camera.cpp b/modules/camera/Camera.cpp
index 42e5cdb..137c5f6 100644
--- a/modules/camera/Camera.cpp
+++ b/modules/camera/Camera.cpp
@@ -326,10 +326,13 @@
// Fill new stream array with reused streams and new streams
for (unsigned int i = 0; i < stream_config->num_streams; i++) {
astream = stream_config->streams[i];
- if (astream->max_buffers > 0)
+ if (astream->max_buffers > 0) {
+ ALOGV("%s:%d: Reusing stream %d", __func__, mId, i);
newStreams[i] = reuseStream(astream);
- else
+ } else {
+ ALOGV("%s:%d: Creating new stream %d", __func__, mId, i);
newStreams[i] = new Stream(mId, astream);
+ }
if (newStreams[i] == NULL) {
ALOGE("%s:%d: Error processing stream %d", __func__, mId, i);