https://linen.dev logo
Join Discord
Powered by
# haxe-ui
  • b

    bright-gpu-74537

    02/07/2023, 10:33 AM
    thats interesting, i doubt very much the wxDC api can do that (or anything close)
  • o

    orange-van-60470

    02/07/2023, 10:33 AM
    well currently have too tweak RGBA mode and change a few js.lib.UInt8Array references
  • b

    bright-gpu-74537

    02/07/2023, 10:33 AM
    so it just spits out a byte array?
  • o

    orange-van-60470

    02/07/2023, 10:33 AM
    yes!
  • o

    orange-van-60470

    02/07/2023, 10:34 AM
    well it is all stored as UInt32Array so there are some Int aspects with 32bit that may occasionally be annoying
  • o

    orange-van-60470

    02/07/2023, 10:35 AM
    but certainly for canvas not seen much only when I tried playing with base12
  • o

    orange-van-60470

    02/07/2023, 10:36 AM
    but think UInt32Array maybe byteArray internally
  • o

    orange-van-60470

    02/07/2023, 10:36 AM
    for c++
  • b

    bright-gpu-74537

    02/07/2023, 10:36 AM
    why not just haxe.Bytes?
  • o

    orange-van-60470

    02/07/2023, 10:37 AM
    well could potentiall modify it to allow user selection.
  • o

    orange-van-60470

    02/07/2023, 10:37 AM
    as there are only a few get set methods
  • o

    orange-van-60470

    02/07/2023, 10:37 AM
    I can't remember at mo why I choose haxe.ds.UInt32Array
  • o

    orange-van-60470

    02/07/2023, 10:38 AM
    I know it was kind of messy to get the UInt8Array view so I just hacked in some js
  • o

    orange-van-60470

    02/07/2023, 10:38 AM
    which is what I need to fix for occasional channel access
  • b

    bright-gpu-74537

    02/07/2023, 10:38 AM
    well, i guess what you would need to do, is get a PoC going that would spit out some bytes that hxWidgets could consume and paint onto a device context (with blit or something)
  • o

    orange-van-60470

    02/07/2023, 10:39 AM
    well it can do smooth edges a bit
  • o

    orange-van-60470

    02/07/2023, 10:41 AM
    well no blit needed... you only draw to the context when you need an update rest is all done with pixelimages, you can use transparent ( alpha blend ) or non ( overwrite pixel )
  • b

    bright-gpu-74537

    02/07/2023, 10:41 AM
    well, but im not sure you can get the raw buffer data from a device context
  • o

    orange-van-60470

    02/07/2023, 10:42 AM
    just draw to an image
  • o

    orange-van-60470

    02/07/2023, 10:42 AM
    probably
  • b

    bright-gpu-74537

    02/07/2023, 10:42 AM
    maybe...
  • b

    bright-gpu-74537

    02/07/2023, 10:42 AM
    i think i added some code to hxwidgets to allow for that a while ago actully
  • o

    orange-van-60470

    02/07/2023, 10:43 AM
    well I draw from html images to canvas to pixelimage render on pixelshapes and draw to canvas
  • o

    orange-van-60470

    02/07/2023, 10:44 AM
    because I am lazy and don't like a server for js I 64 bit encode the images
  • b

    bright-gpu-74537

    02/07/2023, 10:44 AM
    yeah, there are helper functions i added to wxImage to work with its raw data: https://github.com/haxeui/hxWidgets/blob/master/src/hx/widgets/Image.hx
  • o

    orange-van-60470

    02/07/2023, 10:45 AM
    so this is an image drawn to two triangles ( a quad ).
  • o

    orange-van-60470

    02/07/2023, 10:46 AM
    so it is a png image I am using
  • b

    bright-gpu-74537

    02/07/2023, 10:47 AM
    OK, but is this also outputing a byte array, on say, c++?
  • o

    orange-van-60470

    02/07/2023, 10:47 AM
    and I base64 to avoid loading at runtime and having to have a server for testing like lime has to
  • o

    orange-van-60470

    02/07/2023, 10:48 AM
1...147414751476...1687Latest