Daily Archives

Articles indexed Sunday October 21 2012

Page 12/14 | < Previous Page | 8 9 10 11 12 13 14  | Next Page >

  • In 12.04, with my Linksys WUSB54G USB adapter I can see the networks, but cannot connect to any of them

    - by tobye
    I recently loaded Ubuntu version 12.04 onto my computer, and I have a WUSB54G v4 USB wireless adapter. I first tried to get it to work by simply plugging my adapter into an open USB port. This seemed to work fine, it came up with a list of wireless adapters, so I clicked on the correct one and entered the security code. It looked like it was going to connect. It tried for about five minutes before I stopped it. I then decided to create a network as I also have one setup. I did this and it connected, only one problem, I couldn't get onto the internet. Please help me, I am new to Ubuntu and am totally lost.

    Read the article

  • cannot log in to all account except guest after mounting new partition

    - by student
    I really really need help. to do my homework from school, since two days ago, I was installing oracle 11g on my ubuntu. through that process, there was lots of problems also, but searching a lot, in somehow I could go to the next phase installing it. (because it was the first time to install on ubuntu by myself..) but when I was making password for oracle and clicked next, it says there are not enough space for home/oracle folder, So to make another space, I mounted another space after checking Gparted and using Software device management, I mounted it. And when I rebooted it, since then, I cannot log in to my own administrator account and even to oracle account(that I made for oracle 11g on ubuntu ) when I type the passwords for it, it seems to work but it redisplay the first page to log in, without really logging in it.. So I loggined to here as guest account... and even I cannot try gnome console manipulation to restore or fix it.. because it is guest account... I`m struggling for three days and... help me, how do I need to do? and at the time oracle said it needs enough space for its home folder, how I should have done?

    Read the article

  • Ubuntu 12.10 is slow and some programs gose to non-respond state

    - by user99631
    Ubuntu 12.10 is so slow and a lot of not responding applications I was using Skype whenever i open it it will go to non-responding state thin back to normal after a while even the software centre the system process is eating the CPU I don’t know if the compiz is the problem but issuing the command compiz --replace restore the applications from non-responding state CPU : Intel Celeron D 3.4 RAM : 1 GB VGA : Intel G45 Plz help

    Read the article

  • Ubuntu fail to start on a dual boot with Windows 7 on Vaio

    - by user94628
    I followed the instructions for the Ubuntu windows installer on my Sony Vaio laptop (model SVT131A11M). Upon restart I was prompt to choose the OS for boot (Win7 or Ubuntu), but then I shut down the machine and from the next boot, every time I choose to boot into Ubuntu, the GNU GRUB terminal appears with a grub> prompt. Now I'm able to boot into Win7, but can't boot into Ubuntu properly. Why does it happen and how come I was able to start Ubuntu successfully the first time?

    Read the article

  • Python (v2.7) requires to install plugins to create media files of the following type: Vorbis encoder

    - by LibraryGeekAdam
    This is the message I get when I try to rip a cd from any player. I usually use the stock Rhythmbox but have tried others to no avail. I have just updated to 12.10 from 12.04 and I had no problems in 12.04. I have read the other posts and have switched to the Main Server in the Software Sources menu. I have installed Ubuntu Restricted Extras. Nothing seems to help. I would appreciate any help. "Python (v2.7) requires to install plugins to create media files of the following type: Vorbis encoder" Thanks!

    Read the article

  • Can't boot Ubuntu 12.10 32 or 64 Bit, only Ubuntu 12.04 32 Bit [closed]

    - by Alexander
    Possible Duplicate: My computer boots to a black screen, what options do I have to fix it? i tried to install Ubuntu 12.04 64Bit, 12.10 32 and 64Bit, but it doesn't work. I'm used the Ubuntu 12.04 32Bit Start Disc Creator and also Unetboot on Win7, the installation-process are finished and i restart without the Stick. I can choose for example 12.10 and it starts writing "start ... [OK], ...", but then it hangs most on "Stop Kernel Messages [OK]". Then i can only shutdown normal the system and it writes stopping, shutdown and something like that. I am use an Aspire One D270 Netbook with Intel Atom N2600. It also doesn't work to try Ubuntu 12.10 from running on USB Stick. It starts, but then its black and the cursor blink on the left upside. Please can you help me? :(

    Read the article

  • High temperature on my laptop with Radeon Mobility HD4670

    - by Lorthirk
    As almost everyone here, I guess, in these days I downloaded Quantal Quetzal to give it a try. However I noticed that my laptop runs fairly hot with cooling fans almost always on, even sitting in the desktop doing nothing. I downloaded XSensor to read temperature sensors, and I saw that while CPU stays on about 65°C, so quiet normal I guess, the GPU sits at 75°C. In comparison my actual Windows 7 installation, which dual boots witb Quantal, stays at 59°C CPU and 65°C. So I went reading and learned that AMD dropped support for my video card from fglrx package, and that fglrx-legacy won't support 1.13 Xorg, so I'm basically stuck with OSS drivers. So I was guessing if there's anything I can try, and if it's possible that the OSS drivers could be the cause of the high temperature?

    Read the article

  • ubuntu 12.10 The location is not a folder [closed]

    - by psychok7
    i just upgraded my Ubuntu to 12.10 and i noticed that i get this message The location is not a folder whenever i try to access a mounted media (USB or even my other partitions). I am now unable to view content on my usb pendrive or other partitions. already tried sudo apt-get remove exo-utils with no luck because it says it is not installed. Can anyone help me? UPDATE: this workaround seems to work for me http://askubuntu.com/a/204226/59618

    Read the article

  • How to adjust the appearance of the Unity in 12.10?

    - by piedro
    Now I updated to 12.10 and would like to adjust the desktop, well unity, appearance. I know there is the theme setting, but I cannot adjust the symbol theme or windows decoration with the systemsettings. I used to use the tool "unsettings" but it doesn't work with 12.10 anymore. Ubuntu Tweak used to be an option but at this point many features are broken and a lot of settings seem to mess up my system or they don't change anything at all (I understand that there has been a design settings change - gsettings, dconf, something ...) myunity has some options to change stuff but I couldn't find it for 12.10 ... not to forget "gnome-tweak-tool" which seems to work for most settings but not for all, e.g. it doesn't change the mouse cursor and the windows decorations do not show some decorations I'd like to use and I am also afraid of messing things up because it is supposed to be used in gnomeshell ... actually as I found out right now it really messes things up: fonts get inverted, suddenly high contrast accessibility setings are used in some windows, nautilus has white fonts on white background and even the login manager is a mess now ... So: How can I adjust the theme, symbol, decorations, fonts for the normal user and for the desktop and for the applications including the applications started as sudo user? I should mention that I upgraded from 12.04 and that some applications like synaptic completely ignore any settings ... sadly it is a mess, there was a time when gnome theming was really well done and very adjustable, I wonder what happened ... Just now I read that further development of Ubuntu Tweak has been stopped. The developer announced that he won't go any further with the software and the online services ... That is sad and destroys my hope for easy appearance editing just by waiting ... has been such a nice tool for 12.04 ... r.i.p.

    Read the article

  • Ubuntu 12.10 Trackpoint not detected Thinkpad X130e

    - by killerknives
    I just did a fresh install of 12.10 and now only my touchpad works. The trackpoint and Left/Right buttons below the trackpoint do not work. The trackpoint worked fine as of 12.04. I've searched online and there was a hack that said that disabling the touchpad would enable the trackpoint. WRONG! You'll end up having to use the keyboard =/. I don't know what is needed so I'll just dump some stuff. lspci: 00:00.0 Host bridge: Advanced Micro Devices [AMD] Family 14h Processor Root Complex 00:01.0 VGA compatible controller: Advanced Micro Devices [AMD] nee ATI Wrestler [Radeon HD 6310] 00:01.1 Audio device: Advanced Micro Devices [AMD] nee ATI Wrestler HDMI Audio [Radeon HD 6250/6310] 00:05.0 PCI bridge: Advanced Micro Devices [AMD] Family 14h Processor Root Port 00:06.0 PCI bridge: Advanced Micro Devices [AMD] Family 14h Processor Root Port 00:07.0 PCI bridge: Advanced Micro Devices [AMD] Family 14h Processor Root Port 00:11.0 SATA controller: Advanced Micro Devices [AMD] nee ATI SB7x0/SB8x0/SB9x0 SATA Controller [AHCI mode] 00:12.0 USB controller: Advanced Micro Devices [AMD] nee ATI SB7x0/SB8x0/SB9x0 USB OHCI0 Controller 00:12.2 USB controller: Advanced Micro Devices [AMD] nee ATI SB7x0/SB8x0/SB9x0 USB EHCI Controller 00:13.0 USB controller: Advanced Micro Devices [AMD] nee ATI SB7x0/SB8x0/SB9x0 USB OHCI0 Controller 00:13.2 USB controller: Advanced Micro Devices [AMD] nee ATI SB7x0/SB8x0/SB9x0 USB EHCI Controller 00:14.0 SMBus: Advanced Micro Devices [AMD] nee ATI SBx00 SMBus Controller (rev 42) 00:14.2 Audio device: Advanced Micro Devices [AMD] nee ATI SBx00 Azalia (Intel HDA) (rev 40) 00:14.3 ISA bridge: Advanced Micro Devices [AMD] nee ATI SB7x0/SB8x0/SB9x0 LPC host controller (rev 40) 00:14.4 PCI bridge: Advanced Micro Devices [AMD] nee ATI SBx00 PCI to PCI Bridge (rev 40) 00:18.0 Host bridge: Advanced Micro Devices [AMD] Family 12h/14h Processor Function 0 (rev 43) 00:18.1 Host bridge: Advanced Micro Devices [AMD] Family 12h/14h Processor Function 1 00:18.2 Host bridge: Advanced Micro Devices [AMD] Family 12h/14h Processor Function 2 00:18.3 Host bridge: Advanced Micro Devices [AMD] Family 12h/14h Processor Function 3 00:18.4 Host bridge: Advanced Micro Devices [AMD] Family 12h/14h Processor Function 4 00:18.5 Host bridge: Advanced Micro Devices [AMD] Family 12h/14h Processor Function 6 00:18.6 Host bridge: Advanced Micro Devices [AMD] Family 12h/14h Processor Function 5 00:18.7 Host bridge: Advanced Micro Devices [AMD] Family 12h/14h Processor Function 7 01:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8188CE 802.11b/g/n WiFi Adapter (rev 01) 02:00.0 Ethernet controller: Atheros Communications Inc. AR8151 v2.0 Gigabit Ethernet (rev c0) I've installged gpointing-device-setting and it only lists the touchpad. No trackpoint. What should I do? What data do you need?

    Read the article

  • Lenovo ThinkPad Edge E430 Battery Problem

    - by LEo
    On Ubuntu's Web Page, in the Certified hardware section, it is listed Lenovo. http://www.ubuntu.com/certification/ So I decided to buy a ThinkPad from Lenovo. Just one month after I bought the notebook, the battery got a problem and it does not charge anymore. Now Lenovo won't give me any support because I am using Ubuntu. Lenovo says they will give support only for Windows users because their tools runs on Windows. They refused to change my battery before running the Windows based test. What should I do?

    Read the article

  • Getting "boot error" when trying to boot from USB

    - by Jon Ball
    I'm wanting to try out Ubuntu, so followed the instructions for how to install Ubuntu onto a USB. I downloaded the .iso file, then the pendrivelinux 3 part process to make the USB bootable. I can see what looks like a full list of files on the USB (including the wubi.exe application and the syslinux folder). When I try to restart the computer with the USB in, I get the Dell start up screen, and then a black screen with "Boot Error" in the top right hand corner. Setup options (default) are to boot from Removable Device, then Hard Disc. USB is brand new, straight out of the packet. Computer: Dell Inspiron 530S BIOS: 1.0.13 OS: Windows Vista Home Edition USB: EMTEC 8Gb, formatted to FAT32 I've tried some of the tips in other help topics (holding down CTRL key while restarting, removing all other USB devices). I tried to reformat the USB to something other than FAT32, but my only other options were NTFS or exFAT (not FAT16 which was suggested in another topic).

    Read the article

  • How to permanently disable touchpad in 12.04?

    - by Andreas
    I'm looking for a way to permanently disable the touchpad in Ubuntu 12.04 (my computer is a Lenovo Thinkpad Edge on which it isn't possible to disable it in the BIOS). I tried the applications GPointingDeviceSettings and synaptiks 0.8.1 as well as the applets touchpad-indicator and Jupiter. None of these does the trick of disabling the touchpad permanently. Jupiter comes closest - it remembers that I have disabled the touchpad after restart - but when I login after the computer has been in suspend mode, the touchpad is enabled again. Can anyone help me in disabling the touchpad possibly at a lower level so it won't in any way be enabled unless I choose to enable it? I'm totally new to linux so a detailed explanation would be much appreciated ... The links, so far, doesn't address my question. I have no problem turning the touchpad off and making it stay off after reboot but when I login after the computer has been in an altered power mode it's on again. Isn't there a way to permanently disable a device like touchpad?

    Read the article

  • Webcam Q&A page with guest "speakers" ideas?

    - by myladeybugg
    I want to host one way webcam Q&A's/AMA's and embed it on my sites webpage. I must be able to have specified hosts for these Q&A's connect quickly and easily to the webpage, and read user posted messages (questions) for interaction. I know there are some systems out there, like tinychat, but I'm unaware if there is anything exactly used for what I am looking for. Perhaps requiring a specific account/password before allowing streaming on the page, where I can email the host a password or directions to create an account to begin live streaming. Most of these people doing the question and answers on webcam will have little technical knowledge, so extra cookie points goes to ease of use! Thanks for ideas in advance! PS: I apologize if this is the incorrect section for posting this question, this is my first.

    Read the article

  • Inheriting projects - General Rules?

    - by pspahn
    This is an area of discussion I have long been curious about, but overall, I generally lack the experience to give myself an answer that I would fully trust. We've all been there, a new client shows up with a half-complete project they are looking to finish and launch. For whatever reason, they fired their previous developer, and it's now up to you to save the day. I am just finishing up a code review for a new client, and in my estimation is would be better to scrap what the previous developers built since and start from scratch. There's a ton of reasons why I am leaning toward this way, but it still makes me nervous since the client isn't going to want to hear "those last guys built you a big turd, and I can either polish it, or throw it in the trash". What are your general rules for accepting these projects? How do you determine whether it will be better to start from scratch or continue with the existing code base? What other extra steps might you take to help control client expectations, since the previous developer may have inflated those expectations beyond a reasonable level? Any other general advice?

    Read the article

  • Choosing a CSS grid/framework

    - by jonallard
    There are many grids and framework to choose from. A Google search for CSS frameworks will return a dozen articles that themselves list a number of frameworks to choose from. When it comes to choosing one, it's easy to be lost without having an intimate knowledge of all of them. What are the main factors that go into choosing a CSS framework, and how will those choices map to certain frameworks? More generally, how does one choose a CSS framework? Note 1: I'm using "grid" and "framework" almost interchangeably here, but there is probably one I should use over the other. Corrections on this are welcome. Note 2: I am well aware that some choices will depend on taste and accordingly, this question can turn into a "best of" contest/subjective topic. I'm trying to keep it as answerable as possible, as I'm pretty sure many have this problem/question of choosing a framework and an answer to that would benefit the community. As such, improvements to this question are welcome rather than just closing it.

    Read the article

  • How can I create a content widget generator?

    - by Richard
    Sites like Buzzfeed offer widgets (Javascript, PHP, WordPress, etc.) for syndicating their content on other sites. Does anyone have any ideas on how I could go about creating/implementing some kind of interactive widget generator that gives users options for customizing their widget? I assume this would require RSS. Check out the Buzzfeed generator to see what I mean http://www.buzzfeed.com/network/widget

    Read the article

  • CCSpriteHole in cocos2d 2.0?

    - by rakkarage
    i was using this cocos2d class CCSpriteHole in cocos2d 1.0 fine... http://jpsarda.tumblr.com/post/15779708304/new-cocos2d-iphone-extensions-a-progress-bar-and-a i am trying to convert it to cocos2d 2.0... i got it to compile by changing glVertexPointer to glVertexAttribPointer like in the 2.0 version of CCSpriteScale9 here http://jpsarda.tumblr.com/post/9162433577/scale9grid-for-cocos2d and changing contentSizeInPixels_ to contentSize_... -(id) init { if( (self=[super init]) ) { opacityModifyRGB_ = YES; opacity_ = 255; color_ = colorUnmodified_ = ccWHITE; capSize=capSizeInPixels=CGSizeZero; //Not used blendFunc_.src = CC_BLEND_SRC; blendFunc_.dst = CC_BLEND_DST; // update texture (calls updateBlendFunc) [self setTexture:nil]; // default transform anchor anchorPoint_ = ccp(0.5f, 0.5f); vertexDataCount=24; vertexData = (ccV2F_C4F_T2F*) malloc(vertexDataCount * sizeof(ccV2F_C4F_T2F)); [self setTextureRectInPixels:CGRectZero untrimmedSize:CGSizeZero]; } return self; } -(id) initWithTexture:(CCTexture2D*)texture rect:(CGRect)rect { NSAssert(texture!=nil, @"Invalid texture for sprite"); // IMPORTANT: [self init] and not [super init]; if( (self = [self init]) ) { [self setTexture:texture]; [self setTextureRect:rect]; } return self; } -(id) initWithTexture:(CCTexture2D*)texture { NSAssert(texture!=nil, @"Invalid texture for sprite"); CGRect rect = CGRectZero; rect.size = texture.contentSize; return [self initWithTexture:texture rect:rect]; } -(id) initWithFile:(NSString*)filename { NSAssert(filename!=nil, @"Invalid filename for sprite"); CCTexture2D *texture = [[CCTextureCache sharedTextureCache] addImage: filename]; if( texture ) return [self initWithTexture:texture]; return nil; } +(id)spriteWithFile:(NSString*)f { return [[self alloc] initWithFile:f]; } - (void) dealloc { if (vertexData) free(vertexData); } -(void) updateColor { ccColor4F color4; color4.r=(float)color_.r/255.0f; color4.g=(float)color_.g/255.0f; color4.b=(float)color_.b/255.0f; color4.a=(float)opacity_/255.0f; for (int i=0; i<vertexDataCount; i++) { vertexData[i].colors=color4; } } -(void)updateTextureCoords:(CGRect)rect { CCTexture2D *tex = texture_; if(!tex) return; float atlasWidth = (float)tex.pixelsWide; float atlasHeight = (float)tex.pixelsHigh; float left,right,top,bottom; left = rect.origin.x/atlasWidth; right = left + rect.size.width/atlasWidth; top = rect.origin.y/atlasHeight; bottom = top + rect.size.height/atlasHeight; // // |/|/|/| // CGSize capTexCoordsSize=CGSizeMake(capSizeInPixels.width/atlasWidth, capSizeInPixels.height/atlasHeight); // From left to right //Top band // Left vertexData[0].texCoords=(ccTex2F){left,top}; vertexData[1].texCoords=(ccTex2F){left,top+capTexCoordsSize.height}; vertexData[2].texCoords=(ccTex2F){left+capTexCoordsSize.width,top}; vertexData[3].texCoords=(ccTex2F){left+capTexCoordsSize.width,top+capTexCoordsSize.height}; // Center vertexData[4].texCoords=(ccTex2F){right-capTexCoordsSize.width,top}; vertexData[5].texCoords=(ccTex2F){right-capTexCoordsSize.width,top+capTexCoordsSize.height}; // Right vertexData[6].texCoords=(ccTex2F){right,top}; vertexData[7].texCoords=(ccTex2F){right,top+capTexCoordsSize.height}; //Center band // Left vertexData[8].texCoords=(ccTex2F){left,bottom-capTexCoordsSize.height}; vertexData[9].texCoords=(ccTex2F){left,top+capTexCoordsSize.height}; vertexData[10].texCoords=(ccTex2F){left+capTexCoordsSize.width,bottom-capTexCoordsSize.height}; vertexData[11].texCoords=(ccTex2F){left+capTexCoordsSize.width,top+capTexCoordsSize.height}; // Center vertexData[12].texCoords=(ccTex2F){right-capTexCoordsSize.width,bottom-capTexCoordsSize.height}; vertexData[13].texCoords=(ccTex2F){right-capTexCoordsSize.width,top+capTexCoordsSize.height}; // Right vertexData[14].texCoords=(ccTex2F){right,bottom-capTexCoordsSize.height}; vertexData[15].texCoords=(ccTex2F){right,top+capTexCoordsSize.height}; //Bottom band //Left vertexData[16].texCoords=(ccTex2F){left,bottom}; vertexData[17].texCoords=(ccTex2F){left,bottom-capTexCoordsSize.height}; vertexData[18].texCoords=(ccTex2F){left+capTexCoordsSize.width,bottom}; vertexData[19].texCoords=(ccTex2F){left+capTexCoordsSize.width,bottom-capTexCoordsSize.height}; // Center vertexData[20].texCoords=(ccTex2F){right-capTexCoordsSize.width,bottom}; vertexData[21].texCoords=(ccTex2F){right-capTexCoordsSize.width,bottom-capTexCoordsSize.height}; // Right vertexData[22].texCoords=(ccTex2F){right,bottom}; vertexData[23].texCoords=(ccTex2F){right,bottom-capTexCoordsSize.height}; } -(void) updateVertices { float left=0; //-spriteSizeInPixels.width*0.5f; float right=left+contentSize_.width; float bottom=0; //-spriteSizeInPixels.height*0.5f; float top=bottom+contentSize_.height; float holeLeft=holeRect.origin.x*CC_CONTENT_SCALE_FACTOR(); float holeRight=holeLeft+holeRect.size.width*CC_CONTENT_SCALE_FACTOR(); float holeBottom=holeRect.origin.y*CC_CONTENT_SCALE_FACTOR(); float holeTop=holeBottom+holeRect.size.height*CC_CONTENT_SCALE_FACTOR(); // // |/|/|/| // // From left to right //Top band // Left vertexData[0].vertices=(ccVertex2F){left,top}; vertexData[1].vertices=(ccVertex2F){left,holeTop}; vertexData[2].vertices=(ccVertex2F){holeLeft,top}; vertexData[3].vertices=(ccVertex2F){holeLeft,holeTop}; // Center vertexData[4].vertices=(ccVertex2F){holeRight,top}; vertexData[5].vertices=(ccVertex2F){holeRight,holeTop}; // Right vertexData[6].vertices=(ccVertex2F){right,top}; vertexData[7].vertices=(ccVertex2F){right,holeTop}; //Center band // Left vertexData[8].vertices=(ccVertex2F){left,holeBottom}; vertexData[9].vertices=(ccVertex2F){left,holeTop}; vertexData[10].vertices=(ccVertex2F){holeLeft,holeBottom}; vertexData[11].vertices=(ccVertex2F){holeLeft,holeTop}; // Center vertexData[12].vertices=(ccVertex2F){holeRight,holeBottom}; vertexData[13].vertices=(ccVertex2F){holeRight,holeTop}; // Right vertexData[14].vertices=(ccVertex2F){right,holeBottom}; vertexData[15].vertices=(ccVertex2F){right,holeTop}; //Bottom band //Left vertexData[16].vertices=(ccVertex2F){left,bottom}; vertexData[17].vertices=(ccVertex2F){left,holeBottom}; vertexData[18].vertices=(ccVertex2F){holeLeft,bottom}; vertexData[19].vertices=(ccVertex2F){holeLeft,holeBottom}; // Center vertexData[20].vertices=(ccVertex2F){holeRight,bottom}; vertexData[21].vertices=(ccVertex2F){holeRight,holeBottom}; // Right vertexData[22].vertices=(ccVertex2F){right,bottom}; vertexData[23].vertices=(ccVertex2F){right,holeBottom}; } -(void) setHole:(CGRect)r inRect:(CGRect)totalSurface { holeRect=r; self.contentSize=totalSurface.size; holeRect.origin=ccpSub(holeRect.origin,totalSurface.origin); CGPoint holeCenter=ccp(holeRect.origin.x+holeRect.size.width*0.5f,holeRect.origin.y+holeRect.size.height*0.5f); self.anchorPoint=ccp(holeCenter.x/contentSize_.width,holeCenter.y/contentSize_.height); //[self updateTextureCoords:rectInPixels_]; [self updateVertices]; [self updateColor]; } -(void) draw { BOOL newBlend = NO; if( blendFunc_.src != CC_BLEND_SRC || blendFunc_.dst != CC_BLEND_DST ) { newBlend = YES; glBlendFunc( blendFunc_.src, blendFunc_.dst ); } glBindTexture(GL_TEXTURE_2D, [texture_ name]); glVertexAttribPointer(kCCVertexAttrib_Position, 2, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[0].vertices); glVertexAttribPointer(kCCVertexAttrib_TexCoords, 2, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[0].texCoords); glVertexAttribPointer(kCCVertexAttrib_Color, 4, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[0].colors); glDrawArrays(GL_TRIANGLE_STRIP, 0, 8); glVertexAttribPointer(kCCVertexAttrib_Position, 2, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[8].vertices); glVertexAttribPointer(kCCVertexAttrib_TexCoords, 2, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[8].texCoords); glVertexAttribPointer(kCCVertexAttrib_Color, 4, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[8].colors); glDrawArrays(GL_TRIANGLE_STRIP, 0, 8); glVertexAttribPointer(kCCVertexAttrib_Position, 2, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[16].vertices); glVertexAttribPointer(kCCVertexAttrib_TexCoords, 2, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[16].texCoords); glVertexAttribPointer(kCCVertexAttrib_Color, 4, GL_FLOAT, GL_FALSE, sizeof(ccV2F_C4F_T2F), &vertexData[16].colors); glDrawArrays(GL_TRIANGLE_STRIP, 0, 8); if( newBlend ) glBlendFunc(CC_BLEND_SRC, CC_BLEND_DST); } -(void)setTextureRectInPixels:(CGRect)rect untrimmedSize:(CGSize)untrimmedSize { rectInPixels_ = rect; rect_ = CC_RECT_PIXELS_TO_POINTS( rect ); //[self setContentSizeInPixels:untrimmedSize]; [self updateTextureCoords:rectInPixels_]; } -(void)setTextureRect:(CGRect)rect { CGRect rectInPixels = CC_RECT_POINTS_TO_PIXELS( rect ); [self setTextureRectInPixels:rectInPixels untrimmedSize:rectInPixels.size]; } // // RGBA protocol // #pragma mark CCSpriteHole - RGBA protocol -(GLubyte) opacity { return opacity_; } -(void) setOpacity:(GLubyte) anOpacity { opacity_ = anOpacity; // special opacity for premultiplied textures if( opacityModifyRGB_ ) [self setColor: (opacityModifyRGB_ ? colorUnmodified_ : color_ )]; [self updateColor]; } - (ccColor3B) color { if(opacityModifyRGB_){ return colorUnmodified_; } return color_; } -(void) setColor:(ccColor3B)color3 { color_ = colorUnmodified_ = color3; if( opacityModifyRGB_ ){ color_.r = color3.r * opacity_/255; color_.g = color3.g * opacity_/255; color_.b = color3.b * opacity_/255; } [self updateColor]; } -(void) setOpacityModifyRGB:(BOOL)modify { ccColor3B oldColor = self.color; opacityModifyRGB_ = modify; self.color = oldColor; } -(BOOL) doesOpacityModifyRGB { return opacityModifyRGB_; } #pragma mark CCSpriteHole - CocosNodeTexture protocol -(void) updateBlendFunc { if( !texture_ || ! [texture_ hasPremultipliedAlpha] ) { blendFunc_.src = GL_SRC_ALPHA; blendFunc_.dst = GL_ONE_MINUS_SRC_ALPHA; [self setOpacityModifyRGB:NO]; } else { blendFunc_.src = CC_BLEND_SRC; blendFunc_.dst = CC_BLEND_DST; [self setOpacityModifyRGB:YES]; } } -(void) setTexture:(CCTexture2D*)texture { // accept texture==nil as argument NSAssert( !texture || [texture isKindOfClass:[CCTexture2D class]], @"setTexture expects a CCTexture2D. Invalid argument"); texture_ = texture; [self updateBlendFunc]; } -(CCTexture2D*) texture { return texture_; } @end but now positioning and scaling seem to not work? and it starts in the wrong position... but changing the opacity still works. so i was wondering if anyone can see why my 2.0 version is not working? or if maybe there is a better way to do a sprite hole with cocos2d/opengl 2.0? shaders? thanks

    Read the article

  • Is there any hueristic to polygonize a closed 2d-raster shape with n triangles?

    - by Arthur Wulf White
    Lets say we have a 2d image black on white that shows a closed geometric shape. Is there any (not naive brute force) algorithm that approximates that shape as closely as possible with n triangles? If you want a formal definition for as closely as possible: Approximate the shape with a polygon that when rendered into a new 2d image will match the largest number of pixels possible with the original image.

    Read the article

  • jBullet Collision/Physics not working correctly

    - by Kenneth Bray
    Below is the code for one of my objects in the game I am creating (yes although this is a cube, I am not making anything remotely like MineCraft), and my issue is I while the cube will display and is does follow the physics if the cube falls, it does not interact with any other objects in the game. If I was to have multiple cubes in screen at once they all just sit there, or shoot off in all directions never stopping. Anyway, I am new to jBullet, and any help would be appreciated. package Object; import static org.lwjgl.opengl.GL11.GL_QUADS; import static org.lwjgl.opengl.GL11.glBegin; import static org.lwjgl.opengl.GL11.glColor3f; import static org.lwjgl.opengl.GL11.glEnd; import static org.lwjgl.opengl.GL11.glPopMatrix; import static org.lwjgl.opengl.GL11.glPushMatrix; import static org.lwjgl.opengl.GL11.glVertex3f; import javax.vecmath.Matrix4f; import javax.vecmath.Quat4f; import javax.vecmath.Vector3f; import com.bulletphysics.collision.shapes.BoxShape; import com.bulletphysics.collision.shapes.CollisionShape; import com.bulletphysics.dynamics.RigidBody; import com.bulletphysics.dynamics.RigidBodyConstructionInfo; import com.bulletphysics.linearmath.DefaultMotionState; import com.bulletphysics.linearmath.Transform; public class Cube { // Cube size/shape variables private float size; boolean cubeCollidable; boolean cubeDestroyable; // Position variables - currently this defines the center of the cube private float posX; private float posY; private float posZ; // Rotation variables - should be between 0 and 359, might consider letting rotation go higher though I can't think of a purpose currently private float rotX; private float rotY; private float rotZ; //collision shape is a box shape CollisionShape fallShape; // setup the motion state for the ball DefaultMotionState fallMotionState; Vector3f fallInertia = new Vector3f(0, 1, 0); RigidBodyConstructionInfo fallRigidBodyCI; public RigidBody fallRigidBody; int mass = 1; // Constructor public Cube(float pX, float pY, float pZ, float pSize) { posX = pX; posY = pY; posZ = pZ; size = pSize; rotX = 0; rotY = 0; rotZ = 0; // define the physics based on the values passed in fallShape = new BoxShape(new Vector3f(size, size, size)); fallMotionState = new DefaultMotionState(new Transform(new Matrix4f(new Quat4f(0, 0, 0, 1), new Vector3f(0, 50, 0), 1f))); fallRigidBodyCI = new RigidBodyConstructionInfo(mass, fallMotionState, fallShape, fallInertia); fallRigidBody = new RigidBody(fallRigidBodyCI); } public void Update() { Transform trans = new Transform(); fallRigidBody.getMotionState().getWorldTransform(trans); posY = trans.origin.x; posX = trans.origin.y; posZ = trans.origin.z; } public void Draw() { fallShape.calculateLocalInertia(mass, fallInertia); // center point posX, posY, posZ float radius = size / 2; //top glPushMatrix(); glBegin(GL_QUADS); { glColor3f(1.0f,0.0f,0.0f); // red glVertex3f(posX + radius, posY + radius, posZ - radius); glVertex3f(posX - radius, posY + radius, posZ - radius); glVertex3f(posX - radius, posY + radius, posZ + radius); glVertex3f(posX + radius, posY + radius, posZ + radius); } glEnd(); glPopMatrix(); //bottom glPushMatrix(); glBegin(GL_QUADS); { glColor3f(1.0f,1.0f,0.0f); // ?? color glVertex3f(posX + radius, posY - radius, posZ + radius); glVertex3f(posX - radius, posY - radius, posZ + radius); glVertex3f(posX - radius, posY - radius, posZ - radius); glVertex3f(posX + radius, posY - radius, posZ - radius); } glEnd(); glPopMatrix(); //right side glPushMatrix(); glBegin(GL_QUADS); { glColor3f(1.0f,0.0f,1.0f); // ?? color glVertex3f(posX + radius, posY + radius, posZ + radius); glVertex3f(posX + radius, posY - radius, posZ + radius); glVertex3f(posX + radius, posY - radius, posZ - radius); glVertex3f(posX + radius, posY + radius, posZ - radius); } glEnd(); glPopMatrix(); //left side glPushMatrix(); glBegin(GL_QUADS); { glColor3f(0.0f,1.0f,1.0f); // ?? color glVertex3f(posX - radius, posY + radius, posZ - radius); glVertex3f(posX - radius, posY - radius, posZ - radius); glVertex3f(posX - radius, posY - radius, posZ + radius); glVertex3f(posX - radius, posY + radius, posZ + radius); } glEnd(); glPopMatrix(); //front side glPushMatrix(); glBegin(GL_QUADS); { glColor3f(0.0f,0.0f,1.0f); //blue glVertex3f(posX + radius, posY + radius, posZ + radius); glVertex3f(posX - radius, posY + radius, posZ + radius); glVertex3f(posX - radius, posY - radius, posZ + radius); glVertex3f(posX + radius, posY - radius, posZ + radius); } glEnd(); glPopMatrix(); //back side glPushMatrix(); glBegin(GL_QUADS); { glColor3f(0.0f,1.0f,0.0f); // green glVertex3f(posX + radius, posY - radius, posZ - radius); glVertex3f(posX - radius, posY - radius, posZ - radius); glVertex3f(posX - radius, posY + radius, posZ - radius); glVertex3f(posX + radius, posY + radius, posZ - radius); } glEnd(); glPopMatrix(); } }

    Read the article

  • Determine how to display a tile based on surrounding tiles

    - by Jsmith
    I have a game engine which generates maps randomly, set on a 2d grid which is composed of 34px square graphical tiles. These tiles can be displayed in any of three ways, wall, corner, and floor(exists in 2 states, passable and impassible), and four directions, north, south, west and east. What I need to do is, based on the tiles around each individual tile, determine which state to display the tile in, e.g. north wall, northeast corner, floor so that when a player alters the map, the tiles around the affected tile adjust themselves to suit(i.e. tunneling). In case it becomes important, all gameobjects are inherited from the same class, whether they be players, NPC's, walls, or items.

    Read the article

  • Read only array, deep copy or retrieve copies one by one? (Performance and Memory)

    - by Arthur Wulf White
    In a garbage collection based system, what is the most effective way to handle a read only array if such a structure does not exist natively in the language. Is it better to return a copy of an array or allow other classes to retrieve copies of the objects stored in the array one by one? @JustinSkiles: It is not very broad. It is performance related and can actually be answered specifically for two general cases. You only need very few items: in this situation it's more effective to retrieve copies of the objects one by one. You wish to iterate over 30% or more objects. In this cases it is superior to retrieve all the array at once. This saves on functions calls. Function calls are very expansive when compared to reading directly from an array. A good specific answer could include performance, reading from an array and reading indirectly through a function. It is a simple performance related question.

    Read the article

  • AndEngine GLES2 - getting Black screen on emulator 4.1

    - by dizworld.com
    I'm new in andengine . I create following code public class MainActivity extends BaseGameActivity { static final int CAMERA_WIDTH = 800; static final int CAMERA_HEIGHT = 480; public Font mFont; public Camera mCamera; //A reference to the current scene public Scene mCurrentScene; public static BaseActivity instance; public EngineOptions onCreateEngineOptions() { instance = this; mCamera = new Camera(0, 0, CAMERA_WIDTH, CAMERA_HEIGHT); return new EngineOptions(true, ScreenOrientation.LANDSCAPE_SENSOR, new RatioResolutionPolicy(CAMERA_WIDTH, CAMERA_HEIGHT), mCamera); } @Override public void onCreateResources(OnCreateResourcesCallback arg0) throws Exception { mFont = FontFactory.create(this.getFontManager(),this.getTextureManager(), 256, 256,Typeface.create(Typeface.DEFAULT, Typeface.BOLD), 32); mFont.load(); } @Override public void onCreateScene(OnCreateSceneCallback arg0) throws Exception { mEngine.registerUpdateHandler(new FPSLogger()); mCurrentScene = new Scene(); Log.v("Scene","enter"); mCurrentScene.setBackground(new Background(0.09804f, 0.7274f, 0.8f)); // return mCurrentScene; } @Override public void onPopulateScene(Scene arg0, OnPopulateSceneCallback arg1) throws Exception { // TODO Auto-generated method stub } } I got code on sites there is returning scene but in AndEngine GLES2 in method onCreateScene() there is no return scene ... so my First run is BLACK .. any suggestion :)

    Read the article

  • I have an "amoeba" game mechanic. Any idea on how to implement it?

    - by Jason
    Outside of a tetris clone, a crappy 2D top-down shooter, and some messing around with stuff like Unity and Flixel, I realize that I have yet to complete a single, polished, bells-and-whistles game. I want to change this, and I have an idea for my next project. The idea is that you're an amoeba. Amoebas have these eye-like cores (or something like that, I don't know biology), and you have two of 'em. You control one with WASD and the other with IJKL. There has to be a constant radius of stuff around each of the cores: And the area of the amoeba has to stay constant. So if you move a core in one direction, you increase the amoeba's area, but that increase is compensated by a decrease somewhere else: Aaaaaand I'd like to implement a vagination mechanic. You absorb things by engulfing them, like a boss. Maybe even an extra core, or a needle that pops you and causes all your inner stuff to start gushing out: But here's the problem: I don't know how to make this. However, I would like some ideas on how to implement it. Should I explore physics libraries like Box2D? Or maybe something involving fluid physics? Any help would be much appreciated. P.S. Feel free to steal this idea. I have plenty of ideas. If you do, please tell me how you made it so I can try it myself.

    Read the article

  • How can I protect my save data from casual hacking?

    - by Danran
    What options are there for saving game data in a secure manner? I'm interested in solutions specifically tailored for C++. I'm looking for something that is fast and easy to use. I'm only concerned about storing simple information such as Which levels are and are not unlocked The user's score for each level I'm curious again to know what's out there to use, any good libraries to use that give me nice, secure game data files that the average player can't mess with. I just found this here which looks very nice, but it would be great to get some opinions on potential other libraries/options out there.

    Read the article

< Previous Page | 8 9 10 11 12 13 14  | Next Page >