2d Questions
8
Solved
I have an guaranteed to be a perfect square matrix. I want to start at the center of the matrix in this case it would be matrix[2][2], I know how to figure the center (int)(dimensions / 2). I need ...
4
Solved
I have two large numpy arrays of randomly sorted 2d points, let's say they're A and B. What I need to do is find the number of "matches" between the two arrays, where a match is a point in A (call ...
6
Solved
I've got a quick question regarding 2D Sprite animations that I haven't been able to find specifically answered anywhere:
I have a sprite with walk animations to the right. However, I obviously wa...
Stiffler asked 26/10, 2014 at 0:10
3
Solved
I'm writing my own basic physic engine and now I come to a problem I can't solve. Probably because I don't how to google this problem.
So here is my problem. I hope this image can explain it:
Col...
Contentment asked 25/7, 2012 at 17:7
5
tl;dr summary: Give me the resources or help fix the below code to transform path commands for SVG <path> elements by an arbitrary matrix.
details:
I'm writing a library to convert any arbit...
Faery asked 1/3, 2011 at 0:44
3
Solved
I need to define an object (or a region) that is kind of "blob" shaped on a discrete gridmap. It should look something like this:
where the red region denotes the center point (these are just ide...
12
Solved
I have a 2D array containing integers (both positive or negative). Each row represents the values over time for a particular spatial site, whereas each column represents values for various spatial ...
15
Solved
How can I draw a perpendicular on a line segment from a given point? My line segment is defined as (x1, y1), (x2, y2), If I draw a perpendicular from a point (x3,y3) and it meets to line on point (...
Diurnal asked 28/11, 2009 at 4:25
4
Solved
How do I allocate and transfer(to and from Host) 2D arrays in device memory in Cuda?
Reshape asked 26/6, 2009 at 4:38
12
Solved
I have a 2d array like this:
var arr = [[2,3],[5,8],[1,1],[0,9],[5,7]];
Each index stores an inner array containing the coordinates of some element.
How can I use Array.indexOf() to check if th...
Briefing asked 24/7, 2014 at 20:18
1
Which Physics body would be the best for, let's say the player character, enemy and collectibles. StaticBodies are quite different and easy but it is very confusing when we have to choose between a...
Pokeberry asked 2/3, 2023 at 15:38
6
Solved
I am drawing a line on a control on my Windows form like this:
// Get Graphics object from chart
Graphics graph = e.ChartGraphics.Graphics;
PointF point1 = PointF.Empty;
PointF point2 = Point...
Populace asked 23/5, 2011 at 17:17
3
I'm trying to find a script for unity 2d. I need one that restarts the scene I've currently loaded. I've tried a couple from the internet, but none of them seem to work. I just need the basic scrip...
Excess asked 22/1, 2021 at 19:18
2
Solved
I am making a 2d game in the perspective of Terraria/Starbound. I want the lighting to look similar to this:
Ive tried to get lighting like this by adding a material on all the sprites in my game...
Villager asked 31/7, 2015 at 1:20
3
Solved
I have a map with a lot of sprites. I could add a material to the sprite with diffuse shading and than add lots of lights. But that won't give me the result I want. And is performance heavy.
Exa...
Apocopate asked 14/3, 2018 at 22:9
1
What is the easiest way to draw simple graphics using F# ?
I want to visualize a dynamic system (a simplified sample of my use case would be a red square going from one side of the screen to the o...
5
Solved
My current program draw a rotated bitmap (64x64) and tile it on the screen by drawing it again but adding an offset based on the computed position of the bitmap top right corner (after rotation), i...
Djokjakarta asked 11/12, 2022 at 23:45
2
Solved
I'm using a Lua API. I'm trying to transform 3D space coordinates to 2D space coordinates. I've asked google but I can't find anything apart from snippets using OpenGL function. I don't need source...
23
Solved
I want to create a two dimensional array in Javascript where I'm going to store coordinates (x,y). I don't know yet how many pairs of coordinates I will have because they will be dynamically genera...
Descend asked 10/8, 2013 at 15:12
5
Solved
I have a list of details from an output for "set1" which are like "name", "place", "animal", "thing"
and a "set2" with the same details.
I want to create a dictionary with dict_names[setx]['name']...
Legitimize asked 18/9, 2014 at 23:51
3
Solved
The issue I am trying to resolve is the following:
The C++ serial code I have computes across a large 2D matrix. To optimize this process, I wish to split this large 2D matrix and run on 4 nodes (...
Elkin asked 5/5, 2011 at 16:59
5
Solved
I have a python (NumPy) function which creates a uniform random quaternion. I would like to get two quaternion multiplication as 2-dimensional returned array from the same or an another function. T...
Valuator asked 16/8, 2016 at 15:7
2
I am preparing for an interview and have been stuck on this question for quite some time now. Could anybody please help me with the code. If not complete then may be a snippet of it?
Please..
10
Solved
I have a 2D image randomly and sparsely scattered with pixels.
given a point on the image, I need to find the distance to the closest pixel that is not in the background color (black).
What is the ...
Hagi asked 21/11, 2008 at 0:50
4
Solved
I need Three.js code to convert 3D object coordinates to 2d ones in a 'div' element so that I can place text labels where they need to be (without those labels scaling/moving/rotating along with th...
Dominickdominie asked 10/12, 2014 at 19:16
1 Next >
© 2022 - 2024 — McMap. All rights reserved.