Search found 26 matches

by no_response
Thu Sep 30, 2010 10:07 pm
Forum: Beginners Help
Topic: key press
Replies: 7
Views: 1037

i would do

Code: Select all

bool keypressed = receiver.IsKeyDown(KEY_KEY_W);
...


while(device->run()){
...
...

if(!keypressed){
if(receiver.IsKeyDown(KEY_KEY_W)){ print("TEST");}
keypressed = 1;
}
else{
keypressed = receiver.IsKeyDown(KEY_KEY_W);
} 

...
...
}
lol...
by no_response
Thu Sep 30, 2010 9:57 pm
Forum: Beginners Help
Topic: Window/Device position
Replies: 4
Views: 682

well, if you're writing for windows, you can use the win api : MoveWindow(windowhandle, pixelsX, pixelsY, windowsizeX, windowsizeY, redraw?); you can search MSDN for the function. the windowhandle can be obtained the following way (the example is for OpenGL, else check the Irrlicht reference) HWND w...
by no_response
Thu Sep 30, 2010 9:40 pm
Forum: Beginners Help
Topic: Alt + tab issues (minimizing?)
Replies: 3
Views: 493

using win api

Code: Select all

ShowWindow(GetForegroundWindow(), SW_MINIMIZE);
if you need to make it minimize on alt+tab specificaly, just play around with

Code: Select all

GetAsyncKeyState() // http://msdn.microsoft.com/en-us/library/ms646293(VS.85).aspx
by no_response
Wed Sep 29, 2010 6:33 pm
Forum: Beginners Help
Topic: Transparent Button Image
Replies: 4
Views: 1168

also apply

Code: Select all

button->setDrawBorder(0);
by no_response
Wed Sep 29, 2010 6:23 pm
Forum: Beginners Help
Topic: Frame Rate Lock
Replies: 6
Views: 787

what I do is... unsigned int FPS=0; wchar_t* FPSwc = (wchar_t*) calloc(10, sizeof(wchar_t)); unsigned short int time=0; unsigned short int dividor=2; and in the main loop if (driver->getFPS()!=FPS){ FPS = driver->getFPS(); if((double)FPS/(double)desiredfps > 1.5 &&dividor>=4) dividor-=2; els...
by no_response
Wed Sep 29, 2010 8:32 am
Forum: Beginners Help
Topic: How to rotate a 2D sprite i.e texture using irrlicht?
Replies: 1
Views: 361

this may be what you're looking for
by no_response
Mon Sep 27, 2010 9:34 am
Forum: Advanced Help
Topic: Copy ITexture?
Replies: 6
Views: 849

first, thanks for the help. the batch image rendering would be useful if the images were treated as a scene nodes (like when moving the camera, they get out of the view), yet it cant seem to come in handy in my case. The text clipping, however, may be useful, but I can't get it to work. How exactly ...
by no_response
Sun Sep 26, 2010 10:31 pm
Forum: Advanced Help
Topic: Copy ITexture?
Replies: 6
Views: 849

I'm writing a file explorer. The next lines may seem a dumb way of doing things, yet I am open for better ideas. Once a user wants to open a folder, a function stores all the content's names and types (folder, device, file....) in an STL list<>. Next up another function places rectangular scene node...
by no_response
Sun Sep 26, 2010 6:22 pm
Forum: Beginners Help
Topic: Problem with relative paths
Replies: 4
Views: 302

first check where the compiler is set to place the .exe file.
also check the run directory.

<for example, try running your program from the .exe itself, not from the IDE>

does it show any messages like 'unable to open texture : .......'?

post your code.
by no_response
Sun Sep 26, 2010 5:43 pm
Forum: Beginners Help
Topic: Problem with relative paths
Replies: 4
Views: 302

how about

Code: Select all

VideoDriver->getTexture("./Textures/DetailMap.jpg"));
by no_response
Sun Sep 26, 2010 11:38 am
Forum: Beginners Help
Topic: How do I remove GUI button?
Replies: 8
Views: 1099

do like

Code: Select all

IGUIEnvironment* env = device->getGUIEnvironment();

IGUIButton* but = env->addButton(rect<s32>(10,240,110,240 + 32), 0, GUI_ID_START_BUTTON,L"Start", L"begin"); 
and when you want to remove the button, do

Code: Select all

but->remove()
by no_response
Sun Sep 26, 2010 9:58 am
Forum: Advanced Help
Topic: Copy ITexture?
Replies: 6
Views: 849

Copy ITexture?

hi again, I need to copy ITextures. I need a way that is faster than creating a new RTT texture using addRenderTargetTexture. Creating ~500 RTTs takes about 3-4 seconds on my PC (which is old, I know) and this is unacceptable for my app. So instead of creating new RTTs, I decided to have 1 RTT, rend...
by no_response
Wed Sep 15, 2010 10:28 pm
Forum: Bug reports
Topic: [fixed]Rendering text on a texture?
Replies: 14
Views: 3511

here it is #include <Irrlicht.h> using namespace std; using namespace irr; using namespace core; using namespace scene; using namespace video; using namespace io; using namespace gui; bool keys[irr::KEY_KEY_CODES_COUNT]; class MyEventReceiver : public IEventReceiver { public: bool OnEvent(const SEve...
by no_response
Wed Sep 15, 2010 6:16 pm
Forum: Bug reports
Topic: [fixed]Rendering text on a texture?
Replies: 14
Views: 3511

bump. bug also occurr with the default font. only while the RT texture is (or partialy is) on the screen. tried disabling orthogonal camera, didn't work. tried several other things, yet only disabling the cube with the RT texture on it solves the problem. I'm beggining to think that this is some kin...
by no_response
Tue Sep 14, 2010 3:21 pm
Forum: Bug reports
Topic: [fixed]Rendering text on a texture?
Replies: 14
Views: 3511

full code (with all the misc functions and stuff) : [edit - navigation fixed]

Code: Select all

removed, read below