Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
66 user(s) are online (44 user(s) are browsing Forums)

Members: 0
Guests: 66

more...

Headlines

Forum Index


Board index » All Posts (Shadow)




Re: Torque for OS4 progress
Just popping in
Just popping in


@kas1e

I currently consider it to be Alpha :)

I only have the demo assest provided by Garage Games, but if they will let me release this demo for Amiga, then I will make it available, once I feel that it is stable enough.

Go to top


Torque for OS4 progress
Just popping in
Just popping in


Hello,

I just wanted to let everyone know that you can now follow the progress of the Torque port for OS4 on http://www.game-engine.dk

Go to top


Re: SilverGreen Theme
Just popping in
Just popping in


@tommo1975

Change the color in the textures:
SYS:Prefs/Presets/SilverGreen/Bitmaps/Titlebar/

Go to top


Re: My Take on timberwolf logo
Just popping in
Just popping in


@magic

even though it is dark the light appears to be coming from different directions, which makes it look a little odd.

Go to top


Re: developers, what are you working on?
Just popping in
Just popping in


@spotUP

xscreensavers
TGE
MiniGL

Go to top


Re: Are AmigaOS4 SDK compiler, MACRO compilers ?
Just popping in
Just popping in


@freddix

I actually had to look up what macro compilers might mean, this might be it, not sure: http://en.wikipedia.org/wiki/Macro_(computer_science)

But yes you can write macros in c/c++ using the #define preprocessor statement, a classic example:

#define safe_free(x) { \
free(x);\
 x 
NULL;\
}

Go to top


Re: GCC, Dynamic structure creation method ?
Just popping in
Just popping in


@Gazelle

But if you use a typedef, you dont need to type

struct MyStruct {int data;};

struct MyStruct someStruct;
struct MyStructsameStruct;
sameStruct = &someStruct;


you can just type:
typedef struct {int data;} MyStruct;

MyStruct someStruct;
MyStructsameStruct;
sameStruct = &someStruct;

Go to top


Re: GCC, Dynamic structure creation method ?
Just popping in
Just popping in


@freddix

I changed a little but I did not test if it compiles :
/* Structure de Basic 3D qui peut-?tre partag?e pour les donn?es*/
typedef struct {
  
int B3DObjectAmount;
  
int *ObjectList;
  
int *LastCreatedObject;
 }
Basic3DStructType;
Basic3DStructType Basic3D;

typedef struct {
  
BOOL Exist;
  
int *PreviousObject;
  
int *NextObject;
  
int ID;
  
int Type;
  
float XPosYPosZPos;
  
float XRotYRotZRot;
  
float XScaleYScaleZScale;
  
int *TextureImage;
  
BOOL HiddenCullingTransparencyWireFrameFogAmbientLightsFiltering;
  
float RGBRedRGBGreenRGBBlue;
  
BOOL IsGhost;
  
int GhostMode;
  
int DiffuseAmbienceSpecularEmissiveSpecularPower;
  
int *DetailMappingImageSmoothingAlphaMappingPercent;
 }
Object3DType;
 

// #include "_SystemIncludes.c"
#include "Basic3D_EngineInformations.c"

/* 0. System functions unavailable to user */
Object3DType *Allocate3DObjectint ObjectID ){                  // is line 49
  
Object3DType *NewObject IExec -> AllocVecTagssizeofObject3DType ), TAG_DONE );
  if ( !
NewObject ){
    return 
NULL;
   }
  
// On modifie les param?tres de l'objet 3D fraichement cr?e.
  
NewObject->PreviousObject Basic3D.LastCreatedObject;
  
NewObject->Exist 1;
  
NewObject->ID ObjectID;
  
NewObject->PreviousObject Basic3D.LastCreatedObject;
  
NewObject->RGBRed 255;
  
NewObject->RGBGreen 255;
  
NewObject->RGBBlue 255;
  
// On ins?re dans l'avant dernier objet 3D la r?f?rence du nouvel objet 3D.
  
Object3DType *OldObject Basic3D.LastCreatedObject;
  
OldObject->NextObject NewObject;
  
// On ins?re le nouvel objet cr?e dans la structure de Basic3D.
  
Basic3D.LastCreatedObject NewObject;
  
Basic3D.B3DObjectAmount++;
  return 
NewObject;
 }

void Free3DObjectObject3DType *OldObject ){
  if ( 
OldObject != NULL ){
    
IExec -> FreeVecOldObject );
   }
 }


void BASIC3D_Constructorvoid ){
 }

void BASIC3D_Destructorvoid ){
  
// Suppression de tous les objets 3D existants restants.
  
if ( Basic3D.B3DObjectAmount ){
    
// On r?cup?re l'objet en m?moire en Basic3D
    
Object3DType *NewObject Basic3D.LastCreatedObject;
    do{
      
Basic3D.B3DObjectAmount--;
       
Object3DType *NextToDelete NewObject->PreviousObject;
/*      Free3DObject( *NewObject );*/
      
*NewObject = *NextToDelete;
     } while ( !
NewObject );
    if ( 
Basic3D.B3DObjectAmount != NULL ){
     
// Afficher un message d'erreur si la quantit? d'objets restants est > 0 alors que la liste est vide.
     
}
   }
 }

Go to top


Re: GCC, Dynamic structure creation method ?
Just popping in
Just popping in


@freddix

Can you paste in the entire struct?

Go to top


