[TriEmbed] TriEmbed Digest, Vol 83, Issue 15

Pete Soper pete at soper.us
Wed Apr 22 10:45:22 CDT 2020


Well done, Jon!

-Pete

On 4/22/20 11:43 AM, Jon Wolfe via TriEmbed wrote:
>
> Also, since you’re defining the array at global scope, the size of it 
> must be a compile time const-expression anyways, so you wouldn’t even 
> need dynamic memory allocation.
>
> Vec3<unsigned char> framebuffer[imageWidth * imageHeight];
>
> would work., instead of using new. That also has the advantage that 
> the linker will more easily catch size overruns.
>
> *From: *Jon Wolfe via TriEmbed <mailto:triembed at triembed.org>
> *Sent: *Wednesday, April 22, 2020 11:36 AM
> *To: *Jon Wolfe via TriEmbed <mailto:triembed at triembed.org>
> *Subject: *Re: [TriEmbed] TriEmbed Digest, Vol 83, Issue 15
>
> I just realized something I’d overlooked.
>
> Your for loop **is** unexpected in your example, it’s outside of any 
> function.
>
> I just fired up the Arduino and tried my example template code (with 
> the for loop inside of Setup) , and it worked for me.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.triembed.org/pipermail/triembed_triembed.org/attachments/20200422/5cc5e508/attachment.htm>


More information about the TriEmbed mailing list