Gamestudio Links
Zorro Links
Newest Posts
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
Data from CSV not parsed correctly
by EternallyCurious. 04/20/24 21:39
M1 Oversampling
by 11honza11. 04/20/24 20:57
Scripts not found
by juergen_wue. 04/20/24 18:51
zorro 64bit command line support
by 7th_zorro. 04/20/24 10:06
StartWeek not working as it should
by jcl. 04/20/24 08:38
folder management functions
by VoroneTZ. 04/17/24 06:52
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 177 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
shader files using #include #458811
03/31/16 11:34
03/31/16 11:34
Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
Kartoffel Offline OP
Expert
Kartoffel  Offline OP
Expert

Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
Hey there,

I noticed that using #include in a shader file works fine until you compile your application.
Once compiled the engine just crashes as soon as the shader gets compiled (i.e. when an object using the shader gets visible).

It's not a big deal since I'm going to join my shader files and compile them to .fxo-files when I'm done, but you might wanna look into this.


POTATO-MAN saves the day! - Random
Re: shader files using #include [Re: Kartoffel] #458812
03/31/16 11:42
03/31/16 11:42
Joined: Sep 2003
Posts: 9,859
F
FBL Offline
Senior Expert
FBL  Offline
Senior Expert
F

Joined: Sep 2003
Posts: 9,859
Hm... I think I once compiled some of the default shaders (they have several #include statements) to fxo without problems.
Also I regularly used the default shaders in compiled, published and also resourced projects without any problem noticed.

Are you including with <> or with ""?

Re: shader files using #include [Re: FBL] #458813
03/31/16 11:48
03/31/16 11:48
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
What to you mean with "compile your application"? Compiling the shader, or publishing the application?

When you publish your game, you must manually include all files that are not automatically included. That's also all shader files that you need.

Re: shader files using #include [Re: jcl] #458816
03/31/16 13:43
03/31/16 13:43
Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
Kartoffel Offline OP
Expert
Kartoffel  Offline OP
Expert

Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
Sorry, should have explained it a bit more precisely.

The crash is caused by uncompiled shaders (.fx-files) in a published application.

I've put all the required files are in the published folder.


POTATO-MAN saves the day! - Random
Re: shader files using #include [Re: Kartoffel] #458818
03/31/16 13:54
03/31/16 13:54
Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
Kartoffel Offline OP
Expert
Kartoffel  Offline OP
Expert

Joined: Jun 2009
Posts: 2,210
Bavaria, Germany
here's a small example: crash.zip


POTATO-MAN saves the day! - Random
Re: shader files using #include [Re: Kartoffel] #458819
03/31/16 14:06
03/31/16 14:06
Joined: Jul 2010
Posts: 283
Germany
J
jenGs Offline
Member
jenGs  Offline
Member
J

Joined: Jul 2010
Posts: 283
Germany
I can confirm this. Had the same problem in a recent project.

Re: shader files using #include [Re: jenGs] #458827
04/01/16 12:29
04/01/16 12:29
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
Thanks for the example! I can confirm this problem - shader includes only work when they are compiled. We'll look into it in detail. Shader includes will be probably fully supported in the next update.

As a workaround, either compile the shader, or insert the code instead of an include.

Re: shader files using #include [Re: jcl] #461475
08/08/16 07:15
08/08/16 07:15
Joined: Mar 2011
Posts: 3,150
Budapest
sivan Offline
Expert
sivan  Offline
Expert

Joined: Mar 2011
Posts: 3,150
Budapest
Hi,
is there a date when it would be fixed?
Approx. 10-11 months ago I finished a new update for my MapBuilder (billboard model lod, some lighting fixes etc.), what I have wanted to release together with a new GitHub repository, but using no incudes in shaders or compiling them are no good in my case, I'm afraid it would break the workflow...


Free world editor for 3D Gamestudio: MapBuilder Editor
Re: shader files using #include [Re: sivan] #461478
08/08/16 07:51
08/08/16 07:51
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
I have no ETA for the next update yet.

Re: shader files using #include [Re: jcl] #461483
08/08/16 08:05
08/08/16 08:05
Joined: Mar 2011
Posts: 3,150
Budapest
sivan Offline
Expert
sivan  Offline
Expert

Joined: Mar 2011
Posts: 3,150
Budapest
then is there a link to the previous engine version A8.46.2? I would move back and ask my users to do the same. (I have the installer on my disk but it would be better to use an official link)


Free world editor for 3D Gamestudio: MapBuilder Editor
Page 1 of 2 1 2

Moderated by  jcl, Nems, Spirit, Tobias 

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