Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (AndrewAMD, 7th_zorro, alibaba), 913 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 5 of 6 1 2 3 4 5 6
Re: Real DX9 Reflection [Re: Metal_Thrasher] #37752
12/31/04 12:11
12/31/04 12:11
Joined: Nov 2004
Posts: 832
United States, Utah
Braxton Offline
Developer
Braxton  Offline
Developer

Joined: Nov 2004
Posts: 832
United States, Utah
How do I add the original code to 3DGS... where can I get a dll. The one on the forum is for Visual C++ I need one for Dev-C++. I want to try this out but I need to know how.


"The GREAT LAW: Life is and always will be justly ordered, and that all past experiences, good and bad, were the equitable out working of our evolving, yet unevolved selves" - As A Man Thinketh
Re: Real DX9 Reflection [Re: Braxton] #37753
12/31/04 13:24
12/31/04 13:24
Joined: Oct 2003
Posts: 2,194
Saturn
Metal_Thrasher Offline
Expert
Metal_Thrasher  Offline
Expert

Joined: Oct 2003
Posts: 2,194
Saturn
It's not a dll, it's a wdl file using c-script not C++. It's in Wiki.


-Johnny Thrash
Re: Real DX9 Reflection [Re: Metal_Thrasher] #37754
12/31/04 13:34
12/31/04 13:34
Joined: Nov 2004
Posts: 832
United States, Utah
Braxton Offline
Developer
Braxton  Offline
Developer

Joined: Nov 2004
Posts: 832
United States, Utah
I am talking about the original... I want to use that one.


"The GREAT LAW: Life is and always will be justly ordered, and that all past experiences, good and bad, were the equitable out working of our evolving, yet unevolved selves" - As A Man Thinketh
Re: Real DX9 Reflection [Re: Braxton] #37755
12/31/04 13:42
12/31/04 13:42
Joined: Nov 2004
Posts: 832
United States, Utah
Braxton Offline
Developer
Braxton  Offline
Developer

Joined: Nov 2004
Posts: 832
United States, Utah
Well DragonX Dark - Do you have a link to the shader... can't seem to find on called DirextX9 Reflections shader.


"The GREAT LAW: Life is and always will be justly ordered, and that all past experiences, good and bad, were the equitable out working of our evolving, yet unevolved selves" - As A Man Thinketh
Re: Real DX9 Reflection [Re: Braxton] #37756
12/31/04 13:42
12/31/04 13:42
Joined: Oct 2003
Posts: 2,194
Saturn
Metal_Thrasher Offline
Expert
Metal_Thrasher  Offline
Expert

Joined: Oct 2003
Posts: 2,194
Saturn
Quote:

I am talking about the original... I want to use that one.



oh :P sorry


-Johnny Thrash
Re: Real DX9 Reflection [Re: Metal_Thrasher] #37757
12/31/04 13:46
12/31/04 13:46
Joined: Nov 2004
Posts: 832
United States, Utah
Braxton Offline
Developer
Braxton  Offline
Developer

Joined: Nov 2004
Posts: 832
United States, Utah
I want the link to your C-Script one now... PLEASE!!!


"The GREAT LAW: Life is and always will be justly ordered, and that all past experiences, good and bad, were the equitable out working of our evolving, yet unevolved selves" - As A Man Thinketh
Re: Real DX9 Reflection [Re: Metal_Thrasher] #37758
12/31/04 13:47
12/31/04 13:47
Joined: Oct 2003
Posts: 2,194
Saturn
Metal_Thrasher Offline
Expert
Metal_Thrasher  Offline
Expert

Joined: Oct 2003
Posts: 2,194
Saturn
Quote:

Well, HSB's code there is for taking the cobe map picture...the actual code for it is on the wiki page on the bottom of this page. I just used sky texture instead of a cobe map and I got a very pretty crome-effect.



You mean the one I was talking about here? with the crome effect?


