Search found 167 matches

by nespa
Fri Mar 25, 2011 9:51 pm
Forum: Beginners Help
Topic: Strange behaviour when static sphere is lighted dynamically
Replies: 7
Views: 592

the scale is too small, I think
by nespa
Fri Mar 25, 2011 7:55 pm
Forum: Beginners Help
Topic: Move in the direction your node is pointing? [SOLVED]
Replies: 9
Views: 1230

take here :

Code: Select all

ISceneNode* Node;
vector3df move(X,Y,Z);
matrix4 matrix;

matrix = Node->getRelativeTransformation();
matrix.transformVect(move);
Node->setPosition(move);
where X,Y,Z are the movements each frame relative to local axis;
by nespa
Tue Mar 22, 2011 6:30 pm
Forum: Code Snippets
Topic: terrain height painting
Replies: 28
Views: 20155

this is a part of my wrapper code; don't care about the rest, focus to your need: DLL_EXPORT s32 DLL_APIENTRY GetXPoSArrow(ITerrainSceneNode* terrain, ISceneNode* arrow, ITriangleSelector* terrainSelector, ICameraSceneNode* cam, s32 terrscaleXZ, s32 terrscaleY, s32 terrsize) { // move the arrow to t...
by nespa
Mon Mar 21, 2011 8:36 pm
Forum: Beginners Help
Topic: How to edit mesh vertices?
Replies: 7
Views: 1310

take a look at the topic :"Creating a custom heightmap" in the Beginners Help section (follow the link);
by nespa
Mon Mar 21, 2011 4:52 pm
Forum: Beginners Help
Topic: GLSL shader bug [solved]
Replies: 12
Views: 1896

here is working your shader; follows as I told you earlier and try more this: texture your cube: Geometrie->setMaterialTexture(0, driver->getTexture("../media/texture_name.ext")); see: class CShaderCallback : public irr::video::IShaderConstantSetCallBack { void OnSetConstants(irr::video::I...
by nespa
Mon Mar 21, 2011 3:39 pm
Forum: Beginners Help
Topic: GLSL shader bug [solved]
Replies: 12
Views: 1896

did you add a texture to your cube? try this shader to see it is working: vertex shader: void main() { gl_TexCoord[0] = gl_MultiTexCoord0; gl_Position = ftransform(); } fragment shader: uniform sampler2D tex; void main() { vec4 color = texture2D(tex,gl_TexCoord[0].st); gl_FragColor = color; } this i...
by nespa
Mon Mar 21, 2011 1:20 pm
Forum: Beginners Help
Topic: GLSL shader bug [solved]
Replies: 12
Views: 1896

take a look here: http://www.lighthouse3d.com/opengl/glsl/index.php?texture or here: http://www.lighthouse3d.com/tutorials/glsl-tutorial/ is for OpenGL 2.0 but for GLSL 1.2 try comment in your code: class CShaderCallback : public irr::video::IShaderConstantSetCallBack { void OnSetConstants(irr::vide...
by nespa
Sun Mar 20, 2011 11:03 pm
Forum: Beginners Help
Topic: FPS camera using keys only
Replies: 6
Views: 574

right !

:)
by nespa
Sun Mar 20, 2011 7:42 pm
Forum: Beginners Help
Topic: FPS camera using keys only
Replies: 6
Views: 574

having 2 cameras is a practice in many editor enviroments
by nespa
Sun Mar 20, 2011 5:45 pm
Forum: Beginners Help
Topic: Creating a custom heightmap (?)
Replies: 8
Views: 2397

by nespa
Sun Mar 20, 2011 5:39 pm
Forum: Beginners Help
Topic: FPS camera using keys only
Replies: 6
Views: 574

make 2 cameras,

a fixed camera and a FPS camera;

switch from one to the other with Mouse_Right or a key;

here is an example where is used SPACE to commute between the 2 cameras; (edit mode and menu mode);

http://www.filefactory.com/file/ca16d77 ... latGUI.rar
by nespa
Sun Mar 20, 2011 5:31 pm
Forum: Beginners Help
Topic: collision with .irr nodes
Replies: 4
Views: 373

by nespa
Sat Mar 19, 2011 10:08 pm
Forum: Beginners Help
Topic: Clipping problem.
Replies: 8
Views: 457

are You working just with IMesh, not an IAnimatedMeshSceneNode?


Is drawn IMesh?
by nespa
Sat Mar 19, 2011 9:46 pm
Forum: Beginners Help
Topic: collision with .irr nodes
Replies: 4
Views: 373

this way : 1. create a triangle selector for the 1st node; 2. create a triangle selector for the 2nd node; 3. create a ray from 1st node to 2nd node and apply: getCollisionPoint(........); 4. calculate the distance and interpret with "if" see ISceneCollisionManager in include folder of the...
by nespa
Sat Mar 19, 2011 6:08 pm
Forum: Beginners Help
Topic: change rotation of a node
Replies: 2
Views: 269

-before of the main loop: 1. create the camera (take care at : camera->bindTargetAndRotation(true)); 2. create the character; 3. position your character at (0,0,0); 4. position the camera behind the character; 5. set the character as parent of the camera (camera->setParent(character); 6. position th...