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
2 registered members (AndrewAMD, rki), 390 guests, and 0 spiders.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Everything clipped after a while. my.eflags&CLIPPED gets set #421167
04/12/13 12:03
04/12/13 12:03
Joined: Jun 2004
Posts: 655
to your left
BoH_Havoc Offline OP
User
BoH_Havoc  Offline OP
User

Joined: Jun 2004
Posts: 655
to your left
Hi,

we have a strange problem in our game. After a while, EVERYTHING (except skyboxes) is being clipped away. We checked for my.eflags&CLIPPED and can confirm that this flag is set when the bug occurs. Also when looking in a specific direction, the clipped entities will reappear, but only as long as you look in said specific direction.

Any ideas whats going on here?


Shade-C EVO Lite-C Shader Framework
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: BoH_Havoc] #421189
04/12/13 20:04
04/12/13 20:04
Joined: Oct 2004
Posts: 900
Lgh
rojart Offline
User
rojart  Offline
User

Joined: Oct 2004
Posts: 900
Lgh
Hi,

sometimes I use clipfactor higher than the default, maybe this will help.

Code:
my.clipfactor = 999999; // never clip this entity




Regards, Robert

Quote
Everything should be made as simple as possible, but not one bit simpler.
by Albert Einstein

PhysX Preview of Cloth, Fluid and Soft Body

A8.47.1P
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: rojart] #421214
04/13/13 18:05
04/13/13 18:05
Joined: Jun 2004
Posts: 655
to your left
BoH_Havoc Offline OP
User
BoH_Havoc  Offline OP
User

Joined: Jun 2004
Posts: 655
to your left
Well, we absolutely need clipping as the game might run way too slow on low end PCs if we don't use it. So setting clipfactor to a higher value won't be an option for us i guess.
Also, everything runs fine at first. It's only after some time that the whole scene gets clipped away.

As far as i know, only the main camera can change eflag&CLIPPED . Or are there any other ways to change that flag? Maybe we are doing something wrong by accident and turn on clipping for the whole scene because of a bug in our code...?

Last edited by BoH_Havoc; 04/13/13 18:06.

Shade-C EVO Lite-C Shader Framework
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: BoH_Havoc] #421216
04/13/13 18:35
04/13/13 18:35
Joined: Oct 2004
Posts: 900
Lgh
rojart Offline
User
rojart  Offline
User

Joined: Oct 2004
Posts: 900
Lgh
I had the same problem with my ragdoll example some time ago.
I noticed, when the camera was moved outside the global axis center XYZ=0, my ragdoll was clipped, therfore I used clipfactor.


Regards, Robert

Quote
Everything should be made as simple as possible, but not one bit simpler.
by Albert Einstein

PhysX Preview of Cloth, Fluid and Soft Body

A8.47.1P
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: rojart] #421218
04/13/13 19:22
04/13/13 19:22
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Quote:
Maybe we are doing something wrong by accident and turn on clipping for the whole scene because of a bug in our code...?

I think this sadly is the reason for your problem, i.e. you overwrite some memory or something like that. Every now and then there is a "bug" or small problem where a terrain or an object gets clipped too early, but not the whole scene and esp. only after quite some time.
I would ask myself some questions such as when did the problem appear the first time (/ was noticed the first time), what did you implement or change in the recent time and open some old versions (that you hopefully have) and observe if the problem appears there, too.


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: rojart] #421243
04/14/13 10:48
04/14/13 10:48
Joined: Jun 2004
Posts: 655
to your left
BoH_Havoc Offline OP
User
BoH_Havoc  Offline OP
User

Joined: Jun 2004
Posts: 655
to your left
Quote:
I had the same problem with my ragdoll example some time ago.


Were you using Shade-C in that example by an chance? If so, that would helps us in narrowing down the error source. If you were using Shade-C, could you try removing it from the example and see if the bug still appears?

Quote:
i.e. you overwrite some memory or something like that


That's an option we also thought about but as there's lots and lots of code to go through we hoped there might be another (simpler) reason for this behaviour. Oh well... frown

Oh and happy birthday! laugh


Shade-C EVO Lite-C Shader Framework
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: BoH_Havoc] #421274
04/14/13 14:15
04/14/13 14:15
Joined: Oct 2004
Posts: 900
Lgh
rojart Offline
User
rojart  Offline
User

Joined: Oct 2004
Posts: 900
Lgh
As I remember was without Shade-C.

I tested with the last beta 8.42.0, but I can't reproduce the issue any more, maybe was fixed.

ps
Happy Birthday Superku!


Regards, Robert

Quote
Everything should be made as simple as possible, but not one bit simpler.
by Albert Einstein

PhysX Preview of Cloth, Fluid and Soft Body

A8.47.1P
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: rojart] #421282
04/14/13 17:55
04/14/13 17:55
Joined: Mar 2011
Posts: 3,150
Budapest
sivan Offline
Expert
sivan  Offline
Expert

Joined: Mar 2011
Posts: 3,150
Budapest
last week, my shade-c 0.90 water disappeared when I moved camera to its edge, depending on camera angle (tile<45), but only in my editor where I used only water related things (everything else removed), and only in case of one level, when normal-map was the 1st skin. when I put there a texture and used bmap_to_normals, and 2nd and 3rd skins were added also by script, it was fine. I don't really understand it, but I hope it might help a bit...


Free world editor for 3D Gamestudio: MapBuilder Editor
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: sivan] #421286
04/14/13 21:40
04/14/13 21:40
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Thanks guys!

Havoc, have you tried to run an old(er) version yet?


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: Everything clipped after a while. my.eflags&CLIPPED gets set [Re: Superku] #422031
04/30/13 17:00
04/30/13 17:00
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline
Expert
Germanunkol  Offline
Expert

Joined: Jun 2006
Posts: 2,640
Earth
I really dislike the way we're having to debug this. Why is it always so much trial and error?
There's an eflag being set... why can't we work backwards from there? What functions can set eflags? And why?
Is there any material callback or return that will set the eflag for an entity?

Wolfgang, do you have time on Wednesday?
Then we could give it a test run with all clipping disabled.


~"I never let school interfere with my education"~
-Mark Twain

Moderated by  HeelX, Spirit 

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