Re: GCC, Dynamic structure creation method ?
Just popping in
Just popping in


@freddix


I think this is wrong:

typedef struct Object3DType{
 ...
 };


and should be:

typedef struct {
 ...
 } 
Object3DType;

Go to top


Re: TGE on Amiga
Just popping in
Just popping in


@Shadow

No ETA.

I am currently debugging network code, but debugging tools on the amiga are shashimi and IExec->DebugPrintF

Unfortunetely even in single player mode the networking code is used. It does not send anything, but Torque is designed always to have a server and a client. I am looking into it but it is difficult.

Go to top


Re: TGE on Amiga
Just popping in
Just popping in


@Shadow

And it is still alive, just moving very slowly :)

Go to top


Re: OpenGL - Small Stars scroll 4 layers.
Just popping in
Just popping in


@freddix

char buf[256];
int i 23043;

sprintf(buf"%d"i);

Go to top


Re: OpenGL - Small Stars scroll 4 layers.
Just popping in
Just popping in


@freddix

No then it works as expected, rendering is only done when you tell it to render with glutPostRedisplay.

Go to top


Re: OpenGL - Small Stars scroll 4 layers.
Just popping in
Just popping in


@freddix

glutPostRedisplay tells glut to start rendering. glFlush empties the OpenGL command queue.

Idle function is always being called by GLUT while the rendering function is actually only called when something happens to the window eg. it is moved. I am not sure this is true for the amiga port of GLUT though.

Anyway because the rendering function is rarely called you should use the idle function to update your geometry and other stuff, then when that is done you use glutPostRedisplay to tell GLUT that now would be a good time to do some rendering.

Does that make sence?

Go to top


Re: OpenGL - Small Stars scroll 4 layers.
Just popping in
Just popping in


@Shadow

An other thing you should do was to change your idle function

/* OpenGL Sample #1
    SStar scrolling with 4 parallaxs
*/

#include <GL/glut.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <math.h>

float PosXY[256][2];

/*  WHAT WE WANT TO DISPLAY ON SCREEN MUST BE ADDED IN THIS FUNCTION */
void My_glRenderingvoid )
{
  
int i;
  
glClearColor0.00.00.00.0);    /* Set backdrop as black */
  
glClearGL_COLOR_BUFFER_BIT );   /* Clear the backdrop with glClearColor color */
  
glColor3f1.01.01.0 );

  
glBegin(GL_POINTS) ;
    for( 
00256 i++ ){
      
glVertex3fPosXY[i][1], PosXY[i][2], 0.0f );
     }
   
glEnd() ;
  
glFlush();
 }

void My_IdleFuncvoid
{
  
int imultiplier;
  for( 
0256 i++ ){
    
multiplier 0.25f;
    
PosXY[i][1] -= ( 0.00001f multiplier ) ;
    if ( 
PosXY[i][1] < 0.0 )
      
PosXY[i][1] = 1.0;
   }

  
glutPostRedisplay();
}

/* SOME INITIALIZATIONS HERE */
void My_glInitvoid )
{
  
glMatrixModeGL_PROJECTION );
  
glLoadIdentity() ;
  
glOrtho0.01.00.01.0, -1.01.0 );
 }

/* MAIN C PROCEDURE STARTUP-SEQUENCE IS HERE */
int main(int argcchar** argv)
{
  
int i;
  for( 
1256 i++ ){                                                                                                                           
    
PosXY[i][1] = rand() % 100000 100000.0 ;
    
PosXY[i][2] = rand() % 100000 100000.0 ;
   }

  
glutInit(&argcargv);    /* Initialize Glut */
  
glutInitDisplayMode(GLUT_SINGLE GLUT_RGBA);   /* Define display mode properties such as single buffer, color mode and  */
  
glutInitWindowSize640480 );         /* define the sizes of the window to create */
  
glutInitWindowPosition300300 );
  
glutCreateWindow("AmiDARK Test Window");       /* Create the final rendering window */


  
My_glInit();
  
glutDisplayFuncMy_glRendering );
  
glutIdleFuncMy_IdleFunc );
  
mglEnableSync(GL_TRUE );
  
glutMainLoop();

  return 
0;
 }

Go to top


Re: OpenGL - Small Stars scroll 4 layers.
Just popping in
Just popping in


@freddix

Great, but since your are in the optimizing mood you should change:

multiplier 4.0;


to:

multiplier 0.25f;





Oh and by the way.

You are looping to far, and accessing illegal memory.

Your array has 256 element but you are accessing 257 elements (0-256), your break condition should be i < 256.

Go to top


Re: OpenGL - Small Stars scroll 4 layers.
Just popping in
Just popping in


@freddix

Very well done.


But may I suggest the you move glBegin and glEnd outside the loop.

glBegin(GL_POINTS);
for(
0points; ++i)
{
    
glVertex(x,y,z);
}
glEnd();

Go to top


Re: LCD Montior Off on demand
Just popping in
Just popping in


@Slayer

I still dont get it, what is wrong with the power button on the LCD??


Go to top


Re: LCD Montior Off on demand
Just popping in
Just popping in


@Slayer

If you are going to press a hotkey to activate the program that turns off the LDD, and then later do another action to terminate the program. Then the simplest solution would be to press the button on your LCD

Go to top



TopTop
« 1 2 3 (4) 5 »




Powered by XOOPS 2.0 © 2001-2023 The XOOPS Project