Search Results

Search found 1532 results on 62 pages for 'macosx iam'.

Page 41/62 | < Previous Page | 37 38 39 40 41 42 43 44 45 46 47 48  | Next Page >

  • Problem trying to install PyCurl on Mac Snow Leopard

    - by Ldn
    Hi, My app needs to use PyCurl, so i tried to install it on my Mac but i found a lot of problems and error :( Requirement: First of all i've to say that the version of Python working on my Mac is 32 bit based, because i need to use WxPython, that needs 32 bit Python. For doing this i used: defaults write com.apple.versioner.python Prefer-32-Bit -bool yes To install PyCurl i used: sudo env ARCHFLAGS="-arch x86_64" easy_install setuptools pycurl And the terminal returned: Best match: setuptools 0.6c11 Processing setuptools-0.6c11-py2.6.egg setuptools 0.6c11 is already the active version in easy-install.pth Installing easy_install script to /usr/local/bin Installing easy_install-2.6 script to /usr/local/bin Using /Library/Python/2.6/site-packages/setuptools-0.6c11-py2.6.egg Processing dependencies for setuptools Finished processing dependencies for setuptools Searching for pycurl Best match: pycurl 7.16.2.1 Processing pycurl-7.16.2.1-py2.6-macosx-10.6-universal.egg pycurl 7.16.2.1 is already the active version in easy-install.pth Using /Library/Python/2.6/site-packages/pycurl-7.16.2.1-py2.6-macosx-10.6-universal.egg Processing dependencies for pycurl Finished processing dependencies for pycurl so i thought that pycurl was correctly installed and working. But... But when i started my app, python return me an error: python /Users/lorenzodenobili/Desktop/Python/AGGIORNATORE_PY/Dropbox/wxPython/test.py Traceback (most recent call last): File "/Users/lorenzodenobili/Desktop/Python/AGGIORNATORE_PY/Dropbox/wxPython/test.py", line 20, in <module> import pycurl File "build/bdist.macosx-10.6-universal/egg/pycurl.py", line 7, in <module> File "build/bdist.macosx-10.6-universal/egg/pycurl.py", line 6, in __bootstrap__ ImportError: dlopen(/Users/lorenzodenobili/.python-eggs/pycurl-7.16.2.1-py2.6-macosx-10.6-universal.egg-tmp/pycurl.so, 2): no suitable image found. Did find: /Users/lorenzodenobili/.python-eggs/pycurl-7.16.2.1-py2.6-macosx-10.6-universal.egg-tmp/pycurl.so: mach-o, but wrong architecture Yep, there is something quite big that goes wrong. I really don't have any idea on how to solve this error, so i really need your help! thank you so much!!

    Read the article

  • error when plotting log'd array in matplotlib/scipy/numpy

    - by user248237
    I have two arrays and I take their logs. When I do that and try to plot their scatter plot, I get this error: File "/Library/Python/2.6/site-packages/matplotlib-1.0.svn_r7892-py2.6-macosx-10.6-universal.egg/matplotlib/pyplot.py", line 2192, in scatter ret = ax.scatter(x, y, s, c, marker, cmap, norm, vmin, vmax, alpha, linewidths, faceted, verts, **kwargs) File "/Library/Python/2.6/site-packages/matplotlib-1.0.svn_r7892-py2.6-macosx-10.6-universal.egg/matplotlib/axes.py", line 5384, in scatter self.add_collection(collection) File "/Library/Python/2.6/site-packages/matplotlib-1.0.svn_r7892-py2.6-macosx-10.6-universal.egg/matplotlib/axes.py", line 1391, in add_collection self.update_datalim(collection.get_datalim(self.transData)) File "/Library/Python/2.6/site-packages/matplotlib-1.0.svn_r7892-py2.6-macosx-10.6-universal.egg/matplotlib/collections.py", line 153, in get_datalim offsets = transOffset.transform_non_affine(offsets) File "/Library/Python/2.6/site-packages/matplotlib-1.0.svn_r7892-py2.6-macosx-10.6-universal.egg/matplotlib/transforms.py", line 1924, in transform_non_affine self._a.transform(points)) File "/Library/Python/2.6/site-packages/matplotlib-1.0.svn_r7892-py2.6-macosx-10.6-universal.egg/matplotlib/transforms.py", line 1420, in transform return affine_transform(points, mtx) ValueError: Invalid vertices array. the code is simply: myarray_x = log(my_array[:, 0]) myarray_y = log(my_array[:, 1]) plt.scatter(myarray_x, myarray_y) any idea what could be causing this? thanks.

    Read the article

  • How can I use Django with MySQL in MAMP stack?

    - by Robert A Henru
    Hi all, I have difficulty especially in installing MySQLdb module (MySQL-python-1.2.3c1), to connect to the MySQL in MAMP stack. I've done a number of things such as copying the mysql include directory and library (including plugin) from a fresh installation of mysql (version 5.1.47) to the one inside MAMP (version 5.1.37). Now, the MySQLdb module build and install doesnt give me error. The error happens when I'm calling 'import MySQLdb' from python shell (version 2.6). Traceback (most recent call last): File "<stdin>", line 1, in <module> File "build/bdist.macosx-10.6-universal/egg/MySQLdb/__init__.py", line 19, in <module> File "build/bdist.macosx-10.6-universal/egg/_mysql.py", line 7, in <module> File "build/bdist.macosx-10.6-universal/egg/_mysql.py", line 6, in __bootstrap__ ImportError: dlopen(/Users/rhenru/.python-eggs/MySQL_python-1.2.3c1-py2.6-macosx-10.6-universal.egg-tmp/_mysql.so, 2): Symbol not found: _mysql_affected_rows Referenced from: /Users/rhenru/.python-eggs/MySQL_python-1.2.3c1-py2.6-macosx-10.6-universal.egg-tmp/_mysql.so Expected in: flat namespace in /Users/rhenru/.python-eggs/MySQL_python-1.2.3c1-py2.6-macosx-10.6-universal.egg-tmp/_mysql.so Any idea, what else do I need to do to make it works? Thanks a bunch, Robert

    Read the article

  • mysql-python on Snow Leopard with MySQL 64-bit

    - by Derek Reynolds
    Can't seem to get mysql-python to work on Snow Leopard for the life of me. Currently using the default version of python that ships with Snow Leopard (python 2.6.1). Installed MySQL 5.1.45 x86_64. I download the source for mysql-python http://sourceforge.net/projects/mysql-python/ and compile with the following commands: tar xzf MySQL-python-1.2.3c1.tar.gz cd MySQL-python-1.2.3c1 ARCHFLAGS='-arch x86_64' python setup.py build ARCHFLAGS='-arch x86_64' python setup.py install And am getting the following error when I try to import: Python 2.6.1 (r261:67515, Jul 7 2009, 23:51:51) [GCC 4.2.1 (Apple Inc. build 5646)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> import MySQLdb Traceback (most recent call last): File "<stdin>", line 1, in <module> File "build/bdist.macosx-10.6-universal/egg/MySQLdb/__init__.py", line 19, in <module> File "build/bdist.macosx-10.6-universal/egg/_mysql.py", line 7, in <module> File "build/bdist.macosx-10.6-universal/egg/_mysql.py", line 6, in __bootstrap__ ImportError: dlopen(/Users/derek/.python-eggs/MySQL_python-1.2.3c1-py2.6-macosx-10.6-universal.egg-tmp/_mysql.so, 2): no suitable image found. Did find: /Users/derek/.python-eggs/MySQL_python-1.2.3c1-py2.6-macosx-10.6-universal.egg-tmp/_mysql.so: mach-o, but wrong architecture Any ideas? Or the best route for starting over.

    Read the article

  • Firefox on wine crashes on startup on Ubuntu

    - by Iam Zesh
    First, let's explain why I want Firefox under wine, and not the Firefox that is shipped out of the box with Ubuntu. I want to use Firefox under wine because I want to use the Widevine addon, which is "at this time not available for linux". Here is what I did so far to install and use Firefox on wine. On Ubuntu 12.04 LTS, I just installed wine like that: sudo apt-get update; sudo apt-get install wine Then I downloaded the windows installer for Firefox from the mozilla website. I ran the Firefox Setup 25.0.exe file with wine but at the end of the install process when launching Firefox, I got a window notifying me that the program at crashed. I ran Firefox from the command line with wine, to get an idea of what could have went wrong: wine /home/myUser/.wine/drive_c/Program\ Files/Mozilla\ Firefox/firefox.exe fixme:heap:HeapSetInformation (nil) 1 (nil) 0 fixme:process:SetProcessDEPPolicy (1): stub fixme:iphlpapi:NotifyAddrChange (Handle 0x368e8fc, overlapped 0x368e8e0): stub fixme:winsock:WSCGetProviderPath ({e70f1aa0-ab8b-11cf-8ca3-00805f48a192} 0x44fe6f8 0x44fe6b8 0x44fe6e4) Stub! fixme:advapi:RegisterTraceGuidsW (0x1b0e290, 0x39ead80, {509962e0-406b-46f4-99ba-5a009f8d2225}, 3, 0x3974d00, (null), (null), 0x39eadb0,): stub fixme:winsock:WSCGetProviderPath ({e70f1aa0-ab8b-11cf-8ca3-00805f48a192} 0x44fe6f8 0x44fe6b8 0x44fe6e4) Stub! fixme:winsock:WSCGetProviderPath ({11058240-be47-11cf-95c8-00805f48a192} 0x44fe6f8 0x44fe6b8 0x44fe6e4) Stub! fixme:winsock:WSCGetProviderPath ({11058241-be47-11cf-95c8-00805f48a192} 0x44fe6f8 0x44fe6b8 0x44fe6e4) Stub! fixme:winsock:WSCGetProviderPath ({11058241-be47-11cf-95c8-00805f48a192} 0x44fe6f8 0x44fe6b8 0x44fe6e4) Stub! fixme:ntdll:NtLockFile I/O completion on lock not implemented yet fixme:advapi:SetNamedSecurityInfoW L"C:\\users\\myUser\\Application Data\\Mozilla\\Firefox\\Profiles\\cn4oy6kh.default\\extensions.ini" 1 536870916 (nil) (nil) 0x13d40c (nil) fixme:imm:ImmReleaseContext (0x20022, 0x13e850): stub fixme:win:EnumDisplayDevicesW ((null),0,0x32ee18,0x00000000), stub! fixme:shell:ApplicationAssociationRegistration_QueryCurrentDefault (0x143b50)->(L"webcal", 1, 1, 0x32c7a0) fixme:shell:ApplicationAssociationRegistration_QueryCurrentDefault (0x143b50)->(L"ircs", 1, 1, 0x32c7a0) fixme:shell:ApplicationAssociationRegistration_QueryCurrentDefault (0x143b50)->(L"mailto", 1, 1, 0x32c7a0) fixme:shell:ApplicationAssociationRegistration_QueryCurrentDefault (0x143b50)->(L"irc", 1, 1, 0x32c7a0) fixme:alsa:AudioSessionControl_SetGroupingParam (0x153050)->({7b0a93ee-05e7-4576-9cc5-64fdf201f303}, (null)) - stub fixme:alsa:AudioSessionControl_SetGroupingParam (0x153050)->({00000000-0000-0000-0000-000000000000}, (null)) - stub fixme:alsa:AudioSessionControl_UnregisterAudioSessionNotification (0x153050)->(0x6311880) - stub wine: Call from 0x7b839cf2 to unimplemented function dwmapi.dll.DwmGetCompositionTimingInfo, aborting fixme:dbghelp:elf_search_auxv can't find symbol in module Unfortunately I don't know what to do from there on...

    Read the article

  • Ubuntu Sluggish and Graphics Problem after Nvidia Driver Update

    - by iam
    I just recently started using Ubuntu (12.04) since a few weeks ago and noticed that the interface is very slow and sluggish: On Dash, I have to type the entire app name and wait a few seconds before it shows up in the search box, and a bit later before it displays search result Opening new files or applications takes also quite long and awkward Dragging icons or moving app windows around is not very spontaneous too: I have to take extra attention in moving the mouse otherwise Ubuntu would not do a correct movement or might ends up doing something incorrect instead e.g. opening the windows to full screen options or move the file to different folders, which is frustrating My PC is a few years old already (1.7 GB RAM) so this could be a reason too but when I checked in System Monitor it's hardly ever consuming much memory. Plus web-surfing on Firefox is actually lightning fast (much more than Windows), so I suspect there might be something wrong with the graphics driver (mine is GeForce 7050). I checked around System Settings and found an option to update the Nvidia driver. So I tried it and restarted, as instructed. Now, I got into a big problem upon restart... as the login-screen windows (where I have to type in the password) would take several attempts to display and finally did not manage to (it'd freeze for several seconds before there's any movement again). The background screen also kept reloading several times too and at some point the screen turned black with pixelated color strips running on the bottom 1/3 of the screen, and after a long while the background screen would come up again. Eventually I'd manage to be able to access the desktop but the launcher, top menu bar and app windows border would not disappear. I searched around and found many other people have this similar problem after updating Nvidia driver too, and on some threads the suggestion is to use "killall -u $USER" in command line (it's the only thing among various online suggestions I could do, as at that point I could not access Terminal without the launcher - Ctrl-Alt-T doesn't work for me). So I did that and was able to access the desktop correctly again with launchee/menu by creating a new account. But I would still have the same problem if logging into my original account. So I just finally tried upgrading to 12.10 and now can access my original account with fully-functional desktop - the launcher, menu and windows border are all back now. However, the problem with sluggishness still remains. And now I get scared of ever having to update the Nvidia driver again! I wonder if anyone knows what's the reason that updating the Nvidia driver is causing this problem and is there a way I can update it safely in the future? I'm still not sure how to solve the problem with the sluggishness too and not sure where else to look to find a solution.

    Read the article

  • Print Problem: Page Squeezed in Half

    - by iam
    I've just managed to successfully set up my printer (Canon MX320) using the Printing app on Ubuntu 12.04. However the only 1 remaining problem is that each time I tried to print it will only print the file on the top half of the page only: meaning that for some reason, the printer "squeezes" the whole content of each page in the file to fit into the top half of the page only (so the proportion in the print-out is not correct vertically). This happens with every type of file I tried to print (Documents, Images, Web pages). I checked the Printing's setting & properties and couldn't find anything related to this issue yet and I've already made sure to set all the information correct (paper size, source etc.). The Print Preview always display correctly on the screen, but it's only the actual print-out that shows this problem. I also tried with several different types of papers (A4, photos etc.) but the result is always the same: the printer keeps putting the content in the top half of the paper only.

    Read the article

  • I am getting this error on using matplotlib

    - by Arun Abraham
    I get this error on typing this in python command prompt: import matplotlib.pyplot as plt Traceback (most recent call last): File "<pyshell#1>", line 1, in <module> import matplotlib.pyplot as plt File "/Library/Python/2.7/site-packages/matplotlib-1.3.x-py2.7-macosx-10.8-intel.egg/matplotlib/pyplot.py", line 97, in <module> _backend_mod, new_figure_manager, draw_if_interactive, _show = pylab_setup() File "/Library/Python/2.7/site-packages/matplotlib-1.3.x-py2.7-macosx-10.8-intel.egg/matplotlib/backends/__init__.py", line 25, in pylab_setup globals(),locals(),[backend_name]) File "/Library/Python/2.7/site-packages/matplotlib-1.3.x-py2.7-macosx-10.8-intel.egg/matplotlib/backends/backend_macosx.py", line 21, in <module> from matplotlib.backends import _macosx ImportError: dlopen(/Library/Python/2.7/site-packages/matplotlib-1.3.x-py2.7-macosx-10.8-intel.egg/matplotlib/backends/_macosx.so, 2): Library not loaded: /System/Library/Frameworks/CoreText.framework/Versions/A/CoreText Referenced from: /Library/Python/2.7/site-packages/matplotlib-1.3.x-py2.7-macosx-10.8-intel.egg/matplotlib/backends/_macosx.so Reason: image not found Can someone suggest me, how i can fix this ? I had installed all the packages with this shell script https://github.com/fonnesbeck/ScipySuperpack Is there anything that i am missing ? Any additional configuration ?

    Read the article

  • Can't import obj in Python on OS X 10.6.3 Snow Leopard - libiconv.2.dylib?

    - by James
    on OS X 10.6.3 Snow Leopard % python Python 2.6.1 (r261:67515, Feb 11 2010, 00:51:29) [GCC 4.2.1 (Apple Inc. build 5646)] on darwin Type "help", "copyright", "credits" or "license" for more information. import objc Traceback (most recent call last): File "", line 1, in File "/Library/Python/2.6/site-packages/pyobjc_core-2.2-py2.6-macosx-10.6-universal.egg/objc/__init__.py", line 22, in _update() File "/Library/Python/2.6/site-packages/pyobjc_core-2.2-py2.6-macosx-10.6-universal.egg/objc/__init__.py", line 19, in _update import _objc ImportError: dlopen(/Library/Python/2.6/site-packages/pyobjc_core-2.2-py2.6-macosx-10.6-universal.egg/objc/_objc.so, 2): Library not loaded: /opt/local/lib/libiconv.2.dylib Referenced from: /Library/Python/2.6/site-packages/pyobjc_core-2.2-py2.6-macosx-10.6-universal.egg/objc/_objc.so Reason: Incompatible library version: _objc.so requires version 8.0.0 or later, but libiconv.2.dylib provides version 7.0.0 -- what do I need to do?

    Read the article

  • problem in leigeber's sorting

    - by developer
    iam using leigeber's sorting javascript to sort my data on my page......i took the js from here :- leigeber's sorting javascript Now this is shwoing highlighted sorted column and all and its all perfect.Now iam having some negative and some positive values in my data and i want to show those negative data in red color and positive in green.This whole sorting thing is using js and css to do the highlighting and sorting.Iam a bit confused now and cant make it out that how i can assign red color to the negative ones and green to the positive ones as js is returning the data as an object i.e. a complete row and i cant make 1 column's data red or green.Will it be done by js itself or with the help of stylesheet to find -ves and +ves.Im totally lost and dont know how to do it.Please help!!!! this is an example of hte data iam using this whole sorting thing on:- -Name- -Price- -loss- -Pts- abc 361.15 -5.68 -21.75 abc2 1072.35 -5.24 -59.25 abc3 512.35 5.24 28.35 abc4 335.2 -5.02 -17.7 abc5 318.6 5.01 -16.8 abc6 76.15 -4.15 3.3

    Read the article

  • Can I start my new Career as a web application developer over an age of 32

    - by Sami
    Greetings Guys.. Iam 32 years old, I graduated from university in 2005 but from that time I didnt work in my career as a developer,and I dont have any experience in that major. My current career is software testing, but actually iam not satisfied in that job since i dont see any future for it and i dont know its path (to where will I arrive). Now i decided to take extra cources in VB.net, asp.net since I want to change my career to become webdeveloper. But 1 thing that always desturb me is that I feel that time is passed iam iam too old to become web developer. Is my feeling true?? and are there any poeple who start programing at a late age and did the succeed?? Thanks

    Read the article

  • incrementing a table column's data by one || mySql

    - by Praveen Prasad
    iam having a table with columns like id || counter if i do something (some event) i want the counter's value(at a particular id) to increase by one , currently iam doing this : //get current value current_value = select counter from myTable where id='someValue' // increase value current_value++ //update table with current value update myTable set counter=current_value where id='someValue'; currently iam running 2 queries for this, please suggest me some way do it in one step.

    Read the article

  • How do I run compiled java classes with GPU libraries (Jogamp JOCL)?

    - by jam383
    Does anyone know how to run the java code from the command line with dependency on GPU libraries in this case Jogamps JOCL. I have compiled a test program HelloJOCL.java but I get an error during run time. I tried javac -classpath "./lib/jocl.jar:./lib/jocl-natives-macosx-universal.jar:./lib/jocl-natives-linux-i586.jar:./lib/jocl-natives-linux-amd64.jar:./lib/gluegen-rt.jar:./lib/gluegen-rt-natives-linux-amd64.jar:./lib/gluegen-rt-natives-macosx-universal.jar:./lib/gluegen-rt-natives-linux-i586.jar" ./HelloJOCL.java java -classpath "./lib/jocl.jar:./lib/jocl-natives-macosx-universal.jar:./lib/jocl-natives-linux-i586.jar:./lib/jocl-natives-linux-amd64.jar:./lib/gluegen-rt.jar:./lib/gluegen-rt-natives-linux-amd64.jar:./lib/gluegen-rt-natives-macosx-universal.jar:./lib/gluegen-rt-natives-linux-i586.jar:." HelloJOCL but get this error Exception in thread "main" java.lang.NoClassDefFoundError: com/jogamp/opencl/CLContext at java.lang.Class.getDeclaredMethods0(Native Method)

    Read the article

  • Problem with fb:swf in Opera

    - by agog.iam
    Hi, I am embedding my flash game in the following way, which runs fine in IE, Firefox, Chrome but doesn't play in Opera. Please suggest what is wrong here. <div> <fb:swf waitforclick = "true" wmode="opaque" width="640" height="480" imgsrc=""http://mygame.jpg" swfsrc="http://mygame.swf" flashvars="sid=<?php echo $id;?>&musicVal=<?php echo $musicVal;?>&efxVal=<?php echo $efxVal;?>&muteVal=<?php echo $muteVal;?>"/> </div> Thanks in advance, agog.iam

    Read the article

  • how to uninstall ubuntu 12.04 from virtualbox 4.3

    - by Kujua
    Due to some difficulties encountered in using the currently installed ubuntu, Iam trying to uninstall this ubuntu 12.04 from virtualbox 4.3. My aim is to redo the whole installation process. Iam using window 7. I tried once by unistalling virtualbox through control panel, uninstall program. But after re installing again i find that the works done in ubuntu are still there. I wanted to start a fresh, please advice

    Read the article

  • AWS Cloud Formation.Requires capabilities : [CAPABILITY_IAM] (Child Stack)

    - by Drew Khoury
    I'm running a CloudFormation template in the AWS Console. Running Stack Directly I started with a template that used IAM resources, and the console prompts me to acknowledge IAM capabilities when running the stack directly. Running Stack as a child I then tried to call the same stack from a parent stack and did not receive the same prompt. The stack then failed with the message: Requires capabilities : [CAPABILITY_IAM] Research The docs indicate that I can run CF scripts in a number of ways. There's plenty of docs around CLI/API and supplying the capability parameter, but there appears to be no information about how to make sure it's applied when running through the console. http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-iam-template.html IAM Resources in AWS CloudFormation Templates CF Console CLI API What I've done / What I think I've raised an issue via the forum for now, but no response (yet): https://forums.aws.amazon.com/thread.jspa?threadID=139160 I suspect this is a bug in the Console, as there doesn't appear to be any documentation of how to change the behaviour via the console and as far as I'm aware this should just work. Anyone came across the same problem, or can report that it's working fine for them?

    Read the article

  • mac, netbeans 6.8, c++, sdl, opengl: compilation problems

    - by ufk
    Hiya. I'm trying to properly compile a c++ opengl+sdl application using netbeans 6.8 under Snow Leopard 64-bit. I have libSDL 1.2.14 installed using macports. The script that I try to compile is the following: #ifdef WIN32 #define WIN32_LEAN_AND_MEAN #include <windows.h> #endif #if defined(__APPLE__) && defined(__MACH__) #include <OpenGL/gl.h> // Header File For The OpenGL32 Library #include <OpenGL/glu.h> // Header File For The GLu32 Library #else #include <GL/gl.h> // Header File For The OpenGL32 Library #include <GL/glu.h> // Header File For The GLu32 Library #endif #include "sdl/SDL.h" #include <stdio.h> #include <unistd.h> #include "SDL/SDL_main.h" SDL_Surface *screen=NULL; GLfloat rtri; // Angle For The Triangle ( NEW ) GLfloat rquad; // Angle For The Quad ( NEW ) void InitGL(int Width, int Height) // We call this right after our OpenGL window is created. { glViewport(0, 0, Width, Height); glClearColor(0.0f, 0.0f, 0.0f, 0.0f); // This Will Clear The Background Color To Black glClearDepth(1.0); // Enables Clearing Of The Depth Buffer glDepthFunc(GL_LESS); // The Type Of Depth Test To Do glEnable(GL_DEPTH_TEST); // Enables Depth Testing glShadeModel(GL_SMOOTH); // Enables Smooth Color Shading glMatrixMode(GL_PROJECTION); glLoadIdentity(); // Reset The Projection Matrix gluPerspective(45.0f,(GLfloat)Width/(GLfloat)Height,0.1f,100.0f); // Calculate The Aspect Ratio Of The Window glMatrixMode(GL_MODELVIEW); } /* The main drawing function. */ int DrawGLScene() { glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // Clear The Screen And The Depth Buffer glLoadIdentity(); // Reset The View glTranslatef(-1.5f,0.0f,-6.0f); // Move Left 1.5 Units And Into The Screen 6.0 glRotatef(rtri,0.0f,1.0f,0.0f); // Rotate The Triangle On The Y axis ( NEW ) // draw a triangle glBegin(GL_TRIANGLES); // Begin Drawing Triangles glColor3f(1.0f,0.0f,0.0f); // Red glVertex3f( 0.0f, 1.0f, 0.0f); // Top Of Triangle (Front) glColor3f(0.0f,1.0f,0.0f); // Green glVertex3f(-1.0f,-1.0f, 1.0f); // Left Of Triangle (Front) glColor3f(0.0f,0.0f,1.0f); // Blue glVertex3f( 1.0f,-1.0f, 1.0f); // Right Of Triangle (Front) glColor3f(1.0f,0.0f,0.0f); // Red glVertex3f( 0.0f, 1.0f, 0.0f); // Top Of Triangle (Right) glColor3f(0.0f,0.0f,1.0f); // Blue glVertex3f( 1.0f,-1.0f, 1.0f); // Left Of Triangle (Right) glColor3f(0.0f,1.0f,0.0f); // Green glVertex3f( 1.0f,-1.0f, -1.0f); // Right Of Triangle (Right) glColor3f(1.0f,0.0f,0.0f); // Red glVertex3f( 0.0f, 1.0f, 0.0f); // Top Of Triangle (Back) glColor3f(0.0f,1.0f,0.0f); // Green glVertex3f( 1.0f,-1.0f, -1.0f); // Left Of Triangle (Back) glColor3f(0.0f,0.0f,1.0f); // Blue glVertex3f(-1.0f,-1.0f, -1.0f); // Right Of Triangle (Back) glColor3f(1.0f,0.0f,0.0f); // Red glVertex3f( 0.0f, 1.0f, 0.0f); // Top Of Triangle (Left) glColor3f(0.0f,0.0f,1.0f); // Blue glVertex3f(-1.0f,-1.0f,-1.0f); // Left Of Triangle (Left) glColor3f(0.0f,1.0f,0.0f); // Green glVertex3f(-1.0f,-1.0f, 1.0f); // Right Of Triangle (Left) glEnd(); glLoadIdentity(); // Reset The Current Modelview Matrix glTranslatef(1.5f,0.0f,-7.0f); // Move Right 1.5 Units And Into The Screen 6.0 glRotatef(rquad,1.0f,0.0f,0.0f); // Rotate The Quad On The X axis ( NEW ) glBegin(GL_QUADS); // Start Drawing Quads glColor3f(0.0f,1.0f,0.0f); // Set The Color To Green glVertex3f( 1.0f, 1.0f,-1.0f); // Top Right Of The Quad (Top) glVertex3f(-1.0f, 1.0f,-1.0f); // Top Left Of The Quad (Top) glVertex3f(-1.0f, 1.0f, 1.0f); // Bottom Left Of The Quad (Top) glVertex3f( 1.0f, 1.0f, 1.0f); // Bottom Right Of The Quad (Top) glColor3f(1.0f,0.5f,0.0f); // Set The Color To Orange glVertex3f( 1.0f,-1.0f, 1.0f); // Top Right Of The Quad (Bottom) glVertex3f(-1.0f,-1.0f, 1.0f); // Top Left Of The Quad (Bottom) glVertex3f(-1.0f,-1.0f,-1.0f); // Bottom Left Of The Quad (Bottom) glVertex3f( 1.0f,-1.0f,-1.0f); // Bottom Right Of The Quad (Bottom) glColor3f(1.0f,0.0f,0.0f); // Set The Color To Red glVertex3f( 1.0f, 1.0f, 1.0f); // Top Right Of The Quad (Front) glVertex3f(-1.0f, 1.0f, 1.0f); // Top Left Of The Quad (Front) glVertex3f(-1.0f,-1.0f, 1.0f); // Bottom Left Of The Quad (Front) glVertex3f( 1.0f,-1.0f, 1.0f); // Bottom Right Of The Quad (Front) glColor3f(1.0f,1.0f,0.0f); // Set The Color To Yellow glVertex3f( 1.0f,-1.0f,-1.0f); // Bottom Left Of The Quad (Back) glVertex3f(-1.0f,-1.0f,-1.0f); // Bottom Right Of The Quad (Back) glVertex3f(-1.0f, 1.0f,-1.0f); // Top Right Of The Quad (Back) glVertex3f( 1.0f, 1.0f,-1.0f); // Top Left Of The Quad (Back) glColor3f(0.0f,0.0f,1.0f); // Set The Color To Blue glVertex3f(-1.0f, 1.0f, 1.0f); // Top Right Of The Quad (Left) glVertex3f(-1.0f, 1.0f,-1.0f); // Top Left Of The Quad (Left) glVertex3f(-1.0f,-1.0f,-1.0f); // Bottom Left Of The Quad (Left) glVertex3f(-1.0f,-1.0f, 1.0f); // Bottom Right Of The Quad (Left) glColor3f(1.0f,0.0f,1.0f); // Set The Color To Violet glVertex3f( 1.0f, 1.0f,-1.0f); // Top Right Of The Quad (Right) glVertex3f( 1.0f, 1.0f, 1.0f); // Top Left Of The Quad (Right) glVertex3f( 1.0f,-1.0f, 1.0f); // Bottom Left Of The Quad (Right) glVertex3f( 1.0f,-1.0f,-1.0f); // Bottom Right Of The Quad (Right) glEnd(); // Done Drawing A Quad rtri+=0.02f; // Increase The Rotation Variable For The Triangle ( NEW ) rquad-=0.015f; // Decrease The Rotation Variable For The Quad ( NEW ) // swap buffers to display, since we're double buffered. SDL_GL_SwapBuffers(); return true; } int main(int argc,char* argv[]) { int done; /*variable to hold the file name of the image to be loaded *In real world error handling code would precede this */ /* Initialize SDL for video output */ if ( SDL_Init(SDL_INIT_VIDEO) < 0 ) { fprintf(stderr, "Unable to initialize SDL: %s\n", SDL_GetError()); exit(1); } atexit(SDL_Quit); /* Create a 640x480 OpenGL screen */ if ( SDL_SetVideoMode(640, 480, 0, SDL_OPENGL) == NULL ) { fprintf(stderr, "Unable to create OpenGL screen: %s\n", SDL_GetError()); SDL_Quit(); exit(2); } SDL_WM_SetCaption("another example",NULL); InitGL(640,480); done=0; while (! done) { DrawGLScene(); SDL_Event event; while ( SDL_PollEvent(&event) ) { if ( event.type == SDL_QUIT ) { done = 1; } if ( event.type == SDL_KEYDOWN ) { if ( event.key.keysym.sym == SDLK_ESCAPE ) { done = 1; } } } } } Under netbeans project properties I configured the following: C++ Compiler: added /usr/X11/include and /opt/local/include to the include directories. Linker: I added the following libraries: /usr/X11/lib/libGL.dylib /usr/X11/lib/libGLU.dylib /opt/local/lib/libSDL.dylib /opt/local/lib/libSDLmain.a Now... before I included SDL_main.h and libSDLMain.a to the project I got an error unknown reference to _main then I read here: http://www.libsdl.org/faq.php?action=listentries&category=7#55 that I need to include SDL_Main.h and to link libSDLMain.so to my project. after doing so, the project still won't compile. this is the Netbeans output: /usr/bin/make -f nbproject/Makefile-Debug.mk SUBPROJECTS= .clean-conf rm -f -r build/Debug rm -f dist/Debug/GNU-MacOSX/opengl2 CLEAN SUCCESSFUL (total time: 79ms) /usr/bin/make -f nbproject/Makefile-Debug.mk SUBPROJECTS= .build-conf /usr/bin/make -f nbproject/Makefile-Debug.mk dist/Debug/GNU-MacOSX/opengl2 mkdir -p build/Debug/GNU-MacOSX rm -f build/Debug/GNU-MacOSX/main.o.d g++ -c -g -I/usr/X11/include -I/opt/local/include -MMD -MP -MF build/Debug/GNU-MacOSX/main.o.d -o build/Debug/GNU-MacOSX/main.o main.cpp mkdir -p dist/Debug/GNU-MacOSX g++ -o dist/Debug/GNU-MacOSX/opengl2 build/Debug/GNU-MacOSX/main.o /opt/local/lib/libIL.dylib /opt/local/lib/libILU.dylib /opt/local/lib/libILUT.dylib /usr/X11/lib/libGL.dylib /usr/X11/lib/libGLU.dylib /opt/local/lib/libSDL.dylib /opt/local/lib/libSDLmain.a Undefined symbols: "_OBJC_CLASS_$_NSMenu", referenced from: __objc_classrefs__DATA@0 in libSDLmain.a(SDLMain.o) "__objc_empty_cache", referenced from: _OBJC_METACLASS_$_SDLMain in libSDLmain.a(SDLMain.o) _OBJC_CLASS_$_SDLMain in libSDLmain.a(SDLMain.o) "_CFBundleGetMainBundle", referenced from: -[SDLMain setupWorkingDirectory:] in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) "_CFURLGetFileSystemRepresentation", referenced from: -[SDLMain setupWorkingDirectory:] in libSDLmain.a(SDLMain.o) "_NSApp", referenced from: _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) "_OBJC_CLASS_$_NSProcessInfo", referenced from: __objc_classrefs__DATA@0 in libSDLmain.a(SDLMain.o) "_CFURLCreateCopyDeletingLastPathComponent", referenced from: -[SDLMain setupWorkingDirectory:] in libSDLmain.a(SDLMain.o) "_NSAllocateMemoryPages", referenced from: -[NSString(ReplaceSubString) stringByReplacingRange:with:] in libSDLmain.a(SDLMain.o) "___CFConstantStringClassReference", referenced from: cfstring=CFBundleName in libSDLmain.a(SDLMain.o) cfstring= in libSDLmain.a(SDLMain.o) cfstring=About in libSDLmain.a(SDLMain.o) cfstring=Hide in libSDLmain.a(SDLMain.o) cfstring=h in libSDLmain.a(SDLMain.o) cfstring=Hide Others in libSDLmain.a(SDLMain.o) cfstring=Show All in libSDLmain.a(SDLMain.o) cfstring=Quit in libSDLmain.a(SDLMain.o) cfstring=q in libSDLmain.a(SDLMain.o) cfstring=Window in libSDLmain.a(SDLMain.o) cfstring=m in libSDLmain.a(SDLMain.o) cfstring=Minimize in libSDLmain.a(SDLMain.o) "_OBJC_CLASS_$_NSAutoreleasePool", referenced from: __objc_classrefs__DATA@0 in libSDLmain.a(SDLMain.o) "_CPSEnableForegroundOperation", referenced from: _main in libSDLmain.a(SDLMain.o) "_CPSGetCurrentProcess", referenced from: _main in libSDLmain.a(SDLMain.o) "_CFBundleCopyBundleURL", referenced from: -[SDLMain setupWorkingDirectory:] in libSDLmain.a(SDLMain.o) "_NSDeallocateMemoryPages", referenced from: -[NSString(ReplaceSubString) stringByReplacingRange:with:] in libSDLmain.a(SDLMain.o) "_OBJC_CLASS_$_NSApplication", referenced from: l_OBJC_$_CATEGORY_NSApplication_$_SDLApplication in libSDLmain.a(SDLMain.o) __objc_classrefs__DATA@0 in libSDLmain.a(SDLMain.o) "_CPSSetFrontProcess", referenced from: _main in libSDLmain.a(SDLMain.o) "_OBJC_CLASS_$_NSString", referenced from: l_OBJC_$_CATEGORY_NSString_$_ReplaceSubString in libSDLmain.a(SDLMain.o) __objc_classrefs__DATA@0 in libSDLmain.a(SDLMain.o) "_OBJC_CLASS_$_NSObject", referenced from: _OBJC_CLASS_$_SDLMain in libSDLmain.a(SDLMain.o) "_CFBundleGetInfoDictionary", referenced from: _main in libSDLmain.a(SDLMain.o) "_CFRelease", referenced from: -[SDLMain setupWorkingDirectory:] in libSDLmain.a(SDLMain.o) -[SDLMain setupWorkingDirectory:] in libSDLmain.a(SDLMain.o) "__objc_empty_vtable", referenced from: _OBJC_METACLASS_$_SDLMain in libSDLmain.a(SDLMain.o) _OBJC_CLASS_$_SDLMain in libSDLmain.a(SDLMain.o) "_OBJC_CLASS_$_NSMenuItem", referenced from: __objc_classrefs__DATA@0 in libSDLmain.a(SDLMain.o) "_objc_msgSend", referenced from: -[SDLMain application:openFile:] in libSDLmain.a(SDLMain.o) -[SDLMain applicationDidFinishLaunching:] in libSDLmain.a(SDLMain.o) -[NSString(ReplaceSubString) stringByReplacingRange:with:] in libSDLmain.a(SDLMain.o) -[NSString(ReplaceSubString) stringByReplacingRange:with:] in libSDLmain.a(SDLMain.o) -[NSString(ReplaceSubString) stringByReplacingRange:with:] in libSDLmain.a(SDLMain.o) -[NSString(ReplaceSubString) stringByReplacingRange:with:] in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) _main in libSDLmain.a(SDLMain.o) "_OBJC_METACLASS_$_NSObject", referenced from: _OBJC_METACLASS_$_SDLMain in libSDLmain.a(SDLMain.o) _OBJC_METACLASS_$_SDLMain in libSDLmain.a(SDLMain.o) "_objc_msgSend_fixup", referenced from: l_objc_msgSend_fixup_objectForKey_ in libSDLmain.a(SDLMain.o) l_objc_msgSend_fixup_length in libSDLmain.a(SDLMain.o) l_objc_msgSend_fixup_alloc in libSDLmain.a(SDLMain.o) l_objc_msgSend_fixup_release in libSDLmain.a(SDLMain.o) ld: symbol(s) not found collect2: ld returned 1 exit status make[2]: *** [dist/Debug/GNU-MacOSX/opengl2] Error 1 make[1]: *** [.build-conf] Error 2 make: *** [.build-impl] Error 2 BUILD FAILED (exit value 2, total time: 263ms) any ideas? thanks a lot!

    Read the article

  • How to remove strings of certain lengths

    - by Macosx Iam
    So I have this array, and I want to delete strings that are 2 or 4 characters in length (strings that contain 2 or 4 characters). I am doing this method, and it doesn't work, even though logically, it SHOULD work. public static void main(String[] args) { ArrayList<String> list = new ArrayList<String>(); list.add("This"); list.add("is"); list.add("a"); list.add("test"); for (int i=0; i<list.size(); i++) { if(list.get(i).length()==2 || list.get(i).length()==4) { list.remove(i); } } } I'd like to stick to this method of doing it. Can you please give me some suggestions as to how to correct this code? The output of this code when I run it is: [is, a] Even though I want the output to be [a] because "is" is 2 characters long.

    Read the article

  • MacBook: Can't boot into Linux partition after installation.

    - by Otto
    Hello I just installed Ubuntu. I created a partition in MacOSx using Disk utility, then deleted the partition and installed Ubuntu on the free space created. After the installation, Ubuntu said it would reboot. I hang on shutdown (which is normal, as google told me), so I used the power button to turn the MacBook off. Now I want to boot into Ubuntu. Pressing option/alt on startup only shows me the MacOSx and Windows partition. Also, the Linux partition isn't showing up on my MacOSx desktop. And in Disk Utility, I can see 3 grayed out partitions: "disk0s4", "disk0s5" and "Linux Swap". What can I do to boot into Ubuntu without losing my other partitions? Thank you for your help.

    Read the article

  • Can't boot into Linux partition after installation

    - by Otto
    I just installed Ubuntu. I created a partition in MacOSx using Disk utility, then deleted the partition and installed Ubuntu on the free space created. After the installation, Ubuntu said it would reboot. I hang on shutdown (which is normal, as google told me), so I used the power button to turn the MacBook off. Now I want to boot into Ubuntu. Pressing option/alt on startup only shows me the MacOSx and Windows partition. Also, the Linux partition isn't showing up on my MacOSx desktop. And in Disk Utility, I can see 3 grayed out partitions: "disk0s4", "disk0s5" and "Linux Swap". What can I do to boot into Ubuntu without losing my other partitions? Thank you for your help.

    Read the article

  • X11 from ssh on Mac OSX to Linux server doesn't work --- Gtk-WARNING **: cannot open display

    - by Cal
    Hello, I installed a program wireshark on my remote linux box and I'm trying to run it with X11 from my mac computer using SSH. Here's my terminal... macosx$ echo $DISPLAY /tmp/launch-f4w6k6/:0 macosx$ ssh -X [email protected] [email protected]'s password: remoteubuntu:~# echo $DISPLAY remoteubuntu:~# wireshark (wireshark:18927): Gtk-WARNING **: cannot open display: Here's a few lines from /etc/ssh/sshd_config X11Forwarding yes X11DisplayOffset 10 PrintMotd no PrintLastLog yes TCPKeepAlive yes #UseLogin no Thanks for the help!

    Read the article

  • Chrome becomes totally unresponsive - Linux Mint

    - by SpyrosR
    Iam running Linux Mint on my laptop and i have some (serious) problems with Google Chrome.Randomly Chrome becomes totally unresponsive and iam not able to do anything,except restart the system from the power button.I think it's not an issue with system load and/or RAM,because if i for example open lot of "heavy" programs everything seems to work quite fine.When i only run Chrome with not many tabs at random times it freezes the whole system.The weird thing is that Chrome is not heavily loaded with tabs or extensions.I can't figure out what is causing this problem.Any suggestion?Thank you in advance.

    Read the article

< Previous Page | 37 38 39 40 41 42 43 44 45 46 47 48  | Next Page >