Random WIP shots

If you have any questions on programming, this is the place to ask them, whether you're a newbie or an experienced programmer. Discussion on programming in general is also welcome. We will help you with programming homework, but we will not do your work for you! Any porting requests must be made in Developmental Ideas.
User avatar
PH3NOM
DC Developer
DC Developer
Posts: 574
Joined: Fri Jun 18, 2010 9:29 pm
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by PH3NOM » Thu Sep 04, 2014 7:17 pm

I have a guess about the bugs you experience on real hardware.

The PVR will freak out when you throw vertices at it that cross the Near Z Clipping Plane, and your video appears to demonstrate the fact.
I think that the column nearest to the screen may be crossing the Near Z Plane.

Try to enable my Near Z Clipping algorithm in the API:

Code: Select all

glEnable(GL_KOS_NEARZ_CLIPPING);
Jae686
Insane DCEmu
Insane DCEmu
Posts: 112
Joined: Sat Sep 22, 2007 9:43 pm
Location: Braga - Portugal
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by Jae686 » Fri Sep 05, 2014 2:02 pm

Good evening.

When

Code: Select all

glEnable(GL_KOS_NEARZ_CLIPPING);
on lxdream it simply shows a blank screen with a matching glclear() color, until the emulator crashes with

Code: Select all


--- Aborting with signal 11 ---
Could not attach to process.  If your uid matches the uid of the target
process, check the setting of /proc/sys/kernel/yama/ptrace_scope, or try
again as the root user.  For more details, see /etc/sysctl.d/10-ptrace.conf
ptrace: Operation not permitted.
No stack.
Aborted
jaerder@jaerder-G50V ~/development/Projectos Software/vidfdc/dreamcast $ 


I have not tested with real hardware (yet) though.
Jae686
Insane DCEmu
Insane DCEmu
Posts: 112
Joined: Sat Sep 22, 2007 9:43 pm
Location: Braga - Portugal
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by Jae686 » Sat Oct 25, 2014 12:30 pm

Image

Adding support for simple 2d Overlays. (useful to put graphics such as logos, etc on the screen).
User avatar
bogglez
Moderator
Moderator
Posts: 576
Joined: Sun Apr 20, 2014 9:45 am
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by bogglez » Sat Nov 01, 2014 6:41 am

Just added support for rendering polygons with compressed textures or colors to my libgl15.

Code is here: https://bitbucket.org/bogglez/libgl15/s ... ?at=master
libgl15_2014_11_01.png
Wiki & tutorials: http://dcemulation.org/?title=Development
Wiki feedback: viewtopic.php?f=29&t=103940
My libgl playground (not for production): https://bitbucket.org/bogglez/libgl15
My lxdream fork (with small fixes): https://bitbucket.org/bogglez/lxdream
User avatar
PH3NOM
DC Developer
DC Developer
Posts: 574
Joined: Fri Jun 18, 2010 9:29 pm
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by PH3NOM » Mon Nov 03, 2014 9:23 pm

bogglez-

Just to be clear, you can bind a VQ compressed texture using my Open GL API, all you need to do is specify the texture format when binding the texture.

After all, that is quite easy to do using KOS :wink:

But that reminds me, I do need to clean up the PVR texture memory allocation code, as right now I simply allocate 1/4 of the size in texture memory when the VQ flags are set, instead of actually figuring the exact size of the vq texture.
User avatar
bogglez
Moderator
Moderator
Posts: 576
Joined: Sun Apr 20, 2014 9:45 am
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by bogglez » Tue Nov 04, 2014 5:32 am

PH3NOM wrote:bogglez-

Just to be clear, you can bind a VQ compressed texture using my Open GL API, all you need to do is specify the texture format when binding the texture.

After all, that is quite easy to do using KOS :wink:

But that reminds me, I do need to clean up the PVR texture memory allocation code, as right now I simply allocate 1/4 of the size in texture memory when the VQ flags are set, instead of actually figuring the exact size of the vq texture.
I saw that you upload compressed textures using glTexImage, but I think it's not supposed to be done there. Shouldn't you use glCompressedTexImage anyway? You can use glTexImage if the internal format is compressed but the source format is not, I think (with the runtime conversion).
Wiki & tutorials: http://dcemulation.org/?title=Development
Wiki feedback: viewtopic.php?f=29&t=103940
My libgl playground (not for production): https://bitbucket.org/bogglez/libgl15
My lxdream fork (with small fixes): https://bitbucket.org/bogglez/lxdream
User avatar
PH3NOM
DC Developer
DC Developer
Posts: 574
Joined: Fri Jun 18, 2010 9:29 pm
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by PH3NOM » Sun Nov 23, 2014 10:24 pm

