Questions tagged [drawing]

Issues around forms and graphics being drawn onto a computer screen, windowing system or device

5923 questions
2
votes
0 answers

Why is my android view's width 0?

I created a custom view called CanvasView. I can use this view to draw stuff on it outside of the onDraw method. Which means I can add lines, circles, whatever I want to the canvas anywhere in my code. I want to draw a random line on the canvas view…
Sweeper
  • 213,210
  • 22
  • 193
  • 313
2
votes
2 answers

How do I call the Pie function?

I have the center point, radius, and angle to draw the pie, but the Pie function takes 4 points as input data. Does anyone have any conversion function or better explanation for this?
Maysam Torabi
  • 3,672
  • 2
  • 28
  • 31
2
votes
1 answer

Drawing performance over time for a UIBezierPath with Swift for iOS

I'm trying to understand different drawing methods in Swift and why they perform as they do. The below code draws smooth lines using a UIBezierPath, project available from https://github.com/limhowe/LimSignatureView Initially the performance of the…
user4806509
  • 2,925
  • 5
  • 37
  • 72
2
votes
2 answers

Java2D & Image creation

I want to dynamically create some image from Java and save it to a file. As I read in various tutorials, I need to use BufferedImage. But, the BufferedImage constructor requires that the height and width as parameters. But I don't know the final…
Anton Kazennikov
  • 3,574
  • 5
  • 30
  • 38
2
votes
2 answers

how to draw lines on a picture background in pygame

I would like to draw lines (of arbitrary position and length) onto a surface in pygame, which itself is an image loaded from a file on disk. Can anyone point me to some example code that does this?
Paul D. Eden
  • 19,939
  • 18
  • 59
  • 63
2
votes
2 answers

AggPas Delphi Drawing Transparencies

What im trying to do I have a drawing procedure (it works) it draws to a bitmap "OBJmap" it then puts OBJmap into Wholemap. This all works but there is a issue. It seems to treat the undefined parts of objmap as white even though objmap and wholemap…
Arthur
  • 3,376
  • 11
  • 43
  • 70
2
votes
1 answer

vb.net redrawing rectangles on picturebox and invalidate method

I am trying to create a rectangle on a picturebox with randome size and location. Every time the user click on a button, the rectangle will be removed and the new one will be displayed. Private Sub btnDraw_Click(sender As Object, e As EventArgs)…
2
votes
3 answers

How to customize Drawing control looks from google maps v3?

I am using this code to let user draw circles or images drawingManager = new google.maps.drawing.DrawingManager({ drawingMode: null, drawingControlOptions: { drawingModes:…
Toni Michel Caubet
  • 19,333
  • 56
  • 202
  • 378
2
votes
3 answers

How to draw an arc in universal windows app

I need an arc (circle segment) in my universal windows application, but i just cant figure it out how to make it. There are only circle and rectangle shapes available. My goal is to create an arc that is showing the given percent, line 50% 66% etc.
Jano
  • 401
  • 1
  • 5
  • 14
2
votes
1 answer

How to draw smooth ink annotation on PDF in iOS using Objective-C

I am drawing ink annotation in pdf using objective-c. Pdf specifications say that we need to provide an array of points for the ink drawing. I am using PoDoFo library. This is how I am drawing ink annotation currently: PoDoFo::PdfArray arr; //This…
M Zubair Shamshad
  • 2,741
  • 3
  • 23
  • 45
2
votes
1 answer

Writing a "Brushes" quality drawing app, need book and resource recommendations

I've spent about a week reading all the freely available information on iPhone drawing, animation, and OpenGL. Using the available iOS drawing examples like Apple's GLPaint and Quartz sample apps I've written a few versions of a painting tool, but…
2
votes
1 answer

Create line extensions for given line created by user

I've been working in an app which I have to capture user's touches and draw a line on the screen. This is working so far. The problem is that I'd like to create some kind of extension for that line that goes from the line start/end to the screen…
Danilo Gomes
  • 767
  • 5
  • 15
2
votes
1 answer

Capturing signature very sketchy on touch screen

I followed a tutorial for capturing signatures in Firemonkey, and made some major modifications (essentially a re-write) to encapsulate it inside of a custom control. I've written plenty controls in VCL, but this is my first for FMX. When using this…
Jerry Dodge
  • 26,858
  • 31
  • 155
  • 327
2
votes
1 answer

Drawing polygonal line with gradient in GDI+

I have a List of multiple points. How can I draw these points into a bitmap, to get the same as this: http://img291.imageshack.us/img291/4462/outputtz.png Points are known, I just need to achieve this gradient effect somehow. Please note that…
Paya
  • 5,124
  • 4
  • 45
  • 71
2
votes
0 answers

How to translate some x, y coordinates to screen coordinates in Android?

I have a map consisting of a number of lines. I'd like to draw these lines on my screen every so often (using a Handler to update the data every 100 ms, so I'm thinking I can update the screen in that update() method). I found a couple of questions…
Svj0hn
  • 454
  • 5
  • 19