|
Luigi Thirty posted:can someone help me out with my rasterization routine? e: oh wait that's a plus, so i'm wrong e2: how far is the camera from the vector? Also what is this <(-1,1),(-1,1),(-1,1)>? three points in a plane? e3: you mean a line segment from (-1, -1, -1) to (1, 1, 1) and the camera is at (-1, 1, 0) where points are (x, y, z)? e4: regardless i'm p sure your scaleFactor needs to be multiplied by SCREEN_WIDTH and SCREEN_HEIGHT respectively (also be made like .2 or some poo poo in that case) HoboMan fucked around with this message at 04:23 on Jul 12, 2016 |
# ? Jul 12, 2016 04:04 |
|
|
# ? May 11, 2024 07:05 |
|
HoboMan posted:e: oh wait that's a plus, so i'm wrong the screen is 320x200 so SCREEN_WIDTH and SCREEN_HEIGHT are 320 and 200 respectively screenCoordinates is a vector containing an X and Y each between -1 and 1 which right now gets multiplied by a scale factor to produce pixel coordinates. the Z coordinate is for the Z-buffer. HoboMan posted:e3: you mean a line segment from (-1, -1, -1) to (1, 1, 1) and the camera is at (-1, 1, 0) where points are (x, y, z)? the center of the screen is (0,0,0), this is well after we've done the camera transforms and everything i might be doing this wrong https://github.com/Luigi30/polygon/blob/master/framebuffer.cpp#L152 here's the whole function for context Luigi Thirty fucked around with this message at 04:26 on Jul 12, 2016 |
# ? Jul 12, 2016 04:22 |
luigi idk if youve seen http://ogldev.atspace.co.uk/www/tutorial12/tutorial12.html
|
|
# ? Jul 12, 2016 04:29 |
|
oh scaleFactor is just way too low
|
# ? Jul 12, 2016 04:35 |
|
basically hope i was mildly helpful HoboMan fucked around with this message at 04:42 on Jul 12, 2016 |
# ? Jul 12, 2016 04:38 |
|
you were and I more or less solved my FOV problem
|
# ? Jul 12, 2016 04:39 |
|
|
# ? Jul 12, 2016 06:54 |
|
Luigi Thirty posted:https://github.com/Luigi30/polygon?files=1 hell yes!!!
|
# ? Jul 12, 2016 12:58 |
|
oh yeah at 3 am i figured out what i needed to do with that queue thing to maintain order without having some other thread read from the queue. everything in the queue gets a semaphore initialized to 0. everybody who wants to do the thing waits on the semaphore for their thing in the queue. whenever something's dequeued, it signals the next thing. and if the queue is empty, the next thing enqueued is immediately signaled. the end this already exists, doesn't it
|
# ? Jul 12, 2016 12:59 |
|
this is easier if you put the readers in a queue too while next = blocking_list_of_stuff.pop { worker = blocking_list_of_workers.pop worker.process(next) }
|
# ? Jul 12, 2016 13:10 |
did anyone say monads and strife yet
|
|
# ? Jul 12, 2016 14:24 |
|
GameCube posted:oh yeah at 3 am i figured out what i needed to do with that queue thing to maintain order without having some other thread read from the queue. everything in the queue gets a semaphore initialized to 0. everybody who wants to do the thing waits on the semaphore for their thing in the queue. whenever something's dequeued, it signals the next thing. and if the queue is empty, the next thing enqueued is immediately signaled. the end i'm doing a similar thing and the only class that looks related that i found so far is ConcurrentQueue this really does seem like a class that would exist though so if anyone know what it is that would be very helpful e: also what the heck is this? C# code:
HoboMan fucked around with this message at 15:02 on Jul 12, 2016 |
# ? Jul 12, 2016 14:59 |
|
tef posted:this is easier if you put the readers in a queue too i don't even have any readers, even though i should. i think. idk. i just want multiple calls to this api from different threads or tasks maybe? to be executed in order
|
# ? Jul 12, 2016 15:32 |
|
HoboMan posted:e: also what the heck is this? multidimensional array.
|
# ? Jul 12, 2016 15:37 |
|
uggggh why is httpclient giving me these freakin 404s. why. it's not even reaching the server!! the gently caress
|
# ? Jul 12, 2016 15:44 |
|
GameCube posted:i don't even have any readers, even though i should. i think. idk. i just want multiple calls to this api from different threads or tasks maybe? to be executed in order your threads are the "readers"
|
# ? Jul 12, 2016 15:51 |
|
GameCube posted:oh yeah at 3 am i figured out what i needed to do with that queue thing to maintain order without having some other thread read from the queue. everything in the queue gets a semaphore initialized to 0. everybody who wants to do the thing waits on the semaphore for their thing in the queue. whenever something's dequeued, it signals the next thing. and if the queue is empty, the next thing enqueued is immediately signaled. the end it definitely does in posix but i think youre in .netland if i remember right?
|
# ? Jul 12, 2016 16:55 |
|
HoboMan posted:your threads are the "readers" yeah but they're like... just async functions awaiting on stuff. idk this thing seems to work. LeftistMuslimObama posted:it definitely does in posix but i think youre in .netland if i remember right? iirc (probably not) posix semaphores will make threads wait their turn but not .net
|
# ? Jul 12, 2016 17:05 |
|
now this freaking httpclient is throwing 404s without even trying. i'm using mitmproxy to watch the traffic and it's just not happening. wtffffff i must be holding onto some resource cuz the first request succeeds and then every request after that fails. hmm
|
# ? Jul 12, 2016 17:06 |
|
404 means it's not there, when i was debugging an API earlier it always meant the service was not running
|
# ? Jul 12, 2016 17:19 |
|
ok so i'm benchmarking parallelizing this thing but the parallel version seems no faster (some runs were slower even)
|
# ? Jul 12, 2016 22:14 |
|
it can definitely be slower depending on what you're parallelizing
|
# ? Jul 12, 2016 22:50 |
|
i made a house it crashes after ~30 seconds with a stack overflow lol
|
# ? Jul 13, 2016 00:53 |
|
HoboMan posted:404 means it's not there, when i was debugging an API earlier it always meant the service was not running lol i know what 404 means. i'm intercepting the traffic with mitmproxy (very good and cool) and the request isn't even going out! wtf!! and i know the service is running because i am running it, on my computer. freaking microshafted again. it is impossible that my code is wrong.
|
# ? Jul 13, 2016 01:08 |
|
fiddler is probably better!!
|
# ? Jul 13, 2016 01:31 |
|
i really like fiddler because it coerces lovely linux programs that use bad proxy unaware interfaces into working with our mega enterprise corporate proxy
|
# ? Jul 13, 2016 01:32 |
|
fiddler required me to set a registry key and restart the app in order to do reverse proxy. lomarf. anyway i did already try that since mitmproxy's console ui only works (and poorly) in cygwin if you're on windows... but the same freakin thing! what gives!!
|
# ? Jul 13, 2016 01:50 |
|
Finally had to resort to git bisect today. It was less painful than expected.
|
# ? Jul 13, 2016 02:57 |
|
We're apparently considering a move off of svn! Yay!
|
# ? Jul 13, 2016 03:11 |
|
to cvs?
|
# ? Jul 13, 2016 03:16 |
|
Bloody posted:to cvs? I heard they're researching whether git or mercurial will integrate better with our existing tools.
|
# ? Jul 13, 2016 03:24 |
|
LeftistMuslimObama posted:I heard they're researching whether git or mercurial will integrate better with our existing tools. the answer is that mercurial is waaay easier for svn users to pick up and some of the third party tooling is similar all the cool people use git though really cool people have a special git config and workflow tools and they will talk about them
|
# ? Jul 13, 2016 04:27 |
|
git is so bad
|
# ? Jul 13, 2016 04:29 |
|
Shaggar posted:git is so bad it's a bit sucky, but the better (hg) is the enemy of the good (git)
|
# ? Jul 13, 2016 04:30 |
|
GameCube posted:uggggh why is httpclient giving me these freakin 404s. why. it's not even reaching the server!! the gently caress one time my urls got so long that the client i was using just started giving 404a
|
# ? Jul 13, 2016 04:42 |
|
Mr Dog posted:it's a bit sucky, but the better (hg) is the enemy of the good (git)
|
# ? Jul 13, 2016 05:05 |
|
tbh, if you're moving olds from svn, hg is pretty ok and not a huge jump, the interface is very similar (you commit, but now you push and pull) and there's usually 1-1 mapping from one command to another with git, well what you did in svn can be done in 20 different and arcane ways, but it does the job and ~everyone~ uses github or so i'm told
|
# ? Jul 13, 2016 05:45 |
|
git really is shamefully bad maybe it's good at what it was designed to do, but as someone who doesn't mail Linux patches around how would I ever know
|
# ? Jul 13, 2016 05:48 |
|
i've heard that to understand git, you should read some book "git from the ground up" or something like that. to understand mercurial, i just had to read the manual. of course everything everywhere uses git, so you need to learn it anyway. a partner complained to me about using mercurial instead of git about 6 months ago in our company's projects. i told him that before i came to the company, there was no version control at all and the development and production server code had already started to drift apart quite significantly and mercurial was the one i could understand at the time. this happened in 2010
|
# ? Jul 13, 2016 06:25 |
|
|
# ? May 11, 2024 07:05 |
|
git is extremely easy and i really have even more trouble understanding ho0w a bunch of programmers don't understand it but i guess this is the terrible programmer thread after all
|
# ? Jul 13, 2016 06:31 |