-Johnny Thrash
Re: Real DX9 Reflection [Re: Metal_Thrasher] #37759
12/31/04 14:19
12/31/04 14:19
Joined: Nov 2004
Posts: 832
United States, Utah
Braxton Offline
Developer
Braxton  Offline
Developer

Joined: Nov 2004
Posts: 832
United States, Utah
What are you talking about???


"The GREAT LAW: Life is and always will be justly ordered, and that all past experiences, good and bad, were the equitable out working of our evolving, yet unevolved selves" - As A Man Thinketh
Re: Real DX9 Reflection [Re: Braxton] #37760
01/02/05 00:29
01/02/05 00:29
Joined: Jul 2004
Posts: 1,710
MMike Offline
Serious User
MMike  Offline
Serious User

Joined: Jul 2004
Posts: 1,710
this is MY code For "Real" Cube map DX8

:


var cuberesolution=128; // set up the resolution of the cube here
//var cubeposition[3]=0,0,200; // set up the position of the cube here (you could also set cubeposition to the camera position)
var cubeposition=player.pos; // set up the position of the cube here (you could also set cubeposition to the camera position)
var west[3]=180,0,0;
var north[3]=90,0,0;
var east[3]=0,0,0;
var south[3]=-90,0,0;
var down[3]=90,-90,0;
var up[3]=90,90,0;




bmap cube_panel =<cube.tga>;

panel cube_map{

layer=1;
bmap = cube_panel;
flags = visible, overlay;
pos_x=0;
pos_y=0;


}
view Cv_w
{
layer = 2;


pos_y = 0;
size_x = 128;
size_y = 128;
arc = 90;
aspect = 1;
flags= visible;

}


view Cv_n
{
layer = 2;

pos_y = 0;
size_x = 128;
size_y = 128;
arc = 90;
aspect = 1;
flags= visible;

}
view Cv_e
{
layer = 2;

pos_y = 0;
size_x = 128;
size_y = 128;
arc = 90;
aspect = 1;
flags= visible;

}
view Cv_s
{
layer = 2;

pos_y = 0;
size_x = 128;
size_y = 128;
arc = 90;
aspect = 1;
flags= visible;

}
view Cv_d
{
layer = 2;

pos_y = 0;
size_x = 128;
size_y = 128;
arc = 90;
aspect = 1;
flags= visible;

}
view Cv_u
{
layer = 2;

pos_y = 0;
size_x = 128;
size_y = 128;
arc = 90;
aspect = 1;
flags= visible;

}



var n=0;
var v=0;
var r=0;
var cubeposition1;
function CUbereal {





while(1){


cubeposition=player.pos;


vec_set(cv_w.x,cubeposition1);
vec_set(cv_w.pan,west);
cv_w.x=player.x;
cv_w.y=player.y;

v=-128;
n=1;
cv_w.pos_x=v+128*n;
n=2;
cv_n.pos_x=v+128*n;
n=3;
cv_e.pos_x=v+128*n;
n=4;
cv_s.pos_x=v+128*n;
n=5;
cv_d.pos_x=v+128*n;
n=6;
cv_u.pos_x=v+128*n;


vec_set(cv_n.x,cubeposition1);
vec_set(cv_n.pan,north);
cv_n.x=player.x;
cv_n.y=player.y;

vec_set(cv_e.x,cubeposition1);
vec_set(cv_e.pan,east);
cv_e.x=player.x;
cv_e.y=player.y;

vec_set(cv_s.x,cubeposition1);
vec_set(cv_s.pan,south);
cv_s.x=player.x;
cv_s.y=player.y;

vec_set(cv_d.x,cubeposition1);
vec_set(cv_d.pan,down);
cv_d.x=player.x;
cv_d.y=player.y;


vec_set(cv_u.x,cubeposition1);
vec_set(cv_u.pan,up);
cv_u.x=player.x;
cv_u.y=player.y;








wait(1);

}


}

