Skocz do zawartości

Więcej shaderów :D


patry

Rekomendowane odpowiedzi

Witam, wiem, że żeby odblokować dodatkowe shadery w mentalu trzeba zmodyfikować plik lume.mi (tzn. usunąć napis "hidden" i przecinek przed nim) ale takim sposobem odblokowałem tylko 4 shadery.

Czy to nie za mało?? Gdzieśkidyświdziałem, że po takiej modyfikacji można mieć nawet 20 nowych shaderków.

Co robić?? (więcje słów "hidden" już w tym pliku nie ma i dlatego nie wiem jka odblokować więcej tych shaderków)

Odnośnik do komentarza
Udostępnij na innych stronach

  • Odpowiedzi 6
  • Created
  • Ostatniej odpowiedzi

Top Posters In This Topic

Top Posters In This Topic

Base .mi tam jest tego więcej a w mr 3.5 to jest dopiero jazda.

 

Piotrek-

Co do pisania to czy do metala jest potszebny jakiś kompilator czy inny tolbox.

 

{ wcale się nie kompromituje}

 

{ps: wiem co to znaczy pisać shadery w HSL ASHIL CG etc.}

Odnośnik do komentarza
Udostępnij na innych stronach

There are external shader libraries that support compatibility with Alias, Autodesk 3ds max, Dassault Systèmes CATIA, SOFTIMAGE, SolidWorks, Wavefront, and others. Much of the power of mental ray relies on the possibility to write custom shaders and link them dynamically to mental ray at runtime. Custom shaders are written in C or C++, using the full language and library support available in these languages.

 

Here are the steps necessary to create a new shader:

 

Write a .mi declaration for the shader, providing the shader name, return type, shader parameter names and types, and the version to mental ray.

 

Write a C shader parameter data structure that agrees exactly with the .mi parameter declaration. (The mkmishader utility can do this translation.)

 

Write the shader function in C or C++, using the correct signature. The shader computes a result from its shader parameters and the state, and by calling shader interface functions provided by mental ray.

 

Write a version shader (same name with _version appended to the name) that returns a version number that matches the version number in the .mi declaration.

 

If required, write initialization and exit shaders (same name as the shader with _init and _exit appended, respectively).

 

Compile and link the shader, and create a shared shader library (DSO or DLL). This step can be omitted but DSO/DLLs are easiest to use and much faster to link than objects or sources. Libraries must be installed on all machines on the net that are used as masters or network rendering slaves.

 

Use a $include statement in the scene .mi file to load the .mi declaration and a link (or code or $code) statement to load the shader DSO/DLL (or source code).

 

cytat z helpa

Odnośnik do komentarza
Udostępnij na innych stronach

Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto

Jedynie zarejestrowani użytkownicy mogą komentować zawartość tej strony.

Zarejestruj nowe konto

Załóż nowe konto. To bardzo proste!

Zarejestruj się

Zaloguj się

Posiadasz już konto? Zaloguj się poniżej.

Zaloguj się



×
×
  • Dodaj nową pozycję...

Powiadomienie o plikach cookie

Wykorzystujemy cookies. Przeczytaj więcej Polityka prywatności