Seite 92 von 340 ErsteErste ... 42 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 142 192 ... LetzteLetzte
Zeige Ergebnis 2.731 bis 2.760 von 10174

C/C++ Programming Help Thread

This is a discussion on C/C++ Programming Help Thread within the PSP Development Forum forums, part of the PSP Development, Hacks, and Homebrew category; Zitat von jsharrad Anti-QJ, use psplink. It's not an emulator but you can use it to load your programs on ...

  
  1. #2731
    lol
    Points: 20.859, Level: 91
    Level completed: 2%, Points required for next Level: 491
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    Whittier, CA
    Beiträge
    5.791
    Points
    20.859
    Level
    91
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von jsharrad
    Anti-QJ, use psplink. It's not an emulator but you can use it to load your programs on your psp from your pc's terminal window via USB or wifi no copying over to the psp necessary.

    Code:
    svn co svn://svn.ps2dev.org/psp/trunk/psplink
    Thanks dude!



  2. #2732
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    Insomniac - That was what I was planning on doing as my theory. I need to project my texture over enough triangles, to the point where each one is smalelr than a pixel on screen, that way when they do get culled, it won't show as the one next to it is in it's place and showing hte texture as it should. I just need a method of projecting the texture over a lot of triangles. I remember i asked this as ps2dev a way while back, so ill check there in the morning, Til then, im off to bed as i have school tomorrow, and homework i need to do during school

    Also, after placing a simple cube that would resemble a person in my little world, the sky box is HUGE... With nothing else but it there, it doesnt seem to big, rather that your walking slow. But after placing a cube in there, i saw just how big it is... I say I could fit a nice little maze within it. Once that is done, ill start with heightmapping and collision on all 3 axis (right now i just substitute the Y axis as the Z, with a few tweaks so it turns out right...)

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here


  3. #2733
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    I wouldn't make your triangles that small.

    Just tesselate your mesh until you get a decent result.

    Good luck with the 3D collision.

    By the way, sky dome > sky box ;)

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  4. #2734
    Heroes never die
    Points: 8.645, Level: 62
    Level completed: 65%, Points required for next Level: 105
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    ...........
    Beiträge
    1.323
    Points
    8.645
    Level
    62
    Downloads
    0
    Uploads
    0

    Standard

    sill not working
    Code:
      sceIoLseek(in, tmp->psar, SEEK_SET); 
      sceIoRead(in, checkextension , 4);
    
      if( strcmp (checkextension,"PSAR") == 0)
      {
    if( strcmp (checkextension,"PSAR") == 0) is still false

    mayby the fault is here sceIoRead(in, checkextension , 4);
    what it needs to do , reading the offset and stores the first 4 bytes in checkextension , that 4bytes need to be PSAR

  5. #2735
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    hallo - extensions usually start with '.'. Maybe it's returning false because your comparing '.PSA' with 'PSAR'.

    Insomniac - Sky dome is better, but I dont want to mess with spheres until I know I will get a decent framerate (i havent hte slightest clue whether or not a cube takes less CPU than a sphere when creating/rendering, but seeing as how a sphere must have ALOT of verticies, Im guessing the cube is less of a hassle with the CPU.. Please correct me if im guessing wrong).

    Oh and I think you mean 'tessellate' ;) And I know i can make alot of small squares make up a wall, but hte problem is that I need to than project my texture over them. To do this, Im thinking of using offsets of the texture per square. Im looking into it now as we speak. Once thats done, ill apply collision, than make a start and finish with their appropriate collision and whatnot. Than, ill start my map structure...
    -= Double Post =-
    Ok, i know how to do it. When setting the UV coordinates, its as if im setting offests. Now itll be very easy to do.
    -= Double Post =-
    Is anyone on right now, that has some knowledge of using a 3D API? I have a few questions, one thing new I learned is setting a textures envirorment parameter to GL_DECAL, rather than GL_MODULATE, it will prevent any lighting and/or coloring done to the texture, this was currently a problem as whenever I drew ANYTHING, be it a cube or my gridded ground, id get a colored sky box, now it's just peachy.

    But, im still having trouble with culling. Setting my near-z value in my perspective to a greater amount, certainly has helped (now the grided floor shows, but not both ses of lines all the time. I have a question though, setting it any higher (right now it's 2.0f, the default (my regular usage) is 0.1f) make it worse? Also, if someone is on (Raphael, Insomniac, yaustar, etc.) is there anyway i can talk to you via instant messenger? Be it, IRC, MSN, Aim or some other type of messenger? Thatd be great :o Im still a novice at 3D programming, but Im moving, slowly but surely.
    Geändert von SG57 (02-12-2007 um 10:26 PM Uhr) Grund: Automerged Doublepost

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here


  6. #2736
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    You can increase it past that, but it's never going to be a complete way of avoiding the clipping.

    Subdivision (whether it be lines, triangles or whatever) combined with increasing the near plane is a decent way of doing it.

    I've PM'd you my AIM, I'll be home from work in less than an hour.

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  7. #2737
    QJ Gamer Silver
    Points: 14.087, Level: 77
    Level completed: 10%, Points required for next Level: 363
    Overall activity: 0%

    Registriert seit
    Jan 2006
    Ort
    Germany
    Beiträge
    926
    Points
    14.087
    Level
    77
    Downloads
    0
    Uploads
    0

    Standard

    @hallo007: That's because you do something very bad and that is writing to unallocated memory:
    Code:
      char *checkextension;
      ...
      sceIoLseek(in, tmp->psar, SEEK_SET); //zoeken naar data.spar in eboot 
      sceIoRead(in, checkextension , 4);
     
      if( strcmp (checkextension,"PSAR") != 0)//als er een dat.spar is
      {
    Make that first line THIS instead:
    Code:
    char checkextension[5];
    checkextension[4]=0;
    @SG57: You NEED to tesselate/subdivide your faces on PSP to avoid unwanted culling. There was a very good thread on PS2dev where someone explained the exact reason for the PSP to act like that. Also, you can reach me via ICQ most of the time (just not this week, because I'm not at home).
    Also, regarding your texture modes, try GL_REPLACE if you want to completely avoid any mixing of the texture with the background. GL_DECAL is another apply mode that still blends in the current fragment (vertex) color when the color mode is GL_RGBA. GL_DECAL == GL_REPLACE for GL_RGB though.
    Read here for a complete specification of the modes (it's for openGL-ES actually, but it's the same for standard openGL).
    Raphs board rules #31: Excessive use of punctuation is either a sign of a lesser ego or a small mind. Avoid it if you don't want to look like a total moron.
    Raphs board rules #17: When you need to ask whether you are capable of doing something, you are not.
    Raphs board rules #2: Exploits aren't found by changing version numbers, blindly merging data into a file or turning your PSP upside down.
    Raphs board rules #1: If you have no clue how exploits work, don't come up with ideas about them.

  8. #2738
    QJ Gamer Green
    Points: 9.253, Level: 64
    Level completed: 68%, Points required for next Level: 97
    Overall activity: 0%

    Registriert seit
    Feb 2006
    Ort
    Australia - A.C.T.
    Beiträge
    1.517
    Points
    9.253
    Level
    64
    Downloads
    0
    Uploads
    0

    Standard

    ok i have just gone back to realy basic code to re freash my memery and i can work out why this simple code doesn't work.
    Code:
    #include <pspkernel.h>
    #include <pspdebug.h>
    PSP_MODULE_INFO("CONVERTER", 0, 1, 1);
    #define printf pspDebugScreenPrintf
    /* Exit callback */
    int exit_callback(int arg1, int arg2, void *common) {
              sceKernelExitGame();
              return 0;
    }
    
    /* Callback thread */
    int CallbackThread(SceSize args, void *argp) {
              int cbid;
    
              cbid = sceKernelCreateCallback("Exit Callback", exit_callback, NULL);
              sceKernelRegisterExitCallback(cbid);
    
              sceKernelSleepThreadCB();
    
              return 0;
    }
    
    /* Sets up the callback thread and returns its thread id */
    int SetupCallbacks(void) {
              int thid = 0;
    
              thid = sceKernelCreateThread("update_thread", CallbackThread, 0x11, 0xFA0, 0, 0);
              if(thid >= 0) {
                        sceKernelStartThread(thid, 0, 0);
              }
    
              return thid;
    }
    
    int dec1 = 234;
    int bin1 = 0;
    
    #define RGB(r, g, b) ((r)|((g)<<8)|((b)<<16));
    
    int main() {
    pspDebugScreenInit();
    SetupCallbacks();
    
    if (dec1 > 255) {
    pspDebugScreenPrintf("ERROR ");
    }
    
    if (dec1 < 0) {
    pspDebugScreenPrintf("ERROR ");
    }
    
    if (dec1 >= 128) {
    bin1 = 10000000;
    dec1 = (dec1 - 128);
    }
    
    if (dec1 >= 64) {
    bin1 = 1000000;
    dec1 = (dec1 - 64);
    }
    
    if (dec1 >= 32) {
    bin1 = 100000;
    dec1 = (dec1 - 32);
    }
    
    if (dec1 >= 16) {
    bin1 = 10000;
    dec1 = (dec1 - 16);
    }
    
    if (dec1 >= 8) {
    bin1 = 1000;
    dec1 = (dec1 - 8);
    }
    
    
    if (dec1 >= 4) {
    bin1 = 100;
    dec1 = (dec1 - 4);
    }
    
    if (dec1 >= 2) {
    bin1 = 10;
    dec1 = (dec1 - 2);
    }
    
    if (dec1 >= 1) {
    bin1 = 1;
    dec1 = (dec1 - 1);
    }
    
    
    
    
    printf(bin1);
    printf(dec1);
    
    
    sceKernelSleepThread();
    
    return 0;
    }

  9. #2739
    QJ Gamer Silver
    Points: 7.385, Level: 57
    Level completed: 18%, Points required for next Level: 165
    Overall activity: 0%

    Registriert seit
    Sep 2006
    Ort
    Finland
    Beiträge
    752
    Points
    7.385
    Level
    57
    Downloads
    0
    Uploads
    0

    Standard

    mafia1ft: It's because printf requires a char variable, and you're giving it an int. Try printf("%i", bin1); instead of printf(bin1);.
    wheeee =:D

  10. #2740
    QJ Gamer Silver
    Points: 14.087, Level: 77
    Level completed: 10%, Points required for next Level: 363
    Overall activity: 0%

    Registriert seit
    Jan 2006
    Ort
    Germany
    Beiträge
    926
    Points
    14.087
    Level
    77
    Downloads
    0
    Uploads
    0

    Standard

    PS: If you're supposing to print the binary representation of a number with that, then you're off. It will only print the least significant one-bit. If you want the real binary, use bin1+=.
    Also, there are more elegant ways to get done what you want :P Try using a loop and use shifts.
    Raphs board rules #31: Excessive use of punctuation is either a sign of a lesser ego or a small mind. Avoid it if you don't want to look like a total moron.
    Raphs board rules #17: When you need to ask whether you are capable of doing something, you are not.
    Raphs board rules #2: Exploits aren't found by changing version numbers, blindly merging data into a file or turning your PSP upside down.
    Raphs board rules #1: If you have no clue how exploits work, don't come up with ideas about them.

  11. #2741
    Heroes never die
    Points: 8.645, Level: 62
    Level completed: 65%, Points required for next Level: 105
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    ...........
    Beiträge
    1.323
    Points
    8.645
    Level
    62
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von Raphael
    @hallo007: That's because you do something very bad and that is writing to unallocated memory:
    Code:
      char *checkextension;
      ...
      sceIoLseek(in, tmp->psar, SEEK_SET); //zoeken naar data.spar in eboot 
      sceIoRead(in, checkextension , 4);
     
      if( strcmp (checkextension,"PSAR") != 0)//als er een dat.spar is
      {
    Make that first line THIS instead:
    Code:
    char checkextension[5];
    checkextension[4]=0;
    @SG57: You NEED to tesselate/subdivide your faces on PSP to avoid unwanted culling. There was a very good thread on PS2dev where someone explained the exact reason for the PSP to act like that. Also, you can reach me via ICQ most of the time (just not this week, because I'm not at home).
    Also, regarding your texture modes, try GL_REPLACE if you want to completely avoid any mixing of the texture with the background. GL_DECAL is another apply mode that still blends in the current fragment (vertex) color when the color mode is GL_RGBA. GL_DECAL == GL_REPLACE for GL_RGB though.
    Read here for a complete specification of the modes (it's for openGL-ES actually, but it's the same for standard openGL).
    thnx
    but it is possible that ps2dev.org is down because i need to reinstall cygwin and he cant connect to the server

  12. #2742
    QJ Gamer Silver
    Points: 14.087, Level: 77
    Level completed: 10%, Points required for next Level: 363
    Overall activity: 0%

    Registriert seit
    Jan 2006
    Ort
    Germany
    Beiträge
    926
    Points
    14.087
    Level
    77
    Downloads
    0
    Uploads
    0

    Standard

    Yes, ps2dev is down. Cygwin itself doesn't require ps2dev though, so I suppose you mean that you need to install the pspsdk :P
    Raphs board rules #31: Excessive use of punctuation is either a sign of a lesser ego or a small mind. Avoid it if you don't want to look like a total moron.
    Raphs board rules #17: When you need to ask whether you are capable of doing something, you are not.
    Raphs board rules #2: Exploits aren't found by changing version numbers, blindly merging data into a file or turning your PSP upside down.
    Raphs board rules #1: If you have no clue how exploits work, don't come up with ideas about them.

  13. #2743
    Heroes never die
    Points: 8.645, Level: 62
    Level completed: 65%, Points required for next Level: 105
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    ...........
    Beiträge
    1.323
    Points
    8.645
    Level
    62
    Downloads
    0
    Uploads
    0

    Standard

    yeah , thats a big prob ,dam:P
    -= Double Post =-
    wow , see this
    Code:
    Your group is currently "mkpasswd".  This indicates that
    the /etc/passwd (and possibly /etc/group) files should be rebuilt.
    See the man pages for mkpasswd and mkgroup then, for example, run
    mkpasswd -l [-d] > /etc/passwd
    mkgroup  -l [-d] > /etc/group
    Note that the -d switch is necessary for domain users.
    what do i need to do?
    Geändert von hallo007 (02-13-2007 um 11:42 AM Uhr) Grund: Automerged Doublepost

  14. #2744
    QJ Gamer Green
    Points: 9.253, Level: 64
    Level completed: 68%, Points required for next Level: 97
    Overall activity: 0%

    Registriert seit
    Feb 2006
    Ort
    Australia - A.C.T.
    Beiträge
    1.517
    Points
    9.253
    Level
    64
    Downloads
    0
    Uploads
    0

    Standard

    ok i have a number that changes in how many digits are in it but nerver over 8 is that a way i can have it always display as a 8 digit number. put have 0 at the front ?

  15. #2745
    Heroes never die
    Points: 8.645, Level: 62
    Level completed: 65%, Points required for next Level: 105
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    ...........
    Beiträge
    1.323
    Points
    8.645
    Level
    62
    Downloads
    0
    Uploads
    0

    Standard

    Code:
    if(digit<10)
    {
    printf("0000000%i",digit);
    }
    else if(digit>100 && digit >=10)
    {
    printf("000000%i",digit);
    }
    .....

  16. #2746
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von mafia1ft
    ok i have a number that changes in how many digits are in it but nerver over 8 is that a way i can have it always display as a 8 digit number. put have 0 at the front ?
    Code:
    printf("%08d", theNumber);

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  17. #2747
    Heroes never die
    Points: 8.645, Level: 62
    Level completed: 65%, Points required for next Level: 105
    Overall activity: 0%

    Registriert seit
    Aug 2006
    Ort
    ...........
    Beiträge
    1.323
    Points
    8.645
    Level
    62
    Downloads
    0
    Uploads
    0

    Standard

    nice dindt knew that function




    anyway still not fixed
    Code:
    Your group is currently "mkpasswd".  This indicates that
    the /etc/passwd (and possibly /etc/group) files should be rebuilt.
    See the man pages for mkpasswd and mkgroup then, for example, run
    mkpasswd -l [-d] > /etc/passwd
    mkgroup  -l [-d] > /etc/group
    Note that the -d switch is necessary for domain users.
    shows when cygwin start ups

  18. #2748
    likes kittens....awww....
    Points: 6.975, Level: 55
    Level completed: 13%, Points required for next Level: 175
    Overall activity: 0%

    Registriert seit
    Sep 2006
    Ort
    Detroit
    Beiträge
    628
    Points
    6.975
    Level
    55
    Downloads
    0
    Uploads
    0

    Standard

    What header file do I need to include to use sceSyscon functions ?

  19. #2749
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    pspsyscon.h

    Would it have been that hard to look through your include directory, browse the documentation or even taken a wild guess?

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  20. #2750
    likes kittens....awww....
    Points: 6.975, Level: 55
    Level completed: 13%, Points required for next Level: 175
    Overall activity: 0%

    Registriert seit
    Sep 2006
    Ort
    Detroit
    Beiträge
    628
    Points
    6.975
    Level
    55
    Downloads
    0
    Uploads
    0

    Standard

    Zitat Zitat von Insert_Witty_Name
    pspsyscon.h

    Would it have been that hard to look through your include directory, browse the documentation or even taken a wild guess?
    "error: pspsyscon.h: No such file or directory"
    I can't find that file in my include dir, can you upload pspsyscon.h?

  21. #2751
    Developer
    Points: 7.577, Level: 58
    Level completed: 14%, Points required for next Level: 173
    Overall activity: 0%

    Registriert seit
    Mar 2006
    Beiträge
    1.026
    Points
    7.577
    Level
    58
    Downloads
    0
    Uploads
    0

    Standard

    It'd be no use on it's own.

    This is why you should install the toolchain yourself and not use one of those pre-packaged binary setups, you're stuck with whatever revision the setup has.

    If you have installed the toolchain yourself, then update it.

    Check out my homebrew & C tutorials at http://insomniac.0x89.org/
    Coder formerly known as Insomniac197

    tshirtz: what is irshell ??
    Atarian_: it's where people who work for the IRS go when they die

  22. #2752
    likes kittens....awww....
    Points: 6.975, Level: 55
    Level completed: 13%, Points required for next Level: 175
    Overall activity: 0%

    Registriert seit
    Sep 2006
    Ort
    Detroit
    Beiträge
    628
    Points
    6.975
    Level
    55
    Downloads
    0
    Uploads
    0

    Standard

    WTF
    $ make
    make: *** No rule to make target `CFLAGS', needed by `gShell.elf'. Stop.
    Makefile :
    Spoiler for Makefile:
    TARGET = gShell
    OBJS = main.o \
    flib.o \
    framebuffer.o \
    graphics.o \
    filebrowser.o \
    oggplayer.o \
    mp3player.o \
    gfx.o \
    plasma.o \
    CFLAGS = -O2 -G0 -Wall
    CXXFLAGS = $(CFLAGS) -fno-exceptions -fno-rtti
    ASFLAGS = $(CFLAGS)
    LIBS = -lpspctrl -lpspgu -lfreetype -lmad -lpspaudiolib -lpspaudio -lpsppower -lpspumd -lpng -lpsprtc -lpspusb -lpspusbstor -lz -lm -lvorbisidec
    PSP_EBOOT_TITLE = gShell
    EXTRA_TARGETS = EBOOT.PBP
    PSPSDK=$(shell psp-config --pspsdk-path)
    include $(PSPSDK)/lib/build.mak

  23. #2753
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    psp - Are you aware of what hte '\' character is for? *smacks head*

    Remove the '\' after plasma.o
    -= Double Post =-
    Rahpael - Id like to talk to you sometime, I dont have an ICQ #, but Ill make one. Insoniac helped my problem last night, it was a beginners mistake, I was setting the right texture offsets, but I forgot to apply them to the verticies as well (so it'd translate the vertex to make up 1/256 of the square).

    Im just starting to mess around with it so it displays right, as of now its awfully slow and doesnt display correctly. Im working on it though.

    P.S. Im 'honored' to know I can talk to you directly, instantly for a change :o
    Geändert von SG57 (02-13-2007 um 06:20 PM Uhr) Grund: Automerged Doublepost

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here


  24. #2754
    likes kittens....awww....
    Points: 6.975, Level: 55
    Level completed: 13%, Points required for next Level: 175
    Overall activity: 0%

    Registriert seit
    Sep 2006
    Ort
    Detroit
    Beiträge
    628
    Points
    6.975
    Level
    55
    Downloads
    0
    Uploads
    0

    Standard

    now it gives me a bunch of crap when I remove the \
    Spoiler for Error:
    Code:
    $ make
    /usr/bin/psp-ld -T tiffsdk.x -L/usr/psp/sdk/lib main.o gfx.o tiffsdk.o -o main.e
    lf
    main.o: In function `InitGlobals':
    main.c:(.text+0x14): relocation truncated to fit: R_MIPS_GPREL16 against `plasma
    _frequency'
    main.c:(.text+0x1c): relocation truncated to fit: R_MIPS_GPREL16 against `plasma
    _wav_amp'
    main.c:(.text+0x2c): relocation truncated to fit: R_MIPS_GPREL16 against `sp1'
    main.c:(.text+0x34): relocation truncated to fit: R_MIPS_GPREL16 against `sp2'
    main.c:(.text+0x3c): relocation truncated to fit: R_MIPS_GPREL16 against `sp3'
    main.c:(.text+0x44): relocation truncated to fit: R_MIPS_GPREL16 against `sp4'
    main.c:(.text+0x48): relocation truncated to fit: R_MIPS_GPREL16 against `.sbss'
    
    main.c:(.text+0x4c): relocation truncated to fit: R_MIPS_GPREL16 against `.sbss'
    
    main.c:(.text+0x50): relocation truncated to fit: R_MIPS_GPREL16 against `.sbss'
    
    main.c:(.text+0x54): relocation truncated to fit: R_MIPS_GPREL16 against `.sbss'
    
    main.c:(.text+0x58): additional relocation overflows omitted from the output
    make: *** [main] Error 1

  25. #2755
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    Well, that 'crap' is your poor programming skills in action (or copy paste job ;)). My best guess is that your trying to compile that plasma demo someone made over at psp-programming, or some variation of it, and not linking the correct libraries needed on the LIBS line.

    Raphael & Insomniac [& yaustar] - This gives me a slow, dark green (from cube i drew after it ) blob it looks like. Im sure it is theh sky box, but doesnt have hte texture and doesnt look right as it is dark green, even with GL_DECAL or GL_REPLACE....

    Code:
    void Draw_Skybox(float x, float y, float z, float width, float height, float length)
    {
    	// Center the Skybox around the given x,y,z position
    	height += 4;
    	width += 4;
    	length += 4;
    	
    	glTranslatef(x - width  / 2,y - height / 2,z - length / 2); // center
    	
    	// Center the Skybox around the given x,y,z position
    	x = x - width  / 2;
    	y = y - height / 2 + 30;
    	z = z - length / 2;
     
         glScalef(width,height,length); // scale to size
         
         for(i=0;i<256;i+=5) {
           for(j=0;j<256;j+=5) {
         	// Draw Front side
         	glBindTexture(GL_TEXTURE_2D, SkyboxTexture[SKYFRONT]);
         	glBegin(GL_QUADS);	
         		glTexCoord2f(STEP*i, 0.0f); glVertex3f(0,		  0,		1.0f);
         		glTexCoord2f(STEP*i, STEP*j); glVertex3f(0,		  STEP*j, 1.0f);
         		glTexCoord2f(0.0f, STEP*j); glVertex3f(STEP*i, STEP*j, 1.0f); 
         		glTexCoord2f(0.0f, 0.0f); glVertex3f(STEP*i, 0,		1.0f);
         	glEnd();
         
         	// Draw Back side
         	glBindTexture(GL_TEXTURE_2D, SkyboxTexture[SKYBACK]);
         	glBegin(GL_QUADS);		
         		glTexCoord2f(STEP*i, 0.0f); glVertex3f(STEP*i, 0.0f,		0.0f);
         		glTexCoord2f(STEP*i, STEP*j); glVertex3f(STEP*i, STEP*j, 0.0f); 
         		glTexCoord2f(0.0f, STEP*j); glVertex3f(0.0f,		  STEP*j,	0.0f);
         		glTexCoord2f(0.0f, 0.0f); glVertex3f(0.0f,		  0.0f,		0.0f);
         	glEnd();
         
         	// Draw Left side
         	glBindTexture(GL_TEXTURE_2D, SkyboxTexture[SKYLEFT]);
         	glBegin(GL_QUADS);		
         		glTexCoord2f(STEP*i, STEP*j); glVertex3f(0.0f,		  STEP*i,	0);	
         		glTexCoord2f(0.0f, STEP*j); glVertex3f(0.0f,		  STEP*i,	STEP*j); 
         		glTexCoord2f(0.0f, 0.0f); glVertex3f(0.0f,		  0.0f,		STEP*j);
         		glTexCoord2f(STEP*i, 0.0f); glVertex3f(0.0f,		  0.0f,		0.0f);		
         	glEnd();
         
         	// Draw Right side
         	glBindTexture(GL_TEXTURE_2D, SkyboxTexture[SKYRIGHT]);
         	glBegin(GL_QUADS);
         		glTexCoord2f(STEP*i, STEP*j); glVertex3f(1.0f, 0.0f,		0.0f);
         		glTexCoord2f(0.0f, STEP*j); glVertex3f(1.0f, 0,		STEP*j);
         		glTexCoord2f(0.0f, 0.0f); glVertex3f(1.0f, STEP*i,	STEP*j); 
         		glTexCoord2f(STEP*i, 0.0f); glVertex3f(1.0f, STEP*i,	0.0f);
         	glEnd();
         
         	// Draw Up side
         	glBindTexture(GL_TEXTURE_2D, SkyboxTexture[SKYUP]);
         	glBegin(GL_QUADS);		
         		glTexCoord2f(0.0f, 0.0f); glVertex3f(STEP*i, 1.0f, 0.0f);
         		glTexCoord2f(STEP*i, 0.0f); glVertex3f(STEP*i, 1.0f, STEP*j); 
         		glTexCoord2f(STEP*i, STEP*j); glVertex3f(0.0f,		  1.0f,	STEP*j);
         		glTexCoord2f(0.0f, STEP*j); glVertex3f(0.0f,		  1.0f,	0.0f);
         	glEnd();
         
         	// Draw Down side
         	glBindTexture(GL_TEXTURE_2D, SkyboxTexture[SKYDOWN]);
         	glScalef(width,height,length); // scale to size
         	glBegin(GL_QUADS);		
         		glTexCoord2f(0.0f, 0.0f); glVertex3f(0.0f,		  0.0f,		0.0f);
         		glTexCoord2f(STEP*i, 0.0f); glVertex3f(0.0f,		 0.0f,		STEP*j);
         		glTexCoord2f(STEP*i, STEP*j); glVertex3f(STEP*i, 0.0f,		STEP*j); 
         		glTexCoord2f(0.0f, STEP*j); glVertex3f(STEP*i, 0.0f,		0.0f);
         	glEnd();
           }
         }
         glDisable(GL_TEXTURE_2D);
    }
    Im thinking of getting rid of the scaling, along with translation call in the function, and using the verticies points for where to place them, and to 'scale' them (i wont actually scale htem, rather just build the sky box the size it is, without scaling a 1x1x1 cube).

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here


  26. #2756
    Points: 3.523, Level: 37
    Level completed: 16%, Points required for next Level: 127
    Overall activity: 99,0%

    Registriert seit
    Feb 2007
    Beiträge
    16
    Points
    3.523
    Level
    37
    Downloads
    0
    Uploads
    0

    Standard

    I'm having a problem running the toolchain.sh file when setting up the toolchain. Here's a screenshot of it:

  27. #2757
    QJ Gamer Blue
    Points: 3.642, Level: 37
    Level completed: 95%, Points required for next Level: 8
    Overall activity: 0%

    Registriert seit
    Feb 2007
    Beiträge
    99
    Points
    3.642
    Level
    37
    Downloads
    0
    Uploads
    0

    Standard

    Atin, some guy just posted this thread:
    http://forums.qj.net/f-psp-developme...ead-95565.html

    Try posting it there, he may be able to help. I personally don't know much about this, since i myself haven't completely installed cygwin yet.

  28. #2758
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    That guy is super, and he totally disregarded a largely spread rule, *Search*.

    Cygwin Help Thread

    AS for your problem Atin, I had the same problme a long time ago, I made a tutorial on how to do it with that error, it ended up with me downloading whatever link to the file it was trying to get. There's 3 in total; binutils,newlib and gcc i believe...

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here


  29. #2759
    Points: 3.523, Level: 37
    Level completed: 16%, Points required for next Level: 127
    Overall activity: 99,0%

    Registriert seit
    Feb 2007
    Beiträge
    16
    Points
    3.523
    Level
    37
    Downloads
    0
    Uploads
    0

    Standard

    Thanks that's exactly what I needed.

  30. #2760
    words are stones in my <3
    Points: 35.274, Level: 100
    Level completed: 0%, Points required for next Level: 0
    Overall activity: 0%

    Registriert seit
    Jul 2005
    Ort
    Spokane
    Beiträge
    5.008
    Points
    35.274
    Level
    100
    My Mood
    Lonely
    Downloads
    1
    Uploads
    0

    Standard

    All with the same or nearly hte same problem as Atin, check my newly created thread here, or go here:

    http://www.psp-programming.com/forum...php?topic=1178

    ...at what speed must I live.. to be able to see you again?...

    Projects

    You can support my Open World 3D RPG for PSP by voting for it here



 

Tags for this Thread

Forumregeln

  • Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
  • Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
  • Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
  • Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.
  •  





Alle Zeitangaben in WEZ -8. Es ist jetzt 09:28 PM Uhr.

Use of this Web site constitutes acceptance of the TERMS & CONDITIONS and PRIVACY POLICY
Copyright © , Caputo Media, LLC. All Rights Reserved. Cluster .