rem: TRACE(("flags = %#x\n",data->flags)); TRACE(("request_playback_buffers = %#x\n",data->request_playback_buffers)); TRACE(("request_playback_channels = %#x\n",data->request_playback_channels)); TRACE(("request_playback_buffer_size = %#x\n",data->request_playback_buffer_size)); TRACE(("request_record_buffers = %#x\n",data->request_record_buffers)); TRACE(("request_record_channels = %#x\n",data->request_record_channels)); TRACE(("request_record_buffer_size = %#x\n",data->request_record_buffer_size));
add: LOG(("flags = %#x\n",data->flags)); LOG(("request_playback_buffers = %#x\n",data->request_playback_buffers)); LOG(("request_playback_channels = %#x\n",data->request_playback_channels)); LOG(("request_playback_buffer_size = %#x\n",data->request_playback_buffer_size)); LOG(("request_record_buffers = %#x\n",data->request_record_buffers)); LOG(("request_record_channels = %#x\n",data->request_record_channels)); LOG(("request_record_buffer_size = %#x\n",data->request_record_buffer_size));
context: static status_t get_buffers(multi_buffer_list *data){	TRACE(("flags = %#x\n",data->flags));	TRACE(("request_playback_buffers = %#x\n",data->request_playback_buffers));	TRACE(("request_playback_channels = %#x\n",data->request_playback_channels));	TRACE(("request_playback_buffer_size = %#x\n",data->request_playback_buffer_size));	TRACE(("request_record_buffers = %#x\n",data->request_record_buffers));	TRACE(("request_record_channels = %#x\n",data->request_record_channels));	TRACE(("request_record_buffer_size = %#x\n",data->request_record_buffer_size));	if (data->request_playback_buffers < 2 ||		data->request_playback_channels < 2 ||		data->request_record_buffers < 2 ||		data->request_record_channels < 2) {		TRACE(("not enough channels/buffers\n"));	}	ASSERT(BUFFER_COUNT == 2);	//	data->flags = B_MULTI_BUFFER_PLAYBACK | B_MULTI_BUFFER_RECORD; // XXX ???	data->flags = 0;		data->return_playback_buffers = 2;			/* playback_buffers[b][] */	data->return_playback_channels = 2;			/* playback_buffers[][c] */	data->return_playback_buffer_size = BUFFER_SIZE / 4;		/* frames */	/* buffer 0, left channel */	data->playback_buffers[0][0].base = chan_po->userbuffer[0]; /* pointer to first sample for channel for buffer */	data->playback_buffers[0][0].stride = 4; /* offset to next sample */	/* buffer 0, right channel */	data->playback_buffers[0][1].base = ((char*)chan_po->userbuffer[0]) + 2; /* pointer to first sample for channel for buffer */	data->playback_buffers[0][1].stride = 4; /* offset to next sample */	/* buffer 1, left channel */	data->playback_buffers[1][0].base = chan_po->userbuffer[1]; /* pointer to first sample for channel for buffer */	data->playback_buffers[1][0].stride = 4; /* offset to next sample */	/* buffer 1, right channel */	data->playback_buffers[1][1].base = ((char*)chan_po->userbuffer[1]) + 2; /* pointer to first sample for channel for buffer */	data->playback_buffers[1][1].stride = 4; /* offset to next sample */		data->return_record_buffers = 2;	data->return_record_channels = 2;	data->return_record_buffer_size = BUFFER_SIZE / 4;			/* frames */	/* buffer 0, left channel */	data->record_buffers[0][0].base = chan_pi->userbuffer[0]; /* pointer to first sample for channel for buffer */	data->record_buffers[0][0].stride = 4; /* offset to next sample */	/* buffer 0, right channel */	data->record_buffers[0][1].base = ((char*)chan_pi->userbuffer[0]) + 2; /* pointer to first sample for channel for buffer */	data->record_buffers[0][1].stride = 4; /* offset to next sample */	/* buffer 1, left channel */	data->record_buffers[1][0].base = chan_pi->userbuffer[1]; /* pointer to first sample for channel for buffer */	data->record_buffers[1][0].stride = 4; /* offset to next sample */	/* buffer 1, right channel */	data->record_buffers[1][1].base = ((char*)chan_pi->userbuffer[1]) + 2; /* pointer to first sample for channel for buffer */	data->record_buffers[1][1].stride = 4; /* offset to next sample */	return B_OK;}