Closed samnied closed 4 years ago
So, this should be totally possible but it might be a little involved. Adding the sprite editor to a block is the easy part; you can see where the image editor block is defined for arcade here. The hard part is going to be porting over the Image class from arcade. That class is defined in the screen package.
You might be able to get away with just copying the definition of the image literal like this:
/**
* Tagged image literal converter
*/
//% shim=@f4
//% groups=["0.","1#","2T","3t","4N","5n","6G","7g","8","9","aAR","bBP","cCp","dDO","eEY","fFW"]
function img(lits: any, ...args: any[]): Buffer { return null }
But you'll need to parse the Buffer
that gets returned. @mmoskal is the image format documented somewhere? I saw the comment here.
@riknoll Many thanks for your help. Would it be possible to get in contact with you for some further questions ? samuel.niederer@hsr.ch
Feel free to ask them here!
Okey so our team isn't that experienced with the whole pxt environment and the time is running. We are looking for someone who could help us to port the whole editor, for a valuable consideration of course. I wondered if you or someone you know would be interested in doing that for us.
Sorry, I'm not available and I don't know of anyone offhand who might be able to help with this. I'm happy to answer any technical questions that come up in the process though!
We should refactor out the image API into a separate package that would be usable in microbit land...
The sprite editor would allow to draw images for neopixel matrices...
Won't fix for the next release.
I'm currently developing an extension for neopixel matrices with 16x16 pixels. There for I need an editor to enter colored pixel images.
As the makecode arcade environment provides a sprite editor with all the features I need, I'm looking for a way to port the sprite editor to the microbit environment (in the best way as an extension).
I already developed a few small extensions but nothing that "big". I would appreciate all kind of suggestions and hints on how to do it.
I already contacted a few developers, they told me to mention @riknoll.