toojpeg icon indicating copy to clipboard operation
toojpeg copied to clipboard

How to use it in class.

Open promistrio opened this issue 3 years ago • 1 comments

How to do it if I want to write it in class variable? There is conflict with class member and WRITE_ONE_BYTE.

promistrio avatar Mar 31 '21 19:03 promistrio

I must add "this" and it causes an error. For example auto myOutput = [](unsigned char oneByte) { fputc(oneByte, output); }; but auto f = [this](unsigned char oneByte) { public_jpeg.push_back(oneByte); }; error: cannot convert ‘AirSimCamera::readAirsimCamera()::<lambda(unsigned char)>’ to ‘TooJpeg::WRITE_ONE_BYTE’ {aka ‘void (*)(unsigned char)’}

promistrio avatar Mar 31 '21 19:03 promistrio