crownengine / crown Goto Github PK
View Code? Open in Web Editor NEWThe flexible game engine.
Home Page: https://www.crownengine.org
License: Other
The flexible game engine.
Home Page: https://www.crownengine.org
License: Other
Arch Linux 4.3.3, GCC 5.3.0
[rob@Archie][~/dev/crown/build/linux64/bin]% gdb ./crown-debug-64
<snip gdb boot prelude>
Reading symbols from ./crown-debug-64...done.
(gdb) r
Starting program: /home/rob/dev/crown/build/linux64/bin/crown-debug-64
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
[New Thread 0x7ffff33f0700 (LWP 31049)]
Initializing Crown Engine 0.1.13...
Assertion failed: s != NULL
s must be not null
In: ../../../src/core/strings/dynamic_string.h:85
Stacktrace:
[1] /home/rob/dev/crown/build/linux64/bin/crown-debug-64() [0x4f7b59]
[2] /home/rob/dev/crown/build/linux64/bin/crown-debug-64: (crown::error::abort(char const*, int, char const*, ...)
[3] /home/rob/dev/crown/build/linux64/bin/crown-debug-64: (crown::DynamicString::DynamicString(char const*, crown::Allocator&))+0x4c in /home/rob/dev/crown/build/projects/linux/../../../src/core/strings/dynamic_string.h:86
[4] /home/rob/dev/crown/build/linux64/bin/crown-debug-64: (crown::DiskFilesystem::DiskFilesystem(char const*))+0x47 in /home/rob/dev/crown/build/projects/linux/../../../src/core/filesystem/disk_filesystem.cpp:29
[5] /home/rob/dev/crown/build/linux64/bin/crown-debug-64: (crown::Device::init())+0x82 in /home/rob/dev/crown/build/projects/linux/../../../src/device.cpp:84 (discriminator 1)
[6] /home/rob/dev/crown/build/linux64/bin/crown-debug-64: (crown::init(crown::DeviceOptions const&))+0x7b in /home/rob/dev/crown/build/projects/linux/../../../src/device.cpp:474 (discriminator 4)
[7] /home/rob/dev/crown/build/linux64/bin/crown-debug-64: (crown::func(void*))+0x23 in /home/rob/dev/crown/build/projects/linux/../../../src/main/main_linux.cpp:342
[8] /home/rob/dev/crown/build/linux64/bin/crown-debug-64: (crown::Thread::run())+0x36 in /home/rob/dev/crown/build/projects/linux/../../../src/core/thread/thread.h:112
[9] /home/rob/dev/crown/build/linux64/bin/crown-debug-64: (crown::Thread::thread_proc(void*))+0x18 in /home/rob/dev/crown/build/projects/linux/../../../src/core/thread/thread.h:118
[10] /usr/lib/libpthread.so.0: ()+0x74a4 in ??:0
[11] /usr/lib/libc.so.6: (clone)+0x6d in ??:0
[Thread 0x7ffff33f0700 (LWP 31049) exited]
[Inferior 1 (process 31045) exited with code 01]
The current implementation of ALRenderer and SLESRenderer is unable to play multiple instances of the same sound.
E.g.
Playing two times the sound "boom", actually stops the current playing sound ("boom") and starts it again.
Arch Linux 4.3.3, GCC 5.3.0
Log:
[rob@Archie][~/dev/crown]% GENIE=`which genie` make linux-release64 -j128
/usr/bin/genie --file=genie/genie.lua --with-luajit --with-openal --with-bullet --with-tools --compiler=linux-gcc gmake
Building configurations...
Running action 'gmake'...
Generating build/projects/linux/Makefile...
Generating build/projects/linux/bgfx.make...
Generating build/projects/linux/shaderc.make...
Generating build/projects/linux/openal.make...
Generating build/projects/linux/bullet.make...
Generating build/projects/linux/crown.make...
Done.
make -R -C build/projects/linux config=release64
make[1]: warning: jobserver unavailable: using -j1. Add '+' to parent make rule.
make[1]: Entering directory '/home/rob/dev/crown/build/projects/linux'
==== Building bgfx (release64) ====
==== Building shaderc (release64) ====
==== Building openal (release64) ====
==== Building bullet (release64) ====
==== Building crown (release64) ====
sound_world_al.cpp
../../../src/audio/sound_world_al.cpp:11:22: fatal error: id_array.h: No such file or directory
compilation terminated.
crown.make:1039: recipe for target '../../linux64/obj/x64/release/crown/src/audio/sound_world_al.o' failed
make[2]: *** [../../linux64/obj/x64/release/crown/src/audio/sound_world_al.o] Error 1
Makefile:32: recipe for target 'crown' failed
make[1]: *** [crown] Error 2
make[1]: Leaving directory '/home/rob/dev/crown/build/projects/linux'
makefile:38: recipe for target 'linux-release64' failed
make: *** [linux-release64] Error 2
It looks like a file is entirely missing from the repo.
Mainly in order to properly support Android's asset folder.
goals:
Hello :)
I cannot seem to get crown to link to Physx...
Linking
/usr/bin/ld: cannot find -lLowLevelCloth
/usr/bin/ld: cannot find -lPhysX3
/usr/bin/ld: cannot find -lPhysX3Common
/usr/bin/ld: cannot find -lLowLevel
/usr/bin/ld: cannot find -lPhysX3CharacterKinematic
/usr/bin/ld: cannot find -lPhysX3Cooking
/usr/bin/ld: cannot find -lPvdRuntime
/usr/bin/ld: cannot find -lSceneQuery
/usr/bin/ld: cannot find -lSimulationController
Things I have done...
PHYSX_SDK_LINUX
to the location I unpacked Physx.$PHYSX_SDK_LINUX/Bin/linux64
directory to /etc/ld.conf.d/physx.confldconfig -v
checks out with ... libPhysX3CommonCHECKED_x64.so -> libPhysX3CommonCHECKED_x64.so
libPhysX3PROFILE_x64.so -> libPhysX3PROFILE_x64.so
libPhysX3CookingPROFILE_x64.so -> libPhysX3CookingPROFILE_x64.so
libPhysX3CookingDEBUG_x64.so -> libPhysX3CookingDEBUG_x64.so
libPhysX3CommonDEBUG_x64.so -> libPhysX3CommonDEBUG_x64.so
libPhysX3_x64.so -> libPhysX3_x64.so
libPhysX3CharacterKinematicDEBUG_x64.so -> libPhysX3CharacterKinematicDEBUG_x64.so
libCgGL.so -> libCgGL.so
libPhysX3GpuPROFILE_x64.so -> libPhysX3GpuPROFILE_x64.so
libPhysX3GpuDEBUG_x64.so -> libPhysX3GpuDEBUG_x64.so
libPhysX3Gpu_x64.so -> libPhysX3Gpu_x64.so
libPhysX3Cooking_x64.so -> libPhysX3Cooking_x64.so
libPhysX3CharacterKinematicCHECKED_x64.so -> libPhysX3CharacterKinematicCHECKED_x64.so
libPhysX3GpuCHECKED_x64.so -> libPhysX3GpuCHECKED_x64.so
libPhysX3CharacterKinematicPROFILE_x64.so -> libPhysX3CharacterKinematicPROFILE_x64.so
libPhysX3CookingCHECKED_x64.so -> libPhysX3CookingCHECKED_x64.so
libPhysX3Common_x64.so -> libPhysX3Common_x64.so
libPhysX3CommonPROFILE_x64.so -> libPhysX3CommonPROFILE_x64.so
libPhysX3DEBUG_x64.so -> libPhysX3DEBUG_x64.so
libCg.so -> libCg.so
libPhysX3CHECKED_x64.so -> libPhysX3CHECKED_x64.so
libPhysX3CharacterKinematic_x64.so -> libPhysX3CharacterKinematic_x64.so
Lib/linux64/*.a
static libs to /usr/local/lib
So I am a little confused as to why the linked cannot find the library. Some of these names do not marry up at all such as -lLowLevel
... But my C++ is a bit rusty so this could easily be the problem.
Cheers.
I'm probably missing something obvious - but I'd like to use a time uniform in one of my shaders and I'd like to update this uniform each frame with the frame's delta.
I noticed that in some of the examples, inside various material.json files, uniforms are defined thusly -
"uniforms" : {
"u_color" : { "type" : "vector3", "value" : [1, 1, 1] },
"u_time" : { "type" : "float", "value" : 0.0 }
}
So I figured inside my fragment shader I'd be able to do something like -
SAMPLER2D(u_albedo, 0);
uniform vec3 u_color;
uniform float u_time;
void main()
{
gl_FragColor = texture2D(u_albedo, v_texcoord0) * vec4(u_color, (sin(u_time * 4.0f) + 1.0f));
}
However I don't believe u_time is actually being updated after it is initialized. I'm guessing I'm responsible for doing this, but is there any current interface to do so from lua?
Thanks as usual,
-Zach
Currently, Crown Engine uses a mixed underscore/camelcase naming convention due to a switch in code-style guidelines. We need to fix all of the old function names to the new convention prior to the 0.1.0 milestone.
Lua is the preferred way of writing games in Crown at the time being. Improving the quality of the bindings library has to be a triple-A priority for us.
In debug/development builds we want a way to generate Lua errors when the user passes parameters with the wrong type to functions. We also want to assert() in case of dead objects.
Hello,
I'm the guy from twitter who is going to submit the PR for the osx build support this evening, but I have a quick question - what's the most efficient way to structure the various resources for rendering tiles.
I was hoping to do like one unit per player of tiles with a bunch of different sprites, kind of utilizing the unit as a tilemap. I don't think this is going to work however - because I can't find a way to position individual renderables inside a unit.
Am I stuck doing one unit per tile I want to render? I was hoping I'd be able to do something like one sprite with a bunch of individual frames and then one unit which referenced each of those frames as a renderable, just to cut down on the number of json files.
I could alternatively write something in lua to programmatically create all these resources, but I figured I'd ask first in case there is a way to do it with the default resource parsing.
Thanks!
-Zach
Although most of the public APIs are already documented, some of them needs additional work while others could need a total rewrite.
http://www.drdobbs.com/cpp/how-non-member-functions-improve-encapsu/184401197
The above can be further pushed by implementing every function (where possible) as non-member.
JSONPArser is an in-situ parser. It stores sensible pointer to data.
The problem is that it also stores strings from json file, that is a dom-like practice and very expansive in terms of memory usage.
One of the biggest issues with the bitsquid engine is that they have their content-compilers built into the engine instead of having them separated. This causes issues such as not being able to run different compiler chains at the same time since the compiler server hogs one port that is predefined for everything to use.
Instead a separated compiler-chain would be a much more viable solution. Either by linking in libraries from the engine and having separated compiler layers above that or simply by using a common data library for file serialization.
So I don't think there's a lua binding to grab the current system time (please correct me if I'm mistaken), right now I think there is only the binding for grabbing the last frame's delta time - but I think this would be a nice to have.
I can add the binding if you think the enhancement is worth the effort. It would give me more insight into how the whole lua interop works.
Thanks,
Tools:
-resource-browser
-console
-toolchain
eglSwapBuffers:949 error 300d (EGL_BAD_SURFACE)
prepare core's classes for lua bindings with FFI (luajit).
e.g: https://gist.github.com/gaspard/1087380
The idea is to build a virtual console system which communicates with an instance of the engine running on localhost or remote devices via TCP/IP, using a custom protocol based on JSON.
compilation terminated.
make[2]: *** [../../linux64/obj/x64/development/openal/third/openal/Alc/backends/alsa.o] Error 1
make[1]: *** [openal] Error 2
make[1]: Leaving directory `/home/vlad/crown/.build/projects/linux'
make: *** [linux-development64] Error 2
using make linux-development64 or linux-debug64
I have a scene where I'm adding one unit which uses one material that includes the standard sprite shader. The unit is created at vertex 0,0,0. I then add another unit which uses a different material and different shader, but the internals of the fragment shader don't seem to matter here - it can be exactly the same as the basic sprite shader and the problem still occurs.
This second unit appears fine, but as soon as I start adding more units on top which use the same shader as the first unit I created, the second unit starts to show through the third. Here's a screenshot of the problem :
The gradient is the first unit I was talking about and it's using the standard sprite shader included in the example projects you've shared with me. The second unit is the star layer and it's using a different shader - and again I can compile this shader with the same code as the other sprite shader and the problem still occurs. The third group of units I add are the tiles that make up the bridge thing in the foreground. These use the same shader as the gradient background unit.
I doubt this is so much a problem as it is my inexperience with controlling draw order / depth when it comes to playing with shaders. Any insight into how this all works?
Thanks!
-Zach
Wondering if it's possible to achieve multiple render passes with the current lua interface. I believe you stated earlier each unit right now could have just one material or something to that effect. I'm trying to implement bloom without doing it inside of a fragment shader if possible. I'm not sure if this is already possible or whether it's on the roadmap / needs to be worked on.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.