Search Results

Search found 21828 results on 874 pages for 'program x'.

Page 18/874 | < Previous Page | 14 15 16 17 18 19 20 21 22 23 24 25  | Next Page >

  • Minecraft program frame rate is very slow

    - by Cade
    I have recently downloaded Minecraft to Ubuntu 12.04. It launches and plays successfully, however- the frame rates for the game are extremely slow. They never go past 9 fps and usually drop below 3 fps. I have been a Windows XP user for years and have just recently switched to Ubuntu, so I'm not an expert with this OS. My video card is a Diamond Stealth s60 with Radeon 7000. I don't know what other information you guys need but if you ask for it, and would please tell me how to get to it, I will tell you as soon as I can. Thanks for your help.

    Read the article

  • Java Program help [migrated]

    - by georgetheevilman
    Okay I have a really annoying error. Its coming from my retainAll method. The problem is that I am outputting 1,3,5 in ints at the end, but I need 1,3,5,7,9. Here is the code below for the MySet and driver classes public class MySetTester { public static void main(String[]args) { MySet<String> strings = new MySet<String>(); strings.add("Hey!"); strings.add("Hey!"); strings.add("Hey!"); strings.add("Hey!"); strings.add("Hey!"); strings.add("Listen!"); strings.add("Listen!"); strings.add("Sorry, I couldn't resist."); strings.add("Sorry, I couldn't resist."); strings.add("(you know you would if you could)"); System.out.println("Testing add:\n"); System.out.println("Your size: " + strings.size() + ", contains(Sorry): " + strings.contains("Sorry, I couldn't resist.")); System.out.println("Exp. size: 4, contains(Sorry): true\n"); MySet<String> moreStrings = new MySet<String>(); moreStrings.add("Sorry, I couldn't resist."); moreStrings.add("(you know you would if you could)"); strings.removeAll(moreStrings); System.out.println("Testing remove and removeAll:\n"); System.out.println("Your size: " + strings.size() + ", contains(Sorry): " + strings.contains("Sorry, I couldn't resist.")); System.out.println("Exp. size: 2, contains(Sorry): false\n"); MySet<Integer> ints = new MySet<Integer>(); for (int i = 0; i < 100; i++) { ints.add(i); } System.out.println("Your size: " + ints.size()); System.out.println("Exp. size: 100\n"); for (int i = 0; i < 100; i += 2) { ints.remove(i); } System.out.println("Your size: " + ints.size()); System.out.println("Exp. size: 50\n"); MySet<Integer> zeroThroughNine = new MySet<Integer>(); for (int i = 0; i < 10; i++) { zeroThroughNine.add(i); } ints.retainAll(zeroThroughNine); System.out.println("ints should now only retain odd numbers" + " 0 through 10\n"); System.out.println("Testing your iterator:\n"); for (Integer i : ints) { System.out.println(i); } System.out.println("\nExpected: \n\n1 \n3 \n5 \n7 \n9\n"); System.out.println("Yours:"); for (String s : strings) { System.out.println(s); } System.out.println("\nExpected: \nHey! \nListen!"); strings.clear(); System.out.println("\nClearing your set...\n"); System.out.println("Your set is empty: " + strings.isEmpty()); System.out.println("Exp. set is empty: true"); } } And here is the main code. But still read the top part because that's where my examples are. import java.util.Set; import java.util.Collection; import java.lang.Iterable; import java.util.Iterator; import java.util.Arrays; import java.lang.reflect.Array; public class MySet implements Set, Iterable { // instance variables - replace the example below with your own private E[] backingArray; private int numElements; /** * Constructor for objects of class MySet */ public MySet() { backingArray=(E[]) new Object[5]; numElements=0; } public boolean add(E e){ for(Object elem:backingArray){ if (elem==null ? e==null : elem.equals(e)){ return false; } } if(numElements==backingArray.length){ E[] newArray=Arrays.copyOf(backingArray,backingArray.length*2); newArray[numElements]=e; numElements=numElements+1; backingArray=newArray; return true; } else{ backingArray[numElements]=e; numElements=numElements+1; return true; } } public boolean addAll(Collection<? extends E> c){ for(E elem:c){ this.add(elem); } return true; } public void clear(){ E[] newArray=(E[])new Object[backingArray.length]; numElements=0; backingArray=newArray; } public boolean equals(Object o){ if(o instanceof Set &&(((Set)o).size()==numElements)){ for(E elem:(Set<E>)o){ if (this.contains(o)==false){ return false; } return true; } } return false; } public boolean contains(Object o){ for(E backingElem:backingArray){ if (o!=null && o.equals(backingElem)){ return true; } } return false; } public boolean containsAll(Collection<?> c){ for(E elem:(Set<E>)c){ if(!(this.contains(elem))){ return false; } } return true; } public int hashCode(){ int sum=0; for(E elem:backingArray){ if(elem!=null){ sum=sum+elem.hashCode(); } } return sum; } public boolean isEmpty(){ if(numElements==0){ return true; } else{ return false; } } public boolean remove(Object o){ int i=0; for(Object elem:backingArray){ if(o!=null && o.equals(elem)){ backingArray[i]=null; numElements=numElements-1; E[] newArray=Arrays.copyOf(backingArray,backingArray.length-1); return true; } i=i+1; } return false; } public boolean removeAll(Collection<?> c){ for(Object elem:c){ this.remove(elem); } return true; } public boolean retainAll(Collection<?> c){ MySet<E> removalArray=new MySet<E>(); for(E arrayElem:backingArray){ if(arrayElem!= null && !(c.contains(arrayElem))){ this.remove(arrayElem); } } return false; } public int size(){ return numElements; } public <T> T[] toArray(T[] a) throws ArrayStoreException,NullPointerException{ for(int i=0;i<numElements;i++){ a[i]=(T)backingArray[i]; } for(int j=numElements;j<a.length;j++){ a[j]=null; } return a; } public Object[] toArray(){ Object[] newArray=new Object[numElements]; for(int i=0;i<numElements;i++){ newArray[i]=backingArray[i]; } return newArray; } public Iterator<E> iterator(){ setIterator iterator=new setIterator(); return iterator; } private class setIterator implements Iterator<E>{ private int currIndex; private E lastElement; public setIterator(){ currIndex=0; lastElement=null; } public boolean hasNext(){ while(currIndex<=numElements && backingArray[currIndex]==null){ currIndex=currIndex+1; } if (currIndex<=numElements){ return true; } return false; } public E next(){ E element=backingArray[currIndex]; currIndex=currIndex+1; lastElement=element; return element; } public void remove() throws UnsupportedOperationException,IllegalStateException{ if(lastElement!=null){ MySet.this.remove((Object)lastElement); numElements=numElements-1; } else{ throw new IllegalStateException(); } } } } I've been able to reduce the problems, but otherwise this thing is still causing problems.

    Read the article

  • a c++ program for task scheduling [closed]

    - by scheduling
    This is the code which I made but I am not able to correct the mistake in the code. Please correct the mistake in my code. #include<unistd.h> #include<stdio.h> #include<stdlib.h> #include<time.h> #include<string.h> int main() { char *timetoken; char currtime[7]; char schedtime[7]; int i; struct tm *localtimeptr; strcpy(schedtime,"15:25:00"); while(6!=9) { time_t lt; sleep(1); lt = time(NULL); localtimeptr = localtime(<); timetoken=strtok(asctime(localtimeptr)," "); for(i=1;i<5;i++) timetoken=strtok('\0'," "); if(i==3) { strcpy(currtime,timetoken); } } printf("The current time is: %s\n",currtime); printf("We are waiting for: %s\n",schedtime); if(!strcmp(currtime,schedtime)) { printf("Time to do stuff \n"); system("C:\PROJECT X"); } getch(); return 0; }

    Read the article

  • Adding program booting options to the OS

    - by user113948
    I am building a flight simulator box, off of Ubuntu 12.10, but I am trying to make the OS essentially invisible, I just want the machine to boot into the Flight Sim, which, that part isn't really that difficult, just a matter of adding a startup item, but I would like to make it a bit more seemless, and in-addtion to that, I would like maybe a 3-5 second countdown where you could opt-out of the flight sim from starting, if you need to troubleshoot the OS, or the flight sim itself, and I have no idea how that would be accomplished

    Read the article

  • Find hosting through Bizspark program

    - by user636525
    I am a Bizspark owner and I am all set to launch my website but I am really confused about where to start the process for finding a hosting partner with my Bizspark membership. Since I have downloaded MicroSoft SQL Server from Bizspark website, I know I don't need a license for SQL Server. So do I need to email some hosting companies and ask them if I can get their VPS and I can install my own copy of SQL Server? That means, I will end up paying only for the VPS?

    Read the article

  • Portion of Screen Broke

    - by Devoted
    Hi, A portion of my laptop screen broke. Is there any kind of software that will just ignore that part and resize everything accordingly? It's like 1/6 of the screen on the right that makes anything over there impossible to see. If not, what would be the best programming language to go about making my own program? It is a PC but I can also run Ubuntu if that would be easier to make a program for.

    Read the article

  • Execute Command Line Java program in background

    - by Mark Szymanski
    Is it possible to execute a Java program in the background so the user can execute other commands in front of it? For instance, here is how the console might look for said program: $ myProgram (executes program) Program Started! (output from myProgram) $ (the user can enter another UNIX command while myProgram is still running) Thanks in advance!

    Read the article

  • how to implement video and audio merger program ?

    - by egebilmuh
    Hi guys I want to make a program which takes video and audio and merges them. Video Type or audio type is not important for me. I just want to make so- called program. How can i make this ? does any library exist for this ? (I know there are many program about this topic but i want to learn how to implement such a program.) Help me please about this topic.

    Read the article

  • Run a external program with specified max running time

    - by jack
    I want to execute an external program in each thread of a multi-threaded python program. Let's say max running time is set to 1 second. If started process completes within 1 second, main program capture its output for further processing. If it doesn't finishes in 1 second, main program just terminate it and start another new process. How to implement this?

    Read the article

  • Can I use cstdio in a C program?

    - by Tommy
    Can I use cstdio in a C program? I get a ton of errors in cstdio when I add the #include <cstdio> to the C program. c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\include\cstdio(17) : error C2143: syntax error : missing '{' before ':' c:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\include\cstdio(17) : error C2059: syntax error : ':' Thanks EDIT - I would like to use snprintf, which is why I am trying to include this.

    Read the article

  • Execute and Capture one program from another

    - by DandDI
    In win32 programming in C: Whats the best way to execute a win32 console program within another win32 program, and have the program that started the execution capture the output? At the moment I made the program redirect output to a file, but I am sure I must be able to open some sort of pipe?

    Read the article

  • Windows 7 Starter Screensaver Program Original Files

    - by Mark
    Dear Sir or Madam I used the program by Sopan and Javier to change the wallpaper in Windows 7 Starter Edition on my laptop and it worked fine. I have now upgraded to Home Edition but there seems to be remnants of the program still lurking somewhere as when I set photos up for the screensaver they are always stretched no matter what I set the picture position as, ie fill,fit,stretched, tiled or centred. Can Sopan or Javier or anyone else supply original copies please of the files the program modified so that I can over-write the modified files back to the original ones? I know I can re-install the full windows 7 software but I want to save the agony of that along with the re-installation of all my programs and drivers! Many thanks for your help. Mark

    Read the article

  • Tunnel only one program (UDP & TCP) through another server

    - by user136036
    I have a windows machine at home and a server with debian installed. I want to tunnel the UDP traffic from one (any only this) program on my windows machine through my server. For tcp traffic this was easy using putty as a socks5 proxy and then connecting via ssh to my server - but this does not seem to work for UDP. Then I setup dante as a socks5 proxy but it seems to create a new instance/thread per connection which leads to a huge ram usage for my server, so this was no option either. So most people recommend openvpn, so my question: Can I use openvpn to just tunnel this one program through my server? Is there a way to maybe create a local socks5 proxy on my windows machine and set it as a proxy in my program and only this proxy then will use openvpn? Thank you for your ideas

    Read the article

  • Program complains not enough disk space even if the disk space exists

    - by user1189899
    I have an EXT3 partition mounted in ordered data mode. If a power failure occurs when a program is creating files on that partition, I see that space usage reported is normal and I don't see any partial written files. But when I try to run the same program again after the system comes back up it complains that there is not enough disk space. Even though the free space reported is far more than required. The program always succeeds in normal conditions. Also the problem seems to disappear when the partition is remounted. I was wondering what could be the right way to handle the situation other than unmounting and remounting.

    Read the article

  • Using AHK PostMessage to send WM_WININICHANGE to Program Manager

    - by SaintWacko
    I've written a script which updates an environment variable, but I need to tell Program Manager to update the computer's programs with this new information. I was given this as the API call that is made within another program to cause this: ::SendMessage(::FindWindow("Progman", NULL), WM_WININICHANGE, 0L, (LPARAM)"Environment"); I am attempting to translate this into an AutoHotKey PostMessage call, but I'm doing something wrong, as it isn't working. Here's where I've gotten so far: PostMessage, 0x1A,, (LPARAM)"Environment", "Program Manager" Here are the AHK resources I've been looking at to do this: List of Windows Messages Send Messages to a Window or Its Controls PostMessage / SendMessage And here are the resources that I used to figure out the original API call: SendMessage function WM_WININICHANGE message Can anyone help me figure out what I'm doing wrong?

    Read the article

  • How to block a program from using IPv4?

    - by Ian Boyd
    I have a program that can communicate over IPv4 (TCP and UDP) and over IPv6 (TCP and UDP). I want to block the program from being able to use IPv4. I tried the Windows Firewall: Except it blocks IP sub-protocols (e.g. TCP, UDP, encapsulated IPv6, GRE), rather than blocking IPv4 itself. In other words, I need to block IPv4: IPv4/TCP IPv4/UDP IPv4/ICMPv4 IPv4/GRE IPv4/L2TP while allowing IPv6: IPv6/TCP IPv6/UDP IPv6/ICMPv6 IPv6/GRE IPv6/L2TP Can I block a program from using IPv4? Note: If it cannot be done, then don't be afraid to add that as an answer. There's no shame in giving the correct answer to a question.

    Read the article

  • Piping the output of a program to Preview.app

    - by Abhay Buch
    I'm using an application (the dot program of the graphviz library) that generates a wide variety of file formats including PostScript and PDF. It can send the result to stdout or to a file. I'm currently sending it to a file and opening it with Preview. Is there any way to pipe the output and have it be read by Preview, so that I'd don't have to generate a file and have it lying around? This is going to be used by a number of people who won't know the internal structure of the generating script and I don't want to clutter their folders or complicate their lives. More generally, is there any way to take a program that sends its output to stdout and pass that output to an program that usually takes it's input from a file, without actually creating a file?

    Read the article

  • In Windows Vista, when starting any and every program, a "bad image" error is generated

    - by Mark Hatton
    I have a problem where any program is started under Windows Vista, the following error message is generated Bad Image C;\PROGRA~1\Google\GOOGLE~3\GOEC62~1.DLL is either not designed to run on Windows or it contains an error.Try installing the program again using the original installation media or contact your system administrator or the software vendor for support. This happens for every program started, including those that start automatically at boot time. My Google-fu is failing to solve this for me. I have already tried an "sfc /scannow" which did find some problems, but it said that it could not correct them. What might cause this problem? How might it be resolved?

    Read the article

  • When I auto-start Supervisord on boot, the [program:start_gunicorn] don't start

    - by Charlesliam
    The [program:start_gunicorn] is running with no error when I manually start supervisord with this setup. [program:start_gunicorn] command=/env/nafd/bin/gunicorn_start priority=1 autostart=true autorestart=unexpected user=nafd_it redirect_stderr=true stdout_logfile=/env/nafd/logs/gunicorn_supervisor.log stderr_logfile=/env/nafd/logs/gunicorn_supervisor_err.log I successfully run this init script for my supervisord. But when I used auto-start init script for supervisord the gunicorn is not running. ]# service gunicorn status gunicorn: unrecognized service What do I need to do to make the [program:start_gunicorn] run when using auto-start supervisord on boot? Here's my gunicorn config. /env/nafd/bin/gunicorn_start #!/bin/bash NAME="nafd_proj" DJANGODIR=/env/nafd/nafd_proj SOCKFILE=/env/nafd/run/gunicorn.sock NUM_WORKERS=1 DJANGO_SETTINGS_MODULE=nafd_proj.settings DJANGO_WSGI_MODULE=nafd_proj.wsgi echo "Starting $NAME as 'NAFD Web Server'" source /env/nafd/bin/activate export DJANGO_SETTINGS_MODULE=$DJANGO_SETTINGS_MODULE export PYTHONPATH=$DJANGODIR:$PYTHONPATH RUNDIR=$(dirname $SOCKFILE) test -d $RUNDIR || mkdir -p $RUNDIR cd /env/nafd/nafd_proj exec ../bin/gunicorn ${DJANGO_WSGI_MODULE}:application --bind=127.0.0.1:8001 \ --name $NAME \ --workers $NUM_WORKERS \ --log-level=debug \` Any idea is really appreciated.

    Read the article

< Previous Page | 14 15 16 17 18 19 20 21 22 23 24 25  | Next Page >