Image

Image
User avatar
bogglez
Moderator
Moderator
Posts: 576
Joined: Sun Apr 20, 2014 9:45 am
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by bogglez » Mon Nov 24, 2014 5:55 am

I never know what you're working on, Ph3nom.. saw the movie player. now this.. lol
Wiki & tutorials: http://dcemulation.org/?title=Development
Wiki feedback: viewtopic.php?f=29&t=103940
My libgl playground (not for production): https://bitbucket.org/bogglez/libgl15
My lxdream fork (with small fixes): https://bitbucket.org/bogglez/lxdream
User avatar
PH3NOM
DC Developer
DC Developer
Posts: 574
Joined: Fri Jun 18, 2010 9:29 pm
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by PH3NOM » Thu Dec 04, 2014 9:19 pm

This is actually my final project for the semester for my CS course.

Written from scratch using Java, the main focus has been optimizing collision detection.

The collision objects are added to a sorted list, kept sorted from frame to frame.
This exploits Temporal Coherencehttp://en.wikipedia.org/wiki/Collision_ ... _coherence in the fact that most objects do not move a great deal from each frame to the next, so it is easy to keep a list sorted when adding or removing objects.
I use a Binary Search to effectively Sweep And Prune all objects that can not collide with the object in question, before applying an Axis Aligned Bounding Box collision algorithm.

Image

Image
User avatar
Neoblast
DC Developer
DC Developer
Posts: 312
Joined: Sat Dec 01, 2007 8:51 am
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by Neoblast » Fri Dec 05, 2014 3:35 pm

any chance of a dreamcast port maybe? :P
User avatar
PH3NOM
DC Developer
DC Developer
Posts: 574
Joined: Fri Jun 18, 2010 9:29 pm
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by PH3NOM » Mon Dec 15, 2014 10:40 pm

Perhaps... :o
The focus of my project was advanced sorting and searching algorithms, for which I received full credit.

As for DC, I have still been working on getting a decent video player up and running...

Image
User avatar
PH3NOM
DC Developer
DC Developer
Posts: 574
Joined: Fri Jun 18, 2010 9:29 pm
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by PH3NOM » Sun Dec 21, 2014 10:13 pm

Now getting back to Quake 3 BSP rendering on DC.

This map uses a lot of textures, so for a quick fix the textures resolution have been reduced by 1/2 to fit in available texture memory.
A better solution would be to compress into VQ instead of reducing resolution.

Image

Image

Image
User avatar
MisterDave
DCEmu Freak
DCEmu Freak
Posts: 58
Joined: Mon Apr 08, 2013 1:16 pm
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by MisterDave » Sat Jan 09, 2016 2:50 pm

A couple of new videos of where I am with my engine rewrite:

User avatar
bogglez
Moderator
Moderator
Posts: 576
Joined: Sun Apr 20, 2014 9:45 am
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by bogglez » Sat Jan 09, 2016 4:52 pm

MisterDave, you should check out the World of Warcraft level file format. It provides simple tesselation but also keeps silhouettes consistent (your algorithm produces noticeable gaps).
Wiki & tutorials: http://dcemulation.org/?title=Development
Wiki feedback: viewtopic.php?f=29&t=103940
My libgl playground (not for production): https://bitbucket.org/bogglez/libgl15
My lxdream fork (with small fixes): https://bitbucket.org/bogglez/lxdream
User avatar
MisterDave
DCEmu Freak
DCEmu Freak
Posts: 58
Joined: Mon Apr 08, 2013 1:16 pm
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by MisterDave » Tue Jan 12, 2016 6:44 am

Thanks for the link Bogglez. The gaps in my terrain are quite ugly when the tesselation changes coarseness and are really something that should be next on my development agenda. I've fixed the texture blending issue since I posted the last video, so hopefully the next one will look a lot better with both these fixes.
User avatar
bogglez
Moderator
Moderator
Posts: 576
Joined: Sun Apr 20, 2014 9:45 am
Has liked: 0
Been liked: 0

Re: Random WIP shots

Post by bogglez » Tue Aug 23, 2016 12:54 pm

Wrote a simple raytraced screensaver from scratch (no KOS). I used it for benchmarking purposes. It will calculate a new frame every once in a while, rotating about the scene.
raytracer.png

You can try it in an emulator with this file:
raytrace.zip
(9.08 KiB) Downloaded 59 times
Wiki & tutorials: http://dcemulation.org/?title=Development
Wiki feedback: viewtopic.php?f=29&t=103940
My libgl playground (not for production): https://bitbucket.org/bogglez/libgl15
My lxdream fork (with small fixes): https://bitbucket.org/bogglez/lxdream
Post Reply