|
||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||
| Some recent topics started on our forums | |
| Need help with some errors in my bilinear interpolation function | Quote: +---0,0---+---1,0---+ |? ? ? ? ?|? ? ? ? ?|... |? ? ? ? ?|? ? ? ? ?|... |? ? A ? ?|? ? B ? ?|... |? ? ? ? ?|? ? ? ? ?|... |? ? ? ? ?|? ? ? ? ?|... +---0,1---+---1,1---+ |? ? ? ? ?|? ? ? ? ?|... |? ? ? ? ?|? ? ? ? ?|... |? ? C ? ?|? ?... |
| Posted September 28, 2009 5:49:24 PM | |
| averaging elevation | Hey! I have a 2d-grid of squares. Each square contains it's own grid of lets say 11x11 squares. Every square also has an elevation value. I want to average out the elevation of the little squares within one of the larger squares with the surroun... |
| Posted September 27, 2009 9:00:02 PM | |
| [RESOLVED] functions w/ pointers as variables | I don't like pointers and mostly try to avoid them, but there are some places where they would be very useful. I have an object, regionMap, that contain vectors of vectors of another object, regionTile. Can I create a function that takes a po... |
| Posted March 3, 2009 1:35:57 PM | |
| Muert RPG | Muert RPG is a survival simulation/ randomly-generated role-playing game/ living world that is currently in development. world-map zoom: World-Map Zoom animals animaling: Animals Animaling Game features include: *randomly generated world ... |
| Posted December 29, 2008 4:23:46 PM | |
| glListBase & differently sized structures created with call lists | Ok - I have a 2d tile-based game that I display with quads that are looked at head-on. I have each of the 16 x 16 tiles associated with a call list that I create. I read the bmp into memeory then create the call lists at a certain size then if I w... |
| Posted November 17, 2008 12:32:16 AM | |
| reading a txt file in c++ - so simple?!? | I don't get it - I thought this stuff was easy! ( and yes - the first value read in from the text file is the 4th # in the output, I switched them around in the text file at some point when I was trying to figure this out) Why is this the outpu... |
| Posted July 1, 2007 4:15:45 PM | |
| openGL kernel32 error | Hey. I am trying to make my game more portable. Does anybody have any idea what could be causing this error message and how I can go about solving it? That is all the information I have about the error. (I can run the program just fine on a... |
| Posted December 25, 2006 5:01:10 PM | |
| trying to port windows-centric bmp loader | hey, I am trying to make my program more portable, and I have moved all my input to SDL and thought everything was ok. Except for my bmp reading function! It uses: BITMAPFILEHEADER BITMAPINFOHEADER & RGBTRIPLE Does anybody have any good... |
| Posted December 23, 2006 7:48:32 PM | |
| more than 256 display lists | I can't figure out how to do them. I was using NeHe tutorial # 17 and changed it from 128 to 256 lists (GL_BYTE to GL_UNSIGNED_BYTE) and it works fine, but I can not figure out how to do more. I have the texture fine, all the measurements correct... |
| Posted October 10, 2006 10:22:57 PM | |
| changing colors of textures in openGL - [SOLVED] | this was my problem. glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE); once I changed it to GL_BLEND it worked fine. I can not figure out what I am doing wrong. I used one of the tutorials from spacesimu... |
| Posted September 25, 2006 1:52:16 PM | |
| View All Topics Started By This User | |
| Some recent replies made on our forums | |
| Need help with some errors in my bilinear interpolation function | I've got to thank you for all your help, iMalc! This is what I wound up doing (I broke up the function into a couple of different code quotes because it is kind of long): void smoothifyRegion(int wX, int wY, int aX, int aY) { std::stringstr... |
| Posted October 2, 2009 1:05:34 AM | |
| Need help with some errors in my bilinear interpolation function | I think I am just missing some minor step in my function somewhere - I need 'e' to only take into account 5 & 2, because at that point, both 4 & 7 and 1 & 8 should have 0% influence on the value I only have odd sized maps at this... |
| Posted September 30, 2009 6:30:36 PM | |
| Need help with some errors in my bilinear interpolation function | Yeah, that code is pretty funked up - the lowercase n, ne, e, se, s, sw, w & nw are the surrounding big square's base elevation values (or the A, B & D in the example where we try to calculate the values for the C square - the A would be n, the B w... |
| Posted September 30, 2009 2:49:22 PM | |
| Need help with some errors in my bilinear interpolation function | I don't really understand - so if I do something like your diagram to calculate only the central 5-value square: +---+---+---+ |5??|?1?|??4| |???|???|???| |???|???|???| +---+---+---+ |???|???|???| |9??|?5?|??2| |???|???|???| +---+... |
| Posted September 30, 2009 2:36:17 PM | |
| Need help with some errors in my bilinear interpolation function | Thanks for the thorough description iMalc! I don't think I explained the specifics of my problem very well or else I am not completely understanding your explanation. I am not doing anything with graphics, I let openGL handle all of the resa... |
| Posted September 30, 2009 1:22:41 AM | |
| Need help with some errors in my bilinear interpolation function | The code seems to be interpolating correctly within each quadrant, but the 4 quadrants don't line up correctly. And there are those little low elevation squares (the little blue squares evenly spaced around) that mark the exact center of each square.... |
| Posted September 28, 2009 5:56:13 PM | |
| averaging elevation | ok - now I am having trouble with implementation: for(int pix = 0; pix < RMAP_X; pix++) { for(int piy = 0; piy < RMAP_Y; piy++) { quadrant = -1; if(pix < (halfRMAP_X) && piy <(halfRMAP_Y)) { quadrant =... |
| Posted September 28, 2009 2:11:35 PM | |
| averaging elevation | Hodgman, that is basically what I was picturing, but it seems so much easier the way you wrote it out than the way I was envisioning it. Thanks! |
| Posted September 28, 2009 10:57:11 AM | |
| [RESOLVED] functions w/ pointers as variables | yeah, that is exactly what I am looking for - thanks SriLumpa! |
| Posted March 3, 2009 4:13:20 PM | |
| [RESOLVED] functions w/ pointers as variables | I am sure it is something as simple as that. Now how do I pick which regionTile[pix][piy].var1, var2, or var3 the function edits? |
| Posted March 3, 2009 3:56:44 PM | |
| View All Replies Made By This User | |