processing / processing/processing4

Cursor translucency problem?

Abierto
#814 1 comentario 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

bug core has attachment
Lenguaje dominante
Java
Estrellas
494
Forks
183
Merge medio
4 h 39 min
PR fusionados (30 d)
3

Descripción

Created by: lenrik1589

Description

Inconsistent blending of cursor image when using translucency in the image

Expected Behavior

Using cursor(img, x, y) and exporting the image and using it with X should produce same visual result

Current Behavior

System:
Screenshot_20231219_125123
Screenshot_20231219_125452
P2D:
(colored sections are 100/255 alpha) Screenshot_20231219_125105
(colored sections are 10/255 alpha) Screenshot_20231219_125427

Steps to Reproduce

  1. create image with translucency
  2. apply using cursor(img, x, y)
  3. observe how translucent colors interact with the backdrop
  4. export the image.save(file)
  5. create left_ptr using xcursorgen
  6. import as a cursor into the system and apply
  7. observe as cursor now blends differently with the background

(might include code a little later, when come home)

Your Environment

  • Processing version: 4.3 (imported through gradle as implementation("com.github.micycle1:processing-core-4:4.+"))
  • Operating System and OS version: Linux (gemeric arch, kernel 6.6.7)
  • Other information:
    • Wayland Plasma 6.0 Beta 1
    • kwin 5.90.0
    • Xwayland 23.2.3-1
    • mesa 23.3.1
    • Java: 21

Note: the discrepancy existed even when i was using a native x11 session with stable Plasma 5 and processing 3.5 in the processing editor

IIRC there might be a workaround, of using a different renderer, but i can not use it as i found no way to consistently resize a window after initialization or programmatically close other windows (produced by the same program but different PApplet) with anything other than P2D or P3D as i currently use reflection to gain access internal resize method and ((PSurfaceJOGL)surface).finish() ((GLWindow)surface.native).dispose() to close windows

(the older version of description
particularly,
i am running into issue that using P2D (xwayland + opengl) as the renderer for all my sketch windows and other graphics, my custom cursor (using cursor(img, hotspotX, hotspotY)) seems to render incorrectly compared to cursor theme made by exporting the same images as png files, and assembling into a xcursor image to be used with the system
)

Possible Causes / Solutions

It might be a discrepancy between how OpenGL and KWin handle cursors

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Línea de trabajo

Empieza reproduciendo el problema con Processing 4.3, el renderizador P2D y cursor(img, x, y) en el entorno Linux indicado. Compara el cursor translúcido con la imagen exportada ensamblada mediante xcursorgen, incluidos los distintos ejemplos de alpha. Se considera terminado cuando el cursor dentro del sketch y el cursor del sistema se mezclan de forma coherente con el fondo.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
java
Área
computer-graphics, desktop
Tipo de issue
Error
Dificultad
4/5
Tiempo estimado
3-5 días
Estado de actividad
Estancado
Claridad
Necesita aclaración
Aptitud para principiantes
25/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.