Search Results

Search found 99 results on 4 pages for 'cy'.

Page 1/4 | 1 2 3 4  | Next Page >

  • Ignoring file 'eugenesan-java-quantal.list.save'

    - by Lupus
    I have a problem with my newly installed 12.10 86_64 Desktop. This error pops up on console when I try to update apt-get or try to install packages and nodejs just don't work and there is no error on console. Ignoring file 'eugenesan-java-quantal.list.save' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension this error started after my update on apt-get sudo apt-get update I'm a newbie on ubuntu. this is the log file : (in Turkish 'Yoksay' = Ignored, 'Baglandi' = Connected, 'getirilmesi basarisiz oldu' = failed to get ) attila@Lupuseum:~$ sudo apt-get update Yoksay http://security.ubuntu.com quantal-security InRelease Yoksay http://extras.ubuntu.com quantal InRelease Yoksay http://ppa.launchpad.net quantal InRelease Baglandi http://security.ubuntu.com quantal-security Release.gpg Baglandi http://extras.ubuntu.com quantal Release.gpg Yoksay http://cy.archive.ubuntu.com quantal InRelease Yoksay http://ppa.launchpad.net quantal InRelease Baglandi http://security.ubuntu.com quantal-security Release Baglandi http://extras.ubuntu.com quantal Release Yoksay http://cy.archive.ubuntu.com quantal-updates InRelease Baglandi http://ppa.launchpad.net quantal Release.gpg Baglandi http://security.ubuntu.com quantal-security/main Sources Yoksay http://cy.archive.ubuntu.com quantal-backports InRelease Baglandi http://extras.ubuntu.com quantal/main Sources Yoksay http://ppa.launchpad.net quantal Release.gpg Baglandi http://security.ubuntu.com quantal-security/restricted Sources Baglandi http://cy.archive.ubuntu.com quantal Release.gpg Baglandi http://extras.ubuntu.com quantal/main amd64 Packages Baglandi http://ppa.launchpad.net quantal Release Baglandi http://security.ubuntu.com quantal-security/universe Sources Baglandi http://cy.archive.ubuntu.com quantal-updates Release.gpg Baglandi http://extras.ubuntu.com quantal/main i386 Packages Yoksay http://ppa.launchpad.net quantal Release Baglandi http://cy.archive.ubuntu.com quantal-backports Release.gpg Baglandi http://ppa.launchpad.net quantal/main Sources Baglandi http://security.ubuntu.com quantal-security/multiverse Sources Baglandi http://cy.archive.ubuntu.com quantal Release Baglandi http://ppa.launchpad.net quantal/main amd64 Packages Baglandi http://security.ubuntu.com quantal-security/main amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-updates Release Baglandi http://ppa.launchpad.net quantal/main i386 Packages Baglandi http://security.ubuntu.com quantal-security/restricted amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports Release Baglandi http://security.ubuntu.com quantal-security/universe amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal/main Sources Baglandi http://security.ubuntu.com quantal-security/multiverse amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal/restricted Sources Baglandi http://security.ubuntu.com quantal-security/main i386 Packages Baglandi http://cy.archive.ubuntu.com quantal/universe Sources Baglandi http://security.ubuntu.com quantal-security/restricted i386 Packages Baglandi http://cy.archive.ubuntu.com quantal/multiverse Sources Baglandi http://security.ubuntu.com quantal-security/universe i386 Packages Baglandi http://cy.archive.ubuntu.com quantal/main amd64 Packages Baglandi http://security.ubuntu.com quantal-security/multiverse i386 Packages Baglandi http://cy.archive.ubuntu.com quantal/restricted amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal/universe amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal/multiverse amd64 Packages Baglandi http://security.ubuntu.com quantal-security/main Translation-en Yoksay http://extras.ubuntu.com quantal/main Translation-tr_CY Baglandi http://cy.archive.ubuntu.com quantal/main i386 Packages Baglandi http://cy.archive.ubuntu.com quantal/restricted i386 Packages Yoksay http://extras.ubuntu.com quantal/main Translation-tr Baglandi http://security.ubuntu.com quantal-security/multiverse Translation-en Baglandi http://cy.archive.ubuntu.com quantal/universe i386 Packages Yoksay http://extras.ubuntu.com quantal/main Translation-en Baglandi http://cy.archive.ubuntu.com quantal/multiverse i386 Packages Baglandi http://cy.archive.ubuntu.com quantal/main Translation-tr Baglandi http://cy.archive.ubuntu.com quantal/main Translation-en Baglandi http://security.ubuntu.com quantal-security/restricted Translation-en Baglandi http://cy.archive.ubuntu.com quantal/multiverse Translation-tr Baglandi http://cy.archive.ubuntu.com quantal/multiverse Translation-en Baglandi http://security.ubuntu.com quantal-security/universe Translation-en Baglandi http://cy.archive.ubuntu.com quantal/restricted Translation-tr Baglandi http://cy.archive.ubuntu.com quantal/restricted Translation-en Baglandi http://cy.archive.ubuntu.com quantal/universe Translation-tr Baglandi http://cy.archive.ubuntu.com quantal/universe Translation-en Baglandi http://cy.archive.ubuntu.com quantal-updates/main Sources Baglandi http://cy.archive.ubuntu.com quantal-updates/restricted Sources Baglandi http://cy.archive.ubuntu.com quantal-updates/universe Sources Baglandi http://cy.archive.ubuntu.com quantal-updates/multiverse Sources Baglandi http://cy.archive.ubuntu.com quantal-updates/main amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-updates/restricted amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-updates/universe amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-updates/multiverse amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-updates/main i386 Packages Baglandi http://cy.archive.ubuntu.com quantal-updates/restricted i386 Packages Baglandi http://cy.archive.ubuntu.com quantal-updates/universe i386 Packages Baglandi http://cy.archive.ubuntu.com quantal-updates/multiverse i386 Packages Yoksay http://ppa.launchpad.net quantal/main Translation-tr_CY Yoksay http://ppa.launchpad.net quantal/main Translation-tr Yoksay http://ppa.launchpad.net quantal/main Translation-en Baglandi http://cy.archive.ubuntu.com quantal-updates/main Translation-en Hata http://ppa.launchpad.net quantal/main Sources 404 Not Found Hata http://ppa.launchpad.net quantal/main amd64 Packages 404 Not Found Hata http://ppa.launchpad.net quantal/main i386 Packages 404 Not Found Baglandi http://cy.archive.ubuntu.com quantal-updates/multiverse Translation-en Yoksay http://ppa.launchpad.net quantal/main Translation-tr_CY Yoksay http://security.ubuntu.com quantal-security/main Translation-tr_CY Yoksay http://ppa.launchpad.net quantal/main Translation-tr Yoksay http://security.ubuntu.com quantal-security/main Translation-tr Yoksay http://ppa.launchpad.net quantal/main Translation-en Yoksay http://security.ubuntu.com quantal-security/multiverse Translation-tr_CY Baglandi http://cy.archive.ubuntu.com quantal-updates/restricted Translation-en Yoksay http://security.ubuntu.com quantal-security/multiverse Translation-tr Yoksay http://security.ubuntu.com quantal-security/restricted Translation-tr_CY Yoksay http://security.ubuntu.com quantal-security/restricted Translation-tr Baglandi http://cy.archive.ubuntu.com quantal-updates/universe Translation-en Yoksay http://security.ubuntu.com quantal-security/universe Translation-tr_CY Baglandi http://cy.archive.ubuntu.com quantal-backports/main Sources Yoksay http://security.ubuntu.com quantal-security/universe Translation-tr Baglandi http://cy.archive.ubuntu.com quantal-backports/restricted Sources Baglandi http://cy.archive.ubuntu.com quantal-backports/universe Sources Baglandi http://cy.archive.ubuntu.com quantal-backports/multiverse Sources Baglandi http://cy.archive.ubuntu.com quantal-backports/main amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports/restricted amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports/universe amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports/multiverse amd64 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports/main i386 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports/restricted i386 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports/universe i386 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports/multiverse i386 Packages Baglandi http://cy.archive.ubuntu.com quantal-backports/main Translation-en Baglandi http://cy.archive.ubuntu.com quantal-backports/multiverse Translation-en Baglandi http://cy.archive.ubuntu.com quantal-backports/restricted Translation-en Baglandi http://cy.archive.ubuntu.com quantal-backports/universe Translation-en Yoksay http://cy.archive.ubuntu.com quantal/main Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal/multiverse Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal/restricted Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal/universe Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-updates/main Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-updates/main Translation-tr Yoksay http://cy.archive.ubuntu.com quantal-updates/multiverse Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-updates/multiverse Translation-tr Yoksay http://cy.archive.ubuntu.com quantal-updates/restricted Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-updates/restricted Translation-tr Yoksay http://cy.archive.ubuntu.com quantal-updates/universe Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-updates/universe Translation-tr Yoksay http://cy.archive.ubuntu.com quantal-backports/main Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-backports/main Translation-tr Yoksay http://cy.archive.ubuntu.com quantal-backports/multiverse Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-backports/multiverse Translation-tr Yoksay http://cy.archive.ubuntu.com quantal-backports/restricted Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-backports/restricted Translation-tr Yoksay http://cy.archive.ubuntu.com quantal-backports/universe Translation-tr_CY Yoksay http://cy.archive.ubuntu.com quantal-backports/universe Translation-tr N: Ignoring file 'eugenesan-java-quantal.list.save' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension W: http://ppa.launchpad.net/richarvey/nodejs/ubuntu/dists/quantal/main/source/Sources 404 Not Found getirilmesi basarisiz oldu W: http://ppa.launchpad.net/richarvey/nodejs/ubuntu/dists/quantal/main/binary-amd64/Packages 404 Not Found getirilmesi basarisiz oldu W: http://ppa.launchpad.net/richarvey/nodejs/ubuntu/dists/quantal/main/binary-i386/Packages 404 Not Found getirilmesi basarisiz oldu E: Some index files failed to download. They have been ignored, or old ones used instead.

    Read the article

  • Problem with SLATEC routine usage with gfortran

    - by user39461
    I am trying to compute the Bessel function of the second kind (Bessel_y) using the SLATEC's Amos library available on Netlib. Here is the SLATEC code I use. Below I have pasted my test program that calls SLATEC routine CBESY. PROGRAM BESSELTEST IMPLICIT NONE REAL:: FNU INTEGER, PARAMETER :: N = 2, KODE = 1 COMPLEX,ALLOCATABLE :: CWRK (:), CY (:) COMPLEX:: Z, ci INTEGER :: NZ, IERR ALLOCATE(CWRK(N), CY(N)) ci = cmplx (0.0, 1.0) FNU = 0.0e0 Z = CMPLX(0.3e0, 0.4e0) CALL CBESY(Z, FNU, KODE, N, CY, NZ, CWRK, IERR) WRITE(*,*) 'CY: ', CY WRITE(*,*) 'IERR: ', IERR STOP END PROGRAM And here is the output of the above program: CY: ( 5.78591091E-39, 5.80327020E-39) ( 0.0000000 , 0.0000000 ) IERR: 4 Ierr = 4 meaning there is some problem with the input itself. To be precise, the IERR = 4 means the following as per the header info in CBESY.f file: ! IERR=4, CABS(Z) OR FNU+N-1 TOO LARGE - NO COMPUTA- ! TION BECAUSE OF COMPLETE LOSSES OF SIGNIFI- ! CANCE BY ARGUMENT REDUCTION Clearly, CABS(Z) (which is 0.50) or FNU + N - 1 (which is 1.0) are not too large but still the routine CBESY throws the error message number 4 as above. The CY array should have following values for the argument given in above code: CY(1) = -0.4983 + 0.6700i CY(2) = -1.0149 + 0.9485i These values are computed using Matlab. I can't figure out what's the problem when I call CBESY from SLATEC library. Any clues? Much thanks for the suggestions/help. PS: if it is of any help, I used gfortran to compile, link and then create the SLATEC library file ( the .a file ) which I keep in the same directory as my test program above. shell command to execute above code: gfortran -c BesselTest.f95 gfortran -o a *.o libslatec.a a GD.

    Read the article

  • what does AngleVectors method in quake 3 source code does

    - by kypronite
    I just downloaded quake 3 for learning purposes. I know some of some linear algebra(basic vector math ie: dot,cross product). However I can't decipher what below method does, I know what is yaw,pitch and roll. But I can't connect these with vector. Worse, I'm not sure this fall under what math 'category', so I don't really know how to google. Hence the question here. Anyone? void AngleVectors( const vec3_t angles, vec3_t forward, vec3_t right, vec3_t up) { float angle; static float sr, sp, sy, cr, cp, cy; // static to help MS compiler fp bugs angle = angles[YAW] * (M_PI*2 / 360); sy = sin(angle); cy = cos(angle); angle = angles[PITCH] * (M_PI*2 / 360); sp = sin(angle); cp = cos(angle); angle = angles[ROLL] * (M_PI*2 / 360); sr = sin(angle); cr = cos(angle); if (forward) { forward[0] = cp*cy; forward[1] = cp*sy; forward[2] = -sp; } if (right) { right[0] = (-1*sr*sp*cy+-1*cr*-sy); right[1] = (-1*sr*sp*sy+-1*cr*cy); right[2] = -1*sr*cp; } if (up) { up[0] = (cr*sp*cy+-sr*-sy); up[1] = (cr*sp*sy+-sr*cy); up[2] = cr*cp; } } ddddd

    Read the article

  • Html 5 ping pong game side collision problem

    - by Gurjit
    I am making a simple ping pong game where I am facing a side collision problem means when the ball collides with the either side of the paddle . Although I have written code for making it works but something is failing....I want plz someone to give suggestions and tell how to avoid it. Means while trying to hit the ball with side face of the paddle poses a problem.!! Here is the main part of the code causing problem function checkCollision(){ ///// This is collision detection for the upper part ///// if( cy + radius >= paddleTop && cx + radius > paddleLeft && cy + radius >= paddleTop + 5 && cx - radius <= paddleLeft + paddleWidth ) { dy = -dy; ++hits; /// On collision we are increasing the Score playSound(); } else if( cy + radius >= paddleTop && cy + radius <= paddleTop + paddleHeight && cx + radius >= paddleLeft && cy - radius <= paddleLeft - (radius + 1) ) { dx = -dx; } } here is working fiddle for it :- http://jsfiddle.net/gurjitmehta/orzpzf69/

    Read the article

  • How to make Chrome redraw SVG dynamically added content?

    - by Adrian
    I've dynamacally added the circle elements to the svg displayed in a iFrame. Chrome isnt showing the new elements, not tried FF yet. Is there somekind of redraw/refresh I need to call? The first circle is actually in the svg document, the rest come from script. <iframe id="svgFrame" src="xmlfile1.svg" width="300" height="300"> <svg xmlns="http://www.w3.org/2000/svg" id="SVG1" width="200" height="200"> <circle cx="20" cy="20" r="5"/> <circle cx="165" cy="80" r="32"/> <circle cx="15" cy="38" r="32"/> <circle cx="140" cy="39" r="30"/> <circle cx="178" cy="32" r="22"/> ...etc <circle cx="166" cy="130" r="16"/> </svg> </iframe> The javascript which creates the elements: function RandomNumber(min, max) { var r; r = Math.floor(Math.random() * (max - min + 1)) + min; return r; } var svg = document.getElementById("svgFrame").contentDocument; for (var i = 0; i < 99; i++) { var n = svg.createElement("circle"); n.setAttribute("cx" , RandomNumber( 0 , 200) ); n.setAttribute("cy" , RandomNumber(0, 200) ); n.setAttribute("r" , RandomNumber(5, 35) ); svg.documentElement.appendChild(n); }

    Read the article

  • Why does Raphael's framerate slow down on this code?

    - by Bob
    So I'm just doing a basic orbit simulator using Raphael JS, where I draw one circle as the "star" and another circle as the "planet". It seems to be working just fine, with the one snag that as the simulation continues, its framerate progressively slows down until the orbital motion no longer appears fluid. Here's the code (note: uses jQuery only to initialize the page): $(function() { var paper = Raphael(document.getElementById('canvas'), 640, 480); var star = paper.circle(320, 240, 10); var planet = paper.circle(320, 150, 5); var starVelocity = [0,0]; var planetVelocity = [20.42,0]; var starMass = 3.08e22; var planetMass = 3.303e26; var gravConstant = 1.034e-18; function calculateOrbit() { var accx = 0; var accy = 0; accx = (gravConstant * starMass * ((star.attr('cx') - planet.attr('cx')))) / (Math.pow(circleDistance(), 3)); accy = (gravConstant * starMass * ((star.attr('cy') - planet.attr('cy')))) / (Math.pow(circleDistance(), 3)); planetVelocity[0] += accx; planetVelocity[1] += accy; planet.animate({cx: planet.attr('cx') + planetVelocity[0], cy: planet.attr('cy') + planetVelocity[1]}, 150, calculateOrbit); paper.circle(planet.attr('cx'), planet.attr('cy'), 1); // added to 'trace' orbit } function circleDistance() { return (Math.sqrt(Math.pow(star.attr('cx') - planet.attr('cx'), 2) + Math.pow(star.attr('cy') - planet.attr('cy'), 2))); } calculateOrbit(); }); It doesn't appear, to me anyway, that any part of that code would cause the animation to gradually slow down to a crawl, so any help solving the problem will be appreciated!

    Read the article

  • Win32 window capture with BitBlt not displaying border

    - by user292533
    I have written some c++ code to capture a window to a .bmp file. BITMAPFILEHEADER get_bitmap_file_header(int width, int height) { BITMAPFILEHEADER hdr; memset(&hdr, 0, sizeof(BITMAPFILEHEADER)); hdr.bfType = ((WORD) ('M' << 8) | 'B'); // is always "BM" hdr.bfSize = 0;//sizeof(BITMAPFILEHEADER) + sizeof(BITMAPINFOHEADER) + (width * height * sizeof(int)); hdr.bfReserved1 = 0; hdr.bfReserved2 = 0; hdr.bfOffBits = (DWORD)(sizeof(BITMAPFILEHEADER) + sizeof(BITMAPINFOHEADER)); return hdr; } BITMAPINFO get_bitmap_info(int width, int height) { BITMAPINFO bmi; memset(&bmi.bmiHeader, 0, sizeof(BITMAPINFOHEADER)); //initialize bitmap header bmi.bmiHeader.biSize = sizeof(BITMAPINFOHEADER); bmi.bmiHeader.biWidth = width; bmi.bmiHeader.biHeight = height; bmi.bmiHeader.biPlanes = 1; bmi.bmiHeader.biBitCount = 4 * 8; bmi.bmiHeader.biCompression = BI_RGB; bmi.bmiHeader.biSizeImage = width * height * 4; return bmi; } void get_bitmap_from_window(HWND hWnd, int * imageBuff) { HDC hDC = GetWindowDC(hWnd); SIZE size = get_window_size(hWnd); HDC hMemDC = CreateCompatibleDC(hDC); RECT r; HBITMAP hBitmap = CreateCompatibleBitmap(hDC, size.cx, size.cy); HBITMAP hOld = (HBITMAP)SelectObject(hMemDC, hBitmap); BitBlt(hMemDC, 0, 0, size.cx, size.cy, hDC, 0, 0, SRCCOPY); //PrintWindow(hWnd, hMemDC, 0); BITMAPINFO bmi = get_bitmap_info(size.cx, size.cy); GetDIBits(hMemDC, hBitmap, 0, size.cy, imageBuff, &bmi, DIB_RGB_COLORS); SelectObject(hMemDC, hOld); DeleteDC(hMemDC); ReleaseDC(NULL, hDC); } void save_image(HWND hWnd, char * name) { int * buff; RECT r; SIZE size; GetWindowRect(hWnd, &r); size.cx = r.right-r.left; size.cy = r.bottom-r.top; buff = (int*)malloc(size.cx * size.cy * sizeof(int)); get_bitmap_from_window(hWnd, buff); BITMAPINFO bmi = get_bitmap_info(size.cx, size.cy); BITMAPFILEHEADER hdr = get_bitmap_file_header(size.cx, size.cy); FILE * fout = fopen(name, "w"); fwrite(&hdr, 1, sizeof(BITMAPFILEHEADER), fout); fwrite(&bmi.bmiHeader, 1, sizeof(BITMAPINFOHEADER), fout); fwrite(buff, 1, size.cx * size.cy * sizeof(int), fout); fflush(fout); fclose(fout); free(buff); } It works find under XP, but under Vista the border of the window is transparent. Using PrintWindow solves the problem, but is unacceptable for performance reasons. Is there a performant code change, or a setting that can be changed to make the border non-transparent?

    Read the article

  • Libgdx - 2D Mesh rendering overlap glitch

    - by user46858
    I am trying to render a 2D circle segment mesh (quarter circle)using Libgdx/Opengl ES 2.0 but I seem to be getting an overlapping issue as seen in the picture attached. I cant seem to find the cause of the problem but the overlapping disappears/reappears if I drag and resize the window to random sizes. The problem occurs on both pc and android. The strange thing is the first two segments atleast dont seem to be causing any overlapping only the third and/or forth segment.......even though they are all rendered using the same mesh object..... I have spent ages trying to find the cause of the problem before posting here for help so ANY help/advice in finding the cause of this problem would be really appreciated. public class MyGdxGame extends Game { private SpriteBatch batch; private Texture texture; private OrthographicCamera myCamera; private float w; private float h; private ShaderProgram circleSegShader; private Mesh circleScaleSegMesh; private Stage stage; private float TotalSegments; Vector3 virtualres; @Override public void create() { w = Gdx.graphics.getWidth(); h = Gdx.graphics.getHeight(); batch = new SpriteBatch(); ViewPortsize = new Vector2(); TotalSegments = 4.0f; virtualres = new Vector3(1280.0f, 720.0f, 0.0f); myCamera = new OrthographicCamera(); myCamera.setToOrtho(false, w, h); texture = new Texture(Gdx.files.internal("data/libgdx.png")); texture.setFilter(TextureFilter.Linear, TextureFilter.Linear); circleScaleSegMesh = createCircleMesh_V3(0.0f,0.0f,200.0f, 30.0f,3, (360.0f /TotalSegments) ); circleSegShader = loadShaderFromFile(new String("circleseg.vert"), new String("circleseg.frag")); shaderProgram.pedantic = false; stage = new Stage(); stage.setViewport(new ExtendViewport(w, h)); Gdx.input.setInputProcessor(stage); } @Override public void render() { .... //render renderInit(); renderCircleScaledSegment(); } @Override public void resize(int width, int height) { stage.getViewport().update(width, height, true); myCamera.position.set( virtualres.x/2.0f, virtualres.y/2.0f, 0.0f); myCamera.update(); } public void renderInit(){ Gdx.gl20.glClearColor(1.0f, 1.0f, 1.0f, 0.0f); Gdx.gl20.glClear(GL20.GL_COLOR_BUFFER_BIT | GL20.GL_DEPTH_BUFFER_BIT); batch.setShader(null); batch.setProjectionMatrix(myCamera.combined); } public void renderCircleScaledSegment(){ Gdx.gl20.glEnable(GL20.GL_DEPTH_TEST); Gdx.gl20.glBlendFunc(GL20.GL_SRC_ALPHA, GL20.GL_ONE_MINUS_SRC_ALPHA); Gdx.gl20.glEnable(GL20.GL_BLEND); batch.begin(); circleSegShader.begin(); Matrix4 modelMatrix = new Matrix4(); Matrix4 cameraMatrix = new Matrix4(); Matrix4 cameraMatrix2 = new Matrix4(); Matrix4 cameraMatrix3 = new Matrix4(); Matrix4 cameraMatrix4 = new Matrix4(); cameraMatrix = myCamera.combined.cpy(); modelMatrix.idt().rotate(new Vector3(0.0f,0.0f,1.0f), 0.0f - ((360.0f /TotalSegments)/ 2.0f)).trn(virtualres.x/2.0f,virtualres.y/2.0f, 0.0f); cameraMatrix.mul(modelMatrix); cameraMatrix2 = myCamera.combined.cpy(); modelMatrix.idt().rotate(new Vector3(0.0f,0.0f,1.0f), 0.0f - ((360.0f /TotalSegments)/ 2.0f) +(360.0f /TotalSegments) ).trn(virtualres.x/2.0f,virtualres.y/2.0f, 0.0f); cameraMatrix2.mul(modelMatrix); cameraMatrix3 = myCamera.combined.cpy(); modelMatrix.idt().rotate(new Vector3(0.0f,0.0f,1.0f), 0.0f - ((360.0f /TotalSegments)/ 2.0f) +(2*(360.0f /TotalSegments))).trn(virtualres.x/2.0f,virtualres.y/2.0f, 0.0f); cameraMatrix3.mul(modelMatrix); cameraMatrix4 = myCamera.combined.cpy(); modelMatrix.idt().rotate(new Vector3(0.0f,0.0f,1.0f),0.0f - ((360.0f /TotalSegments)/ 2.0f) +(3*(360.0f /TotalSegments)) ).trn(virtualres.x/2.0f,virtualres.y/2.0f, 0.0f); cameraMatrix4.mul(modelMatrix); Vector3 box2dpos = new Vector3(0.0f, 0.0f, 0.0f); circleSegShader.setUniformMatrix("u_projTrans", cameraMatrix); circleSegShader.setUniformf("u_box2dpos", box2dpos); circleSegShader.setUniformi("u_texture", 0); texture.bind(); circleScaleSegMesh.render(circleSegShader, GL20.GL_TRIANGLES); circleSegShader.setUniformMatrix("u_projTrans", cameraMatrix2); circleSegShader.setUniformf("u_box2dpos", box2dpos); circleSegShader.setUniformi("u_texture", 0); texture.bind(); circleScaleSegMesh.render(circleSegShader, GL20.GL_TRIANGLES); circleSegShader.setUniformMatrix("u_projTrans", cameraMatrix3); circleSegShader.setUniformf("u_box2dpos", box2dpos); circleSegShader.setUniformi("u_texture", 0); texture.bind(); circleScaleSegMesh.render(circleSegShader, GL20.GL_TRIANGLES); circleSegShader.setUniformMatrix("u_projTrans", cameraMatrix4); circleSegShader.setUniformf("u_box2dpos", box2dpos); circleSegShader.setUniformi("u_texture", 0); texture.bind(); circleScaleSegMesh.render(circleSegShader, GL20.GL_TRIANGLES); circleSegShader.end(); batch.flush(); batch.end(); Gdx.gl20.glDisable(GL20.GL_DEPTH_TEST); Gdx.gl20.glDisable(GL20.GL_BLEND); } public Mesh createCircleMesh_V3(float cx, float cy, float r_out, float r_in, int num_segments, float segmentSizeDegrees){ float theta = (float) (2.0f * MathUtils.PI / (num_segments * (360.0f / segmentSizeDegrees))); float c = MathUtils.cos(theta);//precalculate the sine and cosine float s = MathUtils.sin(theta); float t,t2; float x = r_out;//we start at angle = 0 float y = 0; float x2 = r_in;//we start at angle = 0 float y2 = 0; float[] meshCoords = new float[num_segments *2 *3 *7]; int arrayIndex = 0; //array for triangles without indices for(int ii = 0; ii < num_segments; ii++) { meshCoords[arrayIndex] = x2+cx; meshCoords[arrayIndex +1] = y2+cy; meshCoords[arrayIndex +2] = 0.0f; meshCoords[arrayIndex +3] = 63.0f/255.0f; meshCoords[arrayIndex +4] = 139.0f/255.0f; meshCoords[arrayIndex +5] = 217.0f/255.0f; meshCoords[arrayIndex +6] = 0.7f; arrayIndex = arrayIndex + 7; meshCoords[arrayIndex] = x+cx; meshCoords[arrayIndex +1] = y+cy; meshCoords[arrayIndex +2] = 0.0f; meshCoords[arrayIndex +3] = 63.0f/255.0f; meshCoords[arrayIndex +4] = 139.0f/255.0f; meshCoords[arrayIndex +5] = 217.0f/255.0f; meshCoords[arrayIndex +6] = 0.7f; arrayIndex = arrayIndex + 7; t = x; x = c * x - s * y; y = s * t + c * y; meshCoords[arrayIndex] = x+cx; meshCoords[arrayIndex +1] = y+cy; meshCoords[arrayIndex +2] = 0.0f; meshCoords[arrayIndex +3] = 63.0f/255.0f; meshCoords[arrayIndex +4] = 139.0f/255.0f; meshCoords[arrayIndex +5] = 217.0f/255.0f; meshCoords[arrayIndex +6] = 0.7f; arrayIndex = arrayIndex + 7; meshCoords[arrayIndex] = x2+cx; meshCoords[arrayIndex +1] = y2+cy; meshCoords[arrayIndex +2] = 0.0f; meshCoords[arrayIndex +3] = 63.0f/255.0f; meshCoords[arrayIndex +4] = 139.0f/255.0f; meshCoords[arrayIndex +5] = 217.0f/255.0f; meshCoords[arrayIndex +6] = 0.7f; arrayIndex = arrayIndex + 7; meshCoords[arrayIndex] = x+cx; meshCoords[arrayIndex +1] = y+cy; meshCoords[arrayIndex +2] = 0.0f; meshCoords[arrayIndex +3] = 63.0f/255.0f; meshCoords[arrayIndex +4] = 139.0f/255.0f; meshCoords[arrayIndex +5] = 217.0f/255.0f; meshCoords[arrayIndex +6] = 0.7f; arrayIndex = arrayIndex + 7; t2 = x2; x2 = c * x2 - s * y2; y2 = s * t2 + c * y2; meshCoords[arrayIndex] = x2+cx; meshCoords[arrayIndex +1] = y2+cy; meshCoords[arrayIndex +2] = 0.0f; meshCoords[arrayIndex +3] = 63.0f/255.0f; meshCoords[arrayIndex +4] = 139.0f/255.0f; meshCoords[arrayIndex +5] = 217.0f/255.0f; meshCoords[arrayIndex +6] = 0.7f; arrayIndex = arrayIndex + 7; } Mesh myMesh = new Mesh(VertexDataType.VertexArray, false, meshCoords.length, 0, new VertexAttribute(VertexAttributes.Usage.Position, 3, "a_position"), new VertexAttribute(VertexAttributes.Usage.Color, 4, "a_color")); myMesh.setVertices(meshCoords); return myMesh; } }

    Read the article

  • PHP GD Text Transparency..

    - by Deagle
    Hello, I can't slove this. I'm trying to make a text transparency but doesn't work.. Here how it looks: qshort.com/userbar/gd.php Here how if possible to show with transparency: qshort.com/userbar/transparent.png Is that possible? Here my PHP Code: <?php header('Content-type: image/png'); $im = imagecreatefrompng("signature.png"); $white = imagecolorallocate($im, 255, 255, 255); $grey = imagecolorallocate($im, 114, 114, 114); $black = imagecolorallocate($im, 0, 0, 0); $tr = imagecolorallocatealpha($im, 255, 255, 255, 20); $trg = imagecolorallocatealpha($im, 114, 114, 114, 50); $font = 'TCCB.TTF'; $mtext="Money: $0"; $mx="261"; $my="80"; $ms="16"; imagettftext($im, $ms, 0, $mx+1, $my, $grey, $font, $mtext); imagettftext($im, $ms, 0, $mx-1, $my, $grey, $font, $mtext); imagettftext($im, $ms, 0, $mx, $my+1, $grey, $font, $mtext); imagettftext($im, $ms, 0, $mx, $my-1, $grey, $font, $mtext); imagettftext($im, $ms, 0, $mx, $my, $white, $font, $mtext); $atext="Score: 0"; $ax="261"; $ay="100"; $as="16"; imagettftext($im, $as, 0, $ax+1, $ay, $grey, $font, $atext); imagettftext($im, $as, 0, $ax-1, $ay, $grey, $font, $atext); imagettftext($im, $as, 0, $ax, $ay+1, $grey, $font, $atext); imagettftext($im, $as, 0, $ax, $ay-1, $grey, $font, $atext); imagettftext($im, $as, 0, $ax, $ay, $white, $font, $atext); $ctext="Properties: 0"; $cx="261"; $cy="120"; $cs="16"; imagettftext($im, $cs, 0, $cx+1, $cy, $grey, $font, $ctext); imagettftext($im, $cs, 0, $cx-1, $cy, $grey, $font, $ctext); imagettftext($im, $cs, 0, $cx, $cy+1, $grey, $font, $ctext); imagettftext($im, $cs, 0, $cx, $cy-1, $grey, $font, $ctext); imagettftext($im, $cs, 0, $cx, $cy, $white, $font, $ctext); $ntext="Nickname"; $nx="20"; $ny="45"; $ns="35"; imagettftext($im, $ns, 0, $nx+1, $ny, $trg, $font, $ntext); imagettftext($im, $ns, 0, $nx-1, $ny, $trg, $font, $ntext); imagettftext($im, $ns, 0, $nx, $ny+1, $trg, $font, $ntext); imagettftext($im, $ns, 0, $nx, $ny-1, $trg, $font, $ntext); imagettftext($im, $ns, 0, $nx, $ny, $tr, $font, $ntext); imagepng($im); imagedestroy($im); ?> Thanks, Waiting for answer.

    Read the article

  • Sitemap structure for network of subdomains

    - by HaCos
    I am working on a project that's a network of 2 domains (domain.gr & domain.com.cy) of subdomains similar to Hubpages [each user gets a profile under a different subdomain & there is a personal blog for that user as well] and I think there is something wrong with our sitemap submission. Sometimes it takes weeks in order a new profiles to get indexed. We make use of one Webmasters account in order to manage all network and we don't want to create different accounts for each subdomain since there are more than 1000 already. According to this post http://goo.gl/KjMCjN, I end up on a structure of 5 sitemaps with the following structure : 1st sitemap will be for indexing the others. 2nd sitemap for all users profile under the domain.gr 3nd sitemap for all users profile under the domain.com.cy 4th sitemap for all posts under the *.domain.gr - news sitemap http://goo.gl/8A8S9f 5th sitemap for all posts under the *.domain.com.cy - news sitemap again Now my questions: Should we create news sitemaps or just list all post in 2nd & 3rd sitemap? Does links ordering has anything to do? Eg: Most recent user created be first in sitemap or doesn't make any different and we just need to make sure that lastmod date is correct? Does anyone guess how Hubpages submit their sitemap in Webmasters so maybe we could follow there way? Any alternative or better way to index this kind of schema? PS: Our network is multi language - Greek & English are available. We make use of hreflang tags on the head of each page to separate country target of each version.

    Read the article

  • Any reliable polygon normal calculation code?

    - by Jenko
    Do you have any reliable face normal calculation code? I'm using this but it fails when faces are 90 degrees upright or similar. // the normal point var x:Number = 0; var y:Number = 0; var z:Number = 0; // if is a triangle with 3 points if (points.length == 3) { // read vertices of triangle var Ax:Number, Bx:Number, Cx:Number; var Ay:Number, By:Number, Cy:Number; var Az:Number, Bz:Number, Cz:Number; Ax = points[0].x; Bx = points[1].x; Cx = points[2].x; Ay = points[0].y; By = points[1].y; Cy = points[2].y; Az = points[0].z; Bz = points[1].z; Cz = points[2].z; // calculate normal of a triangle x = (By - Ay) * (Cz - Az) - (Bz - Az) * (Cy - Ay); y = (Bz - Az) * (Cx - Ax) - (Bx - Ax) * (Cz - Az); z = (Bx - Ax) * (Cy - Ay) - (By - Ay) * (Cx - Ax); // if is a polygon with 4+ points }else if (points.length > 3){ // calculate normal of a polygon using all points var n:int = points.length; x = 0; y = 0; z = 0 // ensure all points above 0 var minx:Number = 0, miny:Number = 0, minz:Number = 0; for (var p:int = 0, pl:int = points.length; p < pl; p++) { var po:_Point3D = points[p] = points[p].clone(); if (po.x < minx) { minx = po.x; } if (po.y < miny) { miny = po.y; } if (po.z < minz) { minz = po.z; } } if (minx > 0 || miny > 0 || minz > 0){ for (p = 0; p < pl; p++) { po = points[p]; po.x -= minx; po.y -= miny; po.z -= minz; } } var cur:int = 1, prev:int = 0, next:int = 2; for (var i:int = 1; i <= n; i++) { // using Newell method x += points[cur].y * (points[next].z - points[prev].z); y += points[cur].z * (points[next].x - points[prev].x); z += points[cur].x * (points[next].y - points[prev].y); cur = (cur+1) % n; next = (next+1) % n; prev = (prev+1) % n; } } // length of the normal var length:Number = Math.sqrt(x * x + y * y + z * z); // if area is 0 if (length == 0) { return null; }else{ // turn large values into a unit vector x = x / length; y = y / length; z = z / length; }

    Read the article

  • How to prevent latex memory overflow

    - by drasto
    I've got a latex macro that makes small pictures. In that picture I need to draw area. Borders of that area are quadratic bezier curves and that area is to be filled. I did not know how to do it so currently I'm "filling" the area by drawing a plenty of bezier curves inside it... This slows down typeseting and when a macro is used multiple times (so tex is drawing really a lot of quadratic bezier curves) it produces following error: ! TeX capacity exceeded, sorry [main memory size=3000000]. How can I prevent this error ? (by freeing memory after macro or such...) Or even better how do I fill the area determined by two quadratic bezier curves? Code that produces error: \usepackage{forloop} \usepackage{picture} \usepackage{eepic} ... \linethickness{\lineThickness\unitlength}% \forloop[\lineThickness]{cy}{\cymin}{\value{cy} < \cymax}{% \qbezier(\ax, \ay)(\cx, \value{cy})(\bx, \by)% }% Here are some example values for variables: \setlength{\unitlength}{0.01pt} \lineThickness=20 %cy is just a counter - inital value is not important \cymin=450 \cymax=900 %from following only the difference between \ax and \bx is important \ax=0 \ay=0 \bx=550 \by=0 Note: To reproduce the error this code have to execute approximately 150 times (could be more depending on your latex memory settings). Thanks a lot for any help

    Read the article

  • Center text inside a circle on a canvas

    - by jax
    I have the coordinates of the center of a circle where I need to draw some text. The circle may be larger or smaller depending on the attributes I have specified. I have set the center horizontally using mTextBrush.setTextAlign(Align.CENTER);. The problem is that I can't figure out a way to center the text vertically. (See "Draw the counter" below) //Text Brush setup mTextBrush = new Paint(Paint.ANTI_ALIAS_FLAG); mTextBrush.setColor(Color.BLACK); mTextBrush.setTextSize(1/10*mMaxSize); mTextBrush.setTextAlign(Align.CENTER); mTextBrush.setStyle(Paint.Style.STROKE); private void drawSmallTimer(Canvas canvas) { //Variable cache int radiusLocalCache = this.mRadius; int cx = radiusLocalCache+(radiusLocalCache/2); int cy = radiusLocalCache-(radiusLocalCache/2); int radius = radiusLocalCache/3; //Draw the background circle canvas.drawCircle(cx, cy, radius, mBackgroundBrush); //Draw the outline stroke canvas.drawCircle(cx, cy, radius, mStrokeBrush); //Draw the counter String text = String.valueOf(mCounter); canvas.drawText(text, cx, cy, mTextBrush); }

    Read the article

  • Help with this optimization

    - by Milo
    Here is what I do: I have bitmaps which I draw into another bitmap. The coordinates are from the center of the bitmap, thus on a 256 by 256 bitmap, an object at 0.0,0.0 would be drawn at 128,128 on the bitmap. I also found the furthest extent and made the bitmap size 2 times the extent. So if the furthest extent is 200,200 pixels, then the bitmap's size is 400,400. Unfortunately this is a bit inefficient. If a bitmap needs to be drawn at 500,500 and the other one at 300,300, then the target bitmap only needs to be 200,200 in size. I cannot seem to find a correct way to draw in the components correctly with a reduced size. I figure out the target bitmap size like this: float AvatarComposite::getFloatWidth(float& remainder) const { float widest = 0.0f; float widestNeg = 0.0f; for(size_t i = 0; i < m_components.size(); ++i) { if(m_components[i].getSprite() == NULL) { continue; } float w = m_components[i].getX() + ( ((m_components[i].getSprite()->getWidth() / 2.0f) * m_components[i].getScale()) / getWidthToFloat()); float wn = m_components[i].getX() - ( ((m_components[i].getSprite()->getWidth() / 2.0f) * m_components[i].getScale()) / getWidthToFloat()); if(w > widest) { widest = w; } if(wn > widest) { widest = wn; } if(w < widestNeg) { widestNeg = w; } if(wn < widestNeg) { widestNeg = wn; } } remainder = (2 * widest) - (widest - widestNeg); return widest - widestNeg; } And here is how I position and draw the bitmaps: int dw = m_components[i].getSprite()->getWidth() * m_components[i].getScale(); int dh = m_components[i].getSprite()->getHeight() * m_components[i].getScale(); int cx = (getWidth() + (m_remainderX * getWidthToFloat())) / 2; int cy = (getHeight() + (m_remainderY * getHeightToFloat())) / 2; cx -= m_remainderX * getWidthToFloat(); cy -= m_remainderY * getHeightToFloat(); int dx = cx + (m_components[i].getX() * getWidthToFloat()) - (dw / 2); int dy = cy + (m_components[i].getY() * getHeightToFloat()) - (dh / 2); g->drawScaledSprite(m_components[i].getSprite(),0.0f,0.0f, m_components[i].getSprite()->getWidth(),m_components[i].getSprite()->getHeight(),dx,dy, dw,dh,0); I basically store the difference between the original 2 * longest extent bitmap and the new optimized one, then I translate by that much which I would think would cause me to draw correctly but then some of the components look cut off. Any insight would help. Thanks

    Read the article

  • determine collision angle on a rotating body

    - by jorb
    update: new diagram and updated description I have a contact listener set up to try and determine the side that a collision happened at relative to the a bodies rotation. One way to solve this is to find the value of the yellow angle between the red and blue vectors drawn above. The angle can be found by taking the arc cosine of the dot product of the two vectors (Evan pointed this out). One of my points of confusion is the difference in domain of the atan2 function html canvas coordinates and the Box2d rotation information. I know I have to account for this somehow... SS below questions: Does Box2D provide these angles more directly in the collision information? Am I even on the right track? If so, any hints? I have the following javascript so far: Ship.prototype.onCollide = function (other_ent,cx,cy) { var pos = this.body.GetPosition(); //collision position relative to body var d_cx = pos.x - cx; var d_cy = pos.y - cy; //length of initial vector var len = Math.sqrt(Math.pow(pos.x -cx,2) + Math.pow(pos.y-cy,2)); //body angle - can over rotate hence mod 2*Pi var ang = this.body.GetAngle() % (Math.PI * 2); //vector representing body's angle - same magnitude as the first var b_vx = len * Math.cos(ang); var b_vy = len * Math.sin(ang); //dot product of the two vectors var dot_prod = d_cx * b_vx + d_cy * b_vy; //new calculation of difference in angle - NOT WORKING! var d_ang = Math.acos(dot_prod); var side; if (Math.abs(d_ang) < Math.PI/2 ) side = "front"; else side = "back"; console.log("length",len); console.log("pos:",pos.x,pos.y); console.log("offs:",d_cx,d_cy); console.log("body vec",b_vx,b_vy); console.log("body angle:",ang); console.log("dot product",dot_prod); console.log("result:",d_ang); console.log("side",side); console.log("------------------------"); }

    Read the article

  • Why are there 3 conflicting OpenCV camera calibration formulas?

    - by John
    I'm having a problem with OpenCV's various parameterization of coordinates used for camera calibration purposes. The problem is that three different sources of information on image distortion formulae apparently give three non-equivalent description of the parameters and equations involved: (1) In their book "Learning OpenCV…" Bradski and Kaehler write regarding lens distortion (page 376): xcorrected = x * ( 1 + k1 * r^2 + k2 * r^4 + k3 * r^6 ) + [ 2 * p1 * x * y + p2 * ( r^2 + 2 * x^2 ) ], ycorrected = y * ( 1 + k1 * r^2 + k2 * r^4 + k3 * r^6 ) + [ p1 * ( r^2 + 2 * y^2 ) + 2 * p2 * x * y ], where r = sqrt( x^2 + y^2 ). Assumably, (x, y) are the coordinates of pixels in the uncorrected captured image corresponding to world-point objects with coordinates (X, Y, Z), camera-frame referenced, for which xcorrected = fx * ( X / Z ) + cx and ycorrected = fy * ( Y / Z ) + cy, where fx, fy, cx, and cy, are the camera's intrinsic parameters. So, having (x, y) from a captured image, we can obtain the desired coordinates ( xcorrected, ycorrected ) to produced an undistorted image of the captured world scene by applying the above first two correction expressions. However... (2) The complication arises as we look at OpenCV 2.0 C Reference entry under the Camera Calibration and 3D Reconstruction section. For ease of comparison we start with all world-point (X, Y, Z) coordinates being expressed with respect to the camera's reference frame, just as in #1. Consequently, the transformation matrix [ R | t ] is of no concern. In the C reference, it is expressed that: x' = X / Z, y' = Y / Z, x'' = x' * ( 1 + k1 * r'^2 + k2 * r'^4 + k3 * r'^6 ) + [ 2 * p1 * x' * y' + p2 * ( r'^2 + 2 * x'^2 ) ], y'' = y' * ( 1 + k1 * r'^2 + k2 * r'^4 + k3 * r'^6 ) + [ p1 * ( r'^2 + 2 * y'^2 ) + 2 * p2 * x' * y' ], where r' = sqrt( x'^2 + y'^2 ), and finally that u = fx * x'' + cx, v = fy * y'' + cy. As one can see these expressions are not equivalent to those presented in #1, with the result that the two sets of corrected coordinates ( xcorrected, ycorrected ) and ( u, v ) are not the same. Why the contradiction? It seems to me the first set makes more sense as I can attach physical meaning to each and every x and y in there, while I find no physical meaning in x' = X / Z and y' = Y / Z when the camera focal length is not exactly 1. Furthermore, one cannot compute x' and y' for we don't know (X, Y, Z). (3) Unfortunately, things get even murkier when we refer to the writings in Intel's Open Source Computer Vision Library Reference Manual's section Lens Distortion (page 6-4), which states in part: "Let ( u, v ) be true pixel image coordinates, that is, coordinates with ideal projection, and ( u ~, v ~ ) be corresponding real observed (distorted) image coordinates. Similarly, ( x, y ) are ideal (distortion-free) and ( x ~, y ~ ) are real (distorted) image physical coordinates. Taking into account two expansion terms gives the following: x ~ = x * ( 1 + k1 * r^2 + k2 * r^4 ) + [ 2 p1 * x * y + p2 * ( r^2 + 2 * x^2 ) ] y ~ = y * ( 1 + k1 * r^2 + k2 * r^4 ] + [ 2 p2 * x * y + p2 * ( r^2 + 2 * y^2 ) ], where r = sqrt( x^2 + y^2 ). ... "Because u ~ = cx + fx * u and v ~ = cy + fy * v , … the resultant system can be rewritten as follows: u ~ = u + ( u – cx ) * [ k1 * r^2 + k2 * r^4 + 2 * p1 * y + p2 * ( r^2 / x + 2 * x ) ] v ~ = v + ( v – cy ) * [ k1 * r^2 + k2 * r^4 + 2 * p2 * x + p1 * ( r^2 / y + 2 * y ) ] The latter relations are used to undistort images from the camera." Well, it would appear that the expressions involving x ~ and y ~ coincided with the two expressions given at the top of this writing involving xcorrected and ycorrected. However, x ~ and y ~ do not refer to corrected coordinates, according to the given description. I don't understand the distinction between the meaning of the coordinates ( x ~, y ~ ) and ( u ~, v ~ ), or for that matter, between the pairs ( x, y ) and ( u, v ). From their descriptions it appears their only distinction is that ( x ~, y ~ ) and ( x, y ) refer to 'physical' coordinates while ( u ~, v ~ ) and ( u, v ) do not. What is this distinction all about? Aren't they all physical coordinates? I'm lost! Thanks for any input!

    Read the article

  • Security tips for adding wireless AP to domain network?

    - by Cy
    I am researching best-practices for adding wireless to our existing domain network. My DHCP server is running Windows Server 03 Standard (not sure if thats useful). I am familiar with simple home networking but I thought I'd get some expert advice for the more advanced stuff. Any tips and / or best-practices? Is this Cisco Wireless Access Point a good option? Are there any additional hardware recommendations? Thank you in advance for your help.

    Read the article

  • Connect ADSL modem SMC7904WBRA-N to CISCO RV082

    - by Cy.
    I have a SMC7904WBRA-N ADSL modem/router that connects to the internet with a static IP given by the provider. I've received a RV082 to create a VPN connection which is having problems to connect to the remote VPN Server. After many tries we deduced that the SMC7904WBRA-N is being problematic with the NAT and I have been suggested to put the SMC router into the appropriate DSL bridging mode so the RV082 gets direct access to internet with the static IP. Can you give me any hints on how could this be done? Which mode is that?

    Read the article

  • CenterPoint in CGContextAddArc ?

    - by Mikhail Naimy
    Hi , i am drawing Arc through CGCOntext.I want to draw a string in the center Point of Arc.how can i fond the center point in the Arc which has been drawn through CGContext. CGContextSetAlpha(ctx, 0.5); CGContextSetRGBFillColor(ctx, color.red, color.green, color.blue, color.alpha ); CGContextMoveToPoint(ctx, cX, cY); CGContextAddArc(ctx, cX, cY, radious+10, (startDeg-90)*M_PI/180.0, (endDeg-90)*M_PI/180.0, 0); CGContextClosePath(ctx); CGContextFillPath(ctx);

    Read the article

  • Converting HTML TAG Object to JSON Object

    - by cooldude
    Hi, I want to convert the html tag objects to json object in the javascript in order to send them to the server from the javascript. As i have to save these objects at the Ruby on Rails server. These HTML objects is the canvas tag object and the graphics objects created using CAKE API. I have used the stringify function but it is not working. Here is my code: var CAKECanvas = new Canvas(document.body, 1000,1000); var canvas=CAKECanvas.canvas; var text=document.createElement('textarea'); text.id="text"; text.rows="100"; text.cols="200"; document.body.appendChild(text); canvas.style.borderStyle="solid"; canvas.style.borderColor="black"; var rect= new Circle(); rect.radius=100; rect.centered=true; rect.cx=Math.random() * 500; rect.cy= Math.random() * 300; rect.stroke= false; rect.fill= "red"; rect.xDir = Math.random() > 0.5?1:-1; rect.yDir = Math.random() > 0.5?1:-1; var obj=new Object; var count = 0,k; for (k in rect) { if (rect.hasOwnProperty(k)) { count++; obj[k]=rect[k]; } } alert(count); rect.addFrameListener(function(t, dt) { this.cx += this.xDir * 50 * dt/1000; this.cy += this.yDir * 50 * dt/1000; if (this.cx > 550) { this.xDir = -1; } if (this.cx < 50) { this.xDir = 1; } if (this.cy > 350) { this.yDir = -1; } if (this.cy < 50) { this.yDir = 1; } } ); CAKECanvas.append(rect); var carAsJSON = JSON.stringify(obj); /////////////////ERROR

    Read the article

1 2 3 4  | Next Page >