This won't work for 2 reasons:

1. &(foo[0]) != foo.  i.e. you're creating a new pointer to foo[0], not the original pointer, so using (&buffer)[1] won't give you samples->pkt->data[1].  Passing samples->pkt->data to the sink works ofc.

2. If you're doing any conversion at all further up, I'm guessing that you no longer have a planar buffer (outcome from Convert() for example).

I suspect what is required is to pass in an array of pointers, so you'll need to create such an array at the start, copy the data content into it, and replace with other stuff in the Convert call.
```
uint8_t **planes = new uint8_t[num_planes];
for (int i = 0; i < num_planes; i++)
  planes[i] = samples->pkt->data[i];

if (NEED_CONVERT)
{ // update planes to point into m_convertBuffer?
}

m_sink->AddPackets(planes, maxFrames, written);
```