Borrar filtros
Borrar filtros

bwlabel with Matlab coder

1 visualización (últimos 30 días)
Alex Zlotnik
Alex Zlotnik el 30 de Abr. de 2015
Respondida: Sainath Varikuti el 1 de Mayo de 2015
I am trying to convert matlab code to C++ using Matlab Coder. The memory is set not to use dynamic allocation. It fails to convert the function bwlabel , stating the function has some unbounded variables inside, and cannot be converted with static allocation.
Does bwlabel demand dynamic memory allocation, or I could have some other bug in my code?

Respuestas (1)

Sainath Varikuti
Sainath Varikuti el 1 de Mayo de 2015
When generating code for 'bwlabel', the parameter 'n' must be compile time constant as discussed here. Try specifying the upper bound using 'code.varsize' or 'assert' statement in the MATLAB code.

Categorías

Más información sobre MATLAB Coder en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by