RenderMonkey texture problem

Started by
1 comment, last by stroma 18 years, 11 months ago
hi guys, i am developing my shaders with rendermonkey. i was using the example files and they are working well. but i started a project from start and add a ogl effect group to it. when i want to use any texture (code is correct,i test it @my engine) it says: "RENDERING ERROR(s): Invalid sampler named 'myTexture' in program object for pass 'Pass 0'" i think i am missing something with "Stream Mapping". what is the problem do you think, how can i solve this? what stream mapping do i have to use(i use the same as the examples, just simple texturing.) thank you..
+-+-+-+-+-STR
Advertisement
I use RenderMonkey for my DX shaders, but it's probably similar for OpenGL. For texturing, after you add "myTexture" to the effect (as you've done), you have to add a texture reference to your shader pass. Right click on your pass and click "Add Texture Object". Then you'll see "Texture0" appear under your shader pass. Expand it, and right click on the tab underneath and the top option is "Reference Node". Simply reference the texture you've loaded up and that texture will now be reference in the first texture sampler (register s0 in the case of Direct3D).

Hopefully this makes some sort of sense to you.
thank you..
+-+-+-+-+-STR

This topic is closed to new replies.

Advertisement