rectangles Questions
5
How can I draw a rectangle with rounded corners in OpenCV? I know that the functions ellipse() and line() can be simply put together to draw it. I just wonder if someone has done it before and has ...
Mcadoo asked 24/9, 2013 at 4:45
6
Solved
Let's say you have a set of ranges:
0 - 100: 'a'
0 - 75: 'b'
95 - 150: 'c'
120 - 130: 'd'
Obviously, these ranges overlap at certain points. How would you dissect these ranges to produce a list...
Ahron asked 10/3, 2009 at 3:21
10
Solved
In pygame I use pygame.draw.rect(screen, color, rectangle) for all the rectangles in my program. I want to be able to rotate these rectangles to any angle. I have seen the following code to rotate ...
Making asked 8/4, 2016 at 23:15
2
Solved
I would like to convert from a RectF to a Rect in Android. Currently I have:
RectF rectF = new RectF();
rectF.set( ... some values ... );
...
Rect rect = new Rect((int)rectF.left,
(int)rectF.to...
Untouchability asked 8/5, 2013 at 19:57
6
I'm making a game that requires knowing how to draw a rectangle in Python (3.2).
I have checked lot of sources but none show exactly how to do it.
Courtnay asked 5/11, 2013 at 1:20
6
Solved
This is a language-agnostic question. Given a rectangle's dimensions with l,t,w,h (left, top, width, height) and a point x,y, how do I find the nearest point on the perimeter of the rectangle to th...
Droopy asked 8/12, 2013 at 12:43
2
I have a code that draws hundreds of small rectangles on top of an image :
The rectangles are instances of
matplotlib.patches.Rectangle
I'd like to put a text (actually a number) into thes...
Hudibrastic asked 25/1, 2013 at 22:25
10
Given two rectangles with x, y, width, height in pixels and a rotation value in degrees -- how do I calculate the closest distance of their outlines toward each other?
Background: In a game writte...
Nikos asked 12/2, 2011 at 13:34
7
Solved
I have to find max number of rectangles from a given set of coordinates.
Consider the following coordinates are given in an X Y coordinate system
3 10,
3 8,
3 6,
3 4,
3 0,
6 0,
6 4,
6 8,
6 10,
H...
Welldressed asked 5/10, 2013 at 22:7
2
Solved
i have started a new project in python using pygame and for the background i want the bottom half filled with gray and the top black. i have used rect drawing in projects before but for some reason...
Thill asked 2/12, 2020 at 18:26
2
Solved
I have a set of rectangles and I would like to "reduce" the set so I have the fewest number of rectangles to describe the same area as the original set. If possible, I would like it to also be fast...
Surculose asked 7/5, 2011 at 5:21
2
Solved
I am using this code to make a rounded rectangle, but it only draws upper left and right corners of rectangle, more it doesn't not complete the rectangle at lower part. How do I make it complete an...
Equalitarian asked 22/11, 2015 at 9:40
3
cv2.rectangle has two ways of calling:
img = cv.rectangle( img, pt1, pt2, color[, thickness[, lineType[, shift]]] )
img = cv.rectangle( img, rec, color[, thickness[, lineType[, shift]]]
source:...
Garb asked 22/1, 2020 at 13:50
2
Solved
I want to draw a rectangle with rounded corners (border radius same for all 4 corners) with a specific color filling the entire rectangle, and a separate border color (say border is 1 px wide).
Fr...
Septemberseptembrist asked 22/3, 2015 at 16:5
5
Solved
Background: I am working on a site for small shopping center, which has multiple rectangular "units" to rent. When a "shop" comes, it can rent one or multiple "units", and I'd like to generate a ma...
Steapsin asked 6/12, 2012 at 14:57
5
Solved
I am using scene2d. Here is my code:
group.addActor(new Actor() {
@Override
public Actor hit(float arg0, float arg1) {
return null;
}
@Override
public void draw(SpriteBatch batch, float arg...
Incoherent asked 13/3, 2013 at 21:43
3
Solved
How do you draw shapes, such as Rectangles and Circles, in MonoGame without having to save the a predrawn shape in the Content folder?
DrawRectangle() and DrawEllipse() are for Windows Form and do...
Salmanazar asked 26/4, 2014 at 1:37
21
Solved
I am trying to write a C++ program that takes the following inputs from the user to construct rectangles (between 2 and 5): height, width, x-pos, y-pos. All of these rectangles will exist parallel ...
Veronique asked 20/11, 2008 at 18:21
1
Solved
After seeing this question many times and replying with old (and not usable) code I decided to redo everything and post about it.
Rectangles are defined by:
center : x and y for his position (reme...
Abdication asked 26/5, 2020 at 17:41
1
Solved
I have binary images where rectangles are placed randomly and I want to get the positions and sizes of those rectangles.
If possible I want the minimal number of rectangles necessary to exactly re...
Fawn asked 13/2, 2020 at 12:42
3
Solved
My Problem
Consider a set of data with two intervals. For instance, consider a student schedule of classes. Each record has a begin and end date, and each class has a period start time and a perio...
Subdominant asked 19/12, 2019 at 22:18
5
Solved
I want to display some text inside SVG rect. Is it possible?
I tried
<svg xmlns="http://www.w3.org/2000/svg">
<g>
<rect x="0" y="0" width="100" height="100" fill="red">
<...
Evulsion asked 17/7, 2011 at 16:43
2
Solved
How can I get the bounding boxes of multiple overlapping rectangles? There might be multiple bounding boxes if there are rectangles that don't overlap.
I have an array containing n objects repre...
Adrell asked 15/8, 2019 at 16:34
5
Solved
Let say that we have two rectangles, defined with their bottom-left and top-right corners. For example: rect1 (x1, y1)(x2, y2) and rect2 (x3, y3)(x4, y4).
I'm trying to find the coordinates(bottom-...
Chadwickchae asked 3/11, 2013 at 12:52
2
Solved
With the following code (thanks to several posts here), I draw a rectangle, that I want to be resizable and movable.
Two anchors (the upper left and lower right) do what I want, and the last one (l...
Sommersommers asked 10/10, 2014 at 11:56
1 Next >
© 2022 - 2024 — McMap. All rights reserved.