dmBuffer::GetStream parameters may be null (DEF-3076) (SOLVED)

In last update, parameters was added to GetStream function

This will not work.(dmengine not responce)

dmBuffer::Result r = dmBuffer::GetStream(hBuffer, dmHashString64("rgb"), (void**)&STREAM, &size_ignored, NULL, NULL);

This work.

dmBuffer::GetStream(hBuffer, dmHashString64("rgb"), (void**)&STREAM, &size_ignored, &components, &stride);

So what about may be null?

may be null, it is about result? not about pointer?

You are right, that is a bug. I’ve added DEF-3076 for this, and I expect it to be fixed in the next release.
In the mean time, do as you do right now, store the values in a temp variable.

3 Likes

Fixed in Defold 1.2.120

1 Like