Questions tagged [pixmap]

123 questions
3
votes
1 answer

Generating textures at runtime with text using libgdx

I'm working on a phone word game. Yesterday I decided to switch to OpenGL using libgdx to try and improve graphics performance and battery usage + to target more platforms. The way letter tile drawing was working on a 2D canvas was each letter tile…
Will Calderwood
  • 4,393
  • 3
  • 39
  • 64
3
votes
1 answer

Libgdx Pixmap and getFrameBufferPixels

I wonder know how to get the FrameBufferPixel in a Pixmap I know I must use getFrameBufferPixels(true) But I don't know what parameters to put in new Pixmap(byte[] encodedData, int offset, int len); Can you show me an exemple who should works…
LeSam
  • 1,235
  • 4
  • 18
  • 38
3
votes
2 answers

Android LibGDX Pixmap issue

I'm developing a game for Android using libGDX. I implemented "spotlight effect" for highlighting some scene elements in tutorial levels. I did use Pixmap class for implementing this. So I did something like this: public class ComplexSpotlight…
Viacheslav
  • 5,443
  • 1
  • 29
  • 36
2
votes
1 answer

Drawing a graphic with a transparent color using xlib

Using Xlib: I'm trying to display a pixmap with a transparent colour (color). That is a colour that will show the background. Currently drawing the pixmap completely opaque using XCopyArea (). How can I make this transparent (to work like…
2
votes
0 answers

how to add an image as a struct using pixmap in racket

I created an image in a file: (define zero-zero (add-curve (rectangle 35 60 "solid" "white") 0 30 0 0 36 30 0 0 "black")) I renamed it in a new file as a…
2
votes
2 answers

QGraphicsView - slow scale performance under Linux

I'm making a program that will display a few images from a directory beside each other. When I scale the images to fit within the height of the window (ie - QGraphicsPixmapItem->scale(...)), it runs fairly well in windows, but runs unbearably slow…
jdrea
  • 53
  • 4
2
votes
1 answer

Drawing text onto a Pixmap (LibGDX)

I am trying to make a "Share Score" button in my game. Part of what I want to do as part of the score sharing is create a little graphic that has the game logo along with the user's score. This graphic will then be shared via whatever platform the…
Samuel M
  • 51
  • 1
  • 9
2
votes
1 answer

draw icon with transparency in xlib and cairo

Now that I've got the icons I want to draw them correctly. At the moment I'm using Cairo to draw these images on a window. I have a mask and the icon as pixmap. cairo_surface_t *image; cairo_surface_t *imask; cairo_surface_t *surface; cairo_t…
dersaft
  • 75
  • 5
2
votes
1 answer

Use a QPixmap as OpenGL texture

I am writing a qt code in c++, including some openQL graphics (QGLWidget).I would like to assign a QPixmap as texture to an openGL quad. Is this possible ?
Laurent Crivello
  • 3,809
  • 6
  • 45
  • 89
2
votes
1 answer

How to rotate a pixmap by 90º to draw to a texture in libgdx?

I need to rotate a Pixmap by 90 degrees. I have seen an answer that achieves a flipped Pixmap. I need to rotate images that are in portrait orientation to landscape already on the Pixmap-level to later create textures out of them.
donfuxx
  • 11,277
  • 6
  • 44
  • 76
2
votes
0 answers

libGDX: can't load pixmap from mounted OBB file

I'm instantiating a Pixmap from a FileHandle that points to a png file in an OBB file from Google's APK Expansion Library, mounted using StorageManager. The OBB file is encrypted. This works fine on devices I tested running Android 5.1 and 4.3…
AxiomaticNexus
  • 6,190
  • 3
  • 41
  • 61
2
votes
1 answer

Fast plotting with pixmap or bitmap in Qt

I need fast plotting widget in Qt, but I don't want to use anything prepared. I have some float data, for example QVector< float > data, and I need to paint it on widget. But I don't want use paintEvent and QPainter directly on it. Is there any…
Tatarinho
  • 754
  • 2
  • 11
  • 31
2
votes
4 answers

How to shift pixels of a pixmap efficient in Qt4

I have implemented a marquee text widget using Qt4. I painted the text content onto a pixmap first. And then paint a portion of this pixmap onto a paint device by calling painter.drawTiledPixmap(offsetX, offsetY, myPixmap) My Imagination is that, Qt…
stanleyxu2005
  • 8,081
  • 14
  • 59
  • 94
2
votes
1 answer

How to draw Pixmap on a texture?

I have problem with drawing a Pixmap on a texture with Samsung GT-N5100. public class PixmapHelper{ static Pixmap mapHelper; static Pixmap miniObject; public static void Initialize() { …
Rinnion
  • 89
  • 1
  • 9
2
votes
1 answer

Modifying transparency of Texture in LibGDX

I want to have a foreground texture overlayed on a background texture. Besides these two textures, I also have a mask that indicates which parts of the foreground should be transparent. This is what I tried: // Initially, the mask should have an…
Paul Manta
  • 30,618
  • 31
  • 128
  • 208
1
2
3
8 9