Iced, a cross-platform GUI library — New release featuring canvas interactivity, overlay support, a renderer alternative, and more! github.com/hecrj/iced/pul…
👍︎ 533
📰︎ r/rust
💬︎
👤︎ u/hecrj
📅︎ Nov 26 2020
🚨︎ report
Simplest cross-platform canvas gui lib?

Hey Gophers,

I'm getting back at doing some cg images (fractals, flam3, attractors, raytracing, etc...) as a hobby, and I would like to use a simple window for displaying purposes instead of blindly generating images to disk and then checking the result, it will make debugging and playing way easier.

I'm in need of a very simple (small and fast) library to display a window and have access to any form of setPixel(x, y, color) within that window. This usually come in 2D gaming libraries or as canvas widgets on GUI libraries, but as a backend developer I have not played with those in a long time.

My only needs are:

  • Simple and fast (the smaller the better I don't need a lot of features)
  • Being able to read/write from the canvas or frame buffer in a window
  • Cross platform (I do work in windows/linux/mac depending on time and place and I want to be able to grab 10-15 min for this wherever I am)
  • I don't mind cgo or external dependencies, dynamic libraries, etc... but less is more, pure Go > c bindings
  • Maintained and supported

From googling around and checking awesome-go I found some possible candidates, but I have found the community always gives the best non-biased advice (usually) when it comes to recommendations.

Right now I'm thinking of using fyne as it checks most of my needs, but I'm leaning towards going back to using GLFW just because its battle tested and it's kinda familiar. One thing worth mentioning is that some of the CG images are CPU heavy and heavily multithreaded, so keeping the main window thread snappy and responsive while the rest of the routines do the heavy lifting is a must.

Thoughts? Recommendations?

Edit: For now I'm using pixel (https://github.com/faiface/pixel)! Seems small and portable enough (and uses GLFW as the OpenGL backend), but I will try other suggestions. Also attached simple DeJong attractors animation I produced with it, I'm looking at some better (and performant) coloring functions to go with it, this is just logarithmic density, but looks good enough for a test and runs fast.

DeJong Attractors

👍︎ 3
📰︎ r/golang
💬︎
👤︎ u/guesdo
📅︎ Dec 13 2020
🚨︎ report
Canvas has a new update! with a new GUI and support for Video, Image sequences and alpha!
👍︎ 2
📰︎ r/Cinema4D
💬︎
👤︎ u/mattcrom15
📅︎ Sep 02 2020
🚨︎ report
Can we shit on Canvas every now and then? Their GUI is pretty shit. At least indicate in some way that I have completed a quiz, would be so much more helpful than continuously going back and forth between tabs.
👍︎ 47
📰︎ r/UCSD
💬︎
👤︎ u/useesd
📅︎ Mar 30 2020
🚨︎ report
Canvas, the website most US schools use, has the worst GUI for viewing PDFs. It's only 1/3 of the screen, has 2 scroll bars for a single file, and can not be expanded. It's been like this for years.
👍︎ 8
💬︎
👤︎ u/useesd
📅︎ Mar 30 2020
🚨︎ report
Hi, how do I put a canvas on another canvas? I have tried this below but it has not worked. pictures of Gui attached.
#lang racket/gui


(define bcg (read-bitmap "C:/Users/black/Desktop/Uni block 2 project/background.png"))
(define bcg2 (read-bitmap "C:/Users/black/Desktop/Uni block 2 project/bcg.png"))
(define logo (read-bitmap "C:/Users/black/Desktop/Uni block 2 project/logo.jpg"))
(define aatylw (read-bitmap "C:/Users/black/Desktop/Uni block 2 project/aatyellow2.png"))
(define aatgreen (read-bitmap "C:/Users/black/Desktop/Uni block 2 project/aatgreen.png"))
(define aatblue (read-bitmap "C:/Users/black/Desktop/Uni block 2 project/aatblue2.png"))
(define aatred (read-bitmap "C:/Users/black/Desktop/Uni block 2 project/aatred2.jpg"))

(define frame (new frame%
                   (width 600) (height 337)
                   (label "Tank Wars: The Last Tankwalker")
                   ))


(define rulepage (new frame%
                      (width 300) (height 100)
                      (label "Tank Wars: Rules of the Game")
                      (stretchable-height #f)))

(define rulepanel (new horizontal-panel%
     (parent rulepage)
     (min-height 300) (min-width 100)
     [stretchable-height #f]
     [stretchable-width #f]
(alignment '(center center))))

  (new message%
                   (parent rulepanel)
                   (min-height 100)
                   (min-width 300)
                   (vert-margin 100)
                   (label "Tank Trouble is tank game where you drive in a maze and shoot missiles at your enemies.
Player 1 plays with WASD-keys for driving and Q for shooting. Player 2 uses the
arrow keys and space."))

(define backbtn (new button%
                     (parent rulepage)
                     (label "Back to Main Menu")
                     (callback (λ (button event)
                                 (and (send rulepage show #f) (send frame show #t))))))

(define gamebtn (new button%
                     (parent rulepage)
                     (label "Start the Game")
                     (callback (λ (button event)
                                 (and (send rulepage show #f) (send frame2 show #t))))))

(define frame2 (new frame%
                    (width 600) (height 600)
                    (label "Tank Wars: The Last Chooseyourplayerwalker")))

(define panel (new vertical-panel%
                   (parent frame)))
... keep reading on reddit ➡

👍︎ 7
📰︎ r/Racket
💬︎
👤︎ u/CaptainCurry2
📅︎ Feb 10 2020
🚨︎ report
How does a professional code make GUIs in HTML5 Canvas?

I'm starting making some web games with HTML5 Canvas, and I have done pretty good so far on my first game. I now need to make a popup GUI, and instead of making a bunch of dumb inefficient code, I thought I'd ask the pros. How do you make GUIs?

EDIT: Sorry for the title, I meant coder.

👍︎ 4
📰︎ r/html5games
💬︎
👤︎ u/MadScientist2854
📅︎ May 22 2018
🚨︎ report
how to go about hiding gui components on the canvas?

disabling the gameobjects themselves is not an option as i need to keep their behavior running, i only want to hide them from view but culling doesnt seem to work for it

👍︎ 2
📰︎ r/Unity3D
💬︎
👤︎ u/CerealCoding
📅︎ Mar 18 2016
🚨︎ report
Which GUI library has the best canvas/drawing support?

I'm looking to get something up and running kind of quick, with the ability to add more features down the line. I've dealt with Tkinter but nothing else, and have never dealt with canvas/drawing widgets in any regard.

Learning isn't the issue, but being able to 1) Get a quick prototype and 2) Easily adding more features (layers? Masking? Grid lines? Cursor snap?) are priorities.

Ninja edit: I consider myself pretty advanced in Python usage, but pretty mediocre when it comes to GUI stuff. Almost everything I've done has been either a command line tool or django related.

I'm fine working in Python 2 and 3 but I doubt that will matter.

👍︎ 7
📰︎ r/learnpython
💬︎
👤︎ u/aqua_scummm
📅︎ Jun 24 2014
🚨︎ report
Depth of Field effect and the GUI Canvas (x-post from unity3d)

Hi guys, i need some help here. What i wish to make is something like in this picture: http://i.imgur.com/OzInBdy.jpg The first image is an example of the gui, and the second image is the effect i want when the gui is overlaped by the window that appears. I thought i could create this effect simply by tweking the depth of field effect on the camera, but aparently i can't. I'm guessing it has something to do with the way the canvas is rendered preventing what i want to achieve. Now i'm not sure how to aproach this, if it's possible at all.

👍︎ 3
📰︎ r/Unity2D
💬︎
👤︎ u/TitoOliveira
📅︎ Jul 02 2015
🚨︎ report
With the new gui canvas, how do you do this? (will explain more)

I have a switch statement with 5 different cases and each case displays a slightly different menu. in each case theres 3 buttons that are the same no matter what but they will be a different height position depending on which case they are.. Then depending on which case it is if its case 1 then there will be a fourth menu button.. if there is case 2 then 5 menu buttons.

How do I do this in new canvas system? It was easy to do in old way of writing the gui in the code.

👍︎ 3
📰︎ r/Unity3D
💬︎
👤︎ u/mygudnesmiya
📅︎ Jan 09 2015
🚨︎ report
Automatically enable / disable GUI Canvas when entering / exiting playmode gist.github.com/karl-/fbb…
👍︎ 3
📰︎ r/Unity3D
💬︎
👤︎ u/fry_
📅︎ Jun 03 2015
🚨︎ report
Canvas-based GUI Input

Hi, I am trying to implement a GUI for my game entirely from scratch (no Swing except for the Canvas). So far I have implemented the rendering of 4 basic elements (Label, button, text field, and a selection element). I can't figure out how to properly handle inputs though. I know I can use keyboard listeners, etc..., but I can't find a good way to do it.

👍︎ 5
📰︎ r/java
💬︎
👤︎ u/novasharp
📅︎ Feb 08 2013
🚨︎ report
Rust renderer into a GUI applications canvas (with glium)

Imagine the following, written in another language (e.g. C#/WinForms), user interface: http://i.imgur.com/bBzl5Tr.png

Could I make the canvas renderer be Rust code (.dll/.so) using glium? I'm worried about glium being a context owner... I would not like to own the canvas. The main application could use the canvas for whatever purposes when it's not drawing with the Rust library, even use another library.

For instance, there's a library for rendering format X (with Rust) and another for format Y, the main app just gives the filename to the library and on each tick asks for that library to render the data on the canvas. The main application may be even responsible for rendering format Z.

👍︎ 4
📰︎ r/rust_gamedev
💬︎
👤︎ u/thelink2012
📅︎ Jul 27 2015
🚨︎ report
Unity - Canvas GUI Text invert

Hello guys,

I have a partially transparent canvas element in world space attached with various text/panel and other things provided by unity do develop UIs.

My problem is that when the player walks behind the UI the text is backwards. Obviously the easiest fix would be a collider that flips the text, but that is dodgy as sometimes the player could step towards the UI activate the collider and then move back and the text would be flipped.

I was wondering if any of you guys had a simple way to do this, I was thinking of using a vector to detect which side of the canvas the player is on then flip it based on that. But I'm not too sure how to implement it properly.

Any help would be appreciated, thanks.

👍︎ 2
📰︎ r/Unity3D
💬︎
👤︎ u/VGMTaylor
📅︎ Sep 10 2015
🚨︎ report
Ask web_design: Please recommend a free drawing GUI tool that exports to HTML5 canvas

I do not need advanced graphics but more for flowcharts and the like (so simple shapes, text, connectors etc). As an example, xfig is an awesome tool for this, but it only exports to SVG, not canvas.

👍︎ 2
📰︎ r/web_design
💬︎
👤︎ u/chengiz
📅︎ Feb 04 2012
🚨︎ report
The early beginnings of my Canvas GUI kipdola.be/subdomain/duk-…
👍︎ 9
📰︎ r/html5
💬︎
👤︎ u/skerit
📅︎ May 15 2011
🚨︎ report
Depth of Field effect and the GUI Canvas

Hi guys, i need some help here. What i wish to make is something like in this picture: http://i.imgur.com/OzInBdy.jpg

The first image is an example of the gui, and the second image is the effect i want when the gui is overlaped by the window that appears.

I thought i could create this effect simply by tweking the depth of field effect on the camera, but aparently i can't. I'm guessing it has something to do with the way the canvas is rendered preventing what i want to achieve.

Now i'm not sure how to aproach this, if it's possible at all.

👍︎ 2
📰︎ r/Unity3D
💬︎
👤︎ u/TitoOliveira
📅︎ Jul 01 2015
🚨︎ report

Please note that this site uses cookies to personalise content and adverts, to provide social media features, and to analyse web traffic. Click here for more information.