bmap bcube=<shot_0.bmp>;
bmap bcube1=<shot_1.bmp>;



function take_cube {
player.invisible=on;
CUbereal();
player.invisible=on;
video_set(768,128,32,2);wait(2);
screenshot("shot_",_shot_no);
wait(2);
//video_switch(800,650,32,1);
video_switch(7,32,1);



}
//on_c CUbereal;
on_t take_cube;


}



function mtl_envmap_view()
{
mat_set(mtl.matrix,matViewInv);
mtl.matrix41=0;
mtl.matrix42=0;
mtl.matrix43=0;
}




function mtl_envmap_init()
{


player.invisible=on;
take_cube();
player.invisible=on;
//bmap_purge(bcube); // Get rid of what is in tex memory
// read from disk // as Skin1, else it will accumulate and
bmap_load(bcube, "shot_0.bmp",0);



//...maybe you should copy the mat_model properties here...

mtl.skin1=bcube;

bmap_to_cubemap(mtl.skin1);
mtl.event=mtl_envmap_view;
mtl.enable_view=on;
mtl.enable_render=on;
player.invisible=off;



}


material mtl_envmap
{

event=mtl_envmap_init;

effect=
"
texture entSkin1;
texture mtlSkin1;
matrix matMtl;
technique envmap
{
pass p0
{
texture[0]=<entSkin1>;
texture[1]=<mtlSkin1>;

zWriteEnable=true;
alphaBlendEnable=false;

colorArg1[0]=Texture;
colorOp[0]=Modulate2x;
colorArg2[0]=Diffuse;

colorArg1[1]=Texture;
colorOp[1]=blendCurrentAlpha;
addressU[1]=Clamp;
addressV[1]=Clamp;
texCoordIndex[1]=cameraSpaceReflectionVector;
textureTransformFlags[1]=Count3;
textureTransform[1]=<matMtl>; // transform camera space back to world space
}
}
";
}

//starter lol
//{mtl_envmap.skin1=bcube;
//wait(1);

//}


action Reflections {

//VLight_orange();
//physics_lamp();

// my.pan+=8*time;
// my.roll+=8*time;


my.material=mtl_envmap;
}


function mem {

//player.invisible=on;
player.invisible=on;


bmap_purge(mtl_envmap.skin1);
mtl_envmap.skin1=mtl_envmap.skin1;
mtl_envmap_init();


}

on_t mem;







action player1
{my.material=mtl_envmap;
player = my;
//my.invisible = on;
my.passable=on;
while (1)
{
camera.x=player.x;
camera.y=player.y;

//vec_set (camera.x, my.x);
//vec_set (camera.y, my.y);
//vec_set (camera.pos, my.pos);
//vec_set (camera.pos, my.pos);

camera.pan = my.pan;
camera.tilt += 10 * mouse_force.y * time;
my.pan -= 10 * mouse_force.x * time;
temp.x = 25 * (key_w - key_s) * time;
temp.y = 25 * (key_a - key_d) * time;
//temp.z = 0;

ent_move (temp, nullvector);
wait (1);
}

}






you need a bmap called.. go check it above lazy "shot_0.bmp"

Oh and [T] to save the cube map to a file ... then all you need to do is A env shader, where the file you use as cube map is that one.. so its refreshed.. the shader name I have is reflections, but you assig it to the player or something like that .. action player1 then you must use orbital cam , to check the effect..

Last edited by Unknot; 01/02/05 00:34.
Re: Real DX9 Reflection [Re: MMike] #37761
01/02/05 12:48
01/02/05 12:48
Joined: Oct 2003
Posts: 4,131
M
Matt_Aufderheide Offline
Expert
Matt_Aufderheide  Offline
Expert
M

Joined: Oct 2003
Posts: 4,131
I dont get this .. what is the screenshot() function? there isnt one here...

Page 5 of 6 1 2 3 4 5 6

Moderated by  Blink, Hummel, Superku 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1