Results 1 to 19 of 19

Thread: ClanLib 2.2 Preview Help Requested

  1. #1
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Talking ClanLib 2.2 Preview Help Requested

    Later this year, we will be releasing ClanLib 2.2.0

    ClanLib has a lack of active Linux developers. This makes is very difficult to check ClanLib works on all platforms / distros.

    Also there are numerous versions Microsoft Windows with various graphic cards. We need testers, to ensure the examples work.

    Since ClanLib 2.2 SVN is currently in a stable state (at the time of writing this message). Please help us by testing ClanLib 2.2.

    Below are links to the source code (Taken from SVN #4628)

    http://esoteric.clanlib.org/~rombust/ClanLib-2.2.0.tgz <--- linux line feeds, without Microsoft Windows themes
    http://esoteric.clanlib.org/~rombust/ClanLib-2.2.0.zip <--- windows line feeds, including Microsoft Windows themes

    Important: See UPDATE.txt (in the base directory)

    The known bugs and "would like" features are found in "TODO.txt" (in the base directory)
    Last edited by rombust; 05-28-2010 at 09:46 PM.

  2. #2
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    Updated to SVN 4696.

    The TODO.txt is now found at http://clanlib.org/wiki/TODO

    Linux running i386, you need to add the following to the example makefiles:

    CXXFLAGS += -msse2

    Ideally this could be set in the "pkg-config --cflags" ... Depending on the options CL_DISABLE_SSE2 define (that should also be in the pkg-config flags)
    Last edited by rombust; 06-30-2010 at 01:36 PM.

  3. #3
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    Updated to SVN 4720

    http://esoteric.clanlib.org/~rombust/ClanLib-2.2.0.tgz <--- linux line feeds, without Microsoft Windows themes
    http://esoteric.clanlib.org/~rombust/ClanLib-2.2.0.zip <--- windows line feeds, including Microsoft Windows themes

    It should now be complete

    Please test ASAP and post problems here before the release within a week

  4. #4

    Default

    debian/x86_64 compile errors

    __________________________________________________ _____________________________

    in Sources/CSSLayout/LayoutTree/css_layout_tree_node.cpp
    324 CL_String bullet(1, 8226);

    overflow in implicit constant conversion (8226 might be converted to int_64 ?
    what is the expected type of the second argument ?)

    __________________________________________________ _____________________________

    in Sources/Core/System/detect_cpu_ext.cpp

    36 #ifdef __GNUC__
    47 #define __cpuid(out, infoType) \
    48 asm volatile(>"pushl %%ebx \n" \
    49 "cpuid \n" \
    50 "movl %%ebx, %1 \n" \
    51 "popl %%ebx" \
    52 : "=a" ((out)[0]), "=r" ((out)[1]), "=c" ((out)[2]), "=d" ((out)[3]): "a" (infoType));
    54 #endif

    doesn't compile on 64bits architectures

    replace with something like this...

    36 #ifdef __GNUC__
    37
    38 #ifdef __amd64__
    39 #define __cpuid(out, infoType) \
    40 asm volatile( "pushq %%rbx \n" \
    41 "cpuid \n" \
    42 "movq %%rbx, 0 \n" \
    43 "movl %%ebx, %1 \n" \
    44 "popq %%rbx" \
    45 : "=a" ((out)[0]), "=r" ((out)[1]), "=c" ((out)[2]), "=d" ((out)[3]): "a" (infoType));
    46 #else // __amd64__
    47 #define __cpuid(out, infoType) \
    48 asm volatile(>"pushl %%ebx \n" \
    49 "cpuid \n" \
    50 "movl %%ebx, %1 \n" \
    51 "popl %%ebx" \
    52 : "=a" ((out)[0]), "=r" ((out)[1]), "=c" ((out)[2]), "=d" ((out)[3]): "a" (infoType));
    53 #endif // __amd64__
    54 #endif

    __________________________________________________ _____________________________

    LayoutTree/css_used_values.cpp
    273 if (properties.right.type == CL_CSSBoxLeft::type_auto || properties.right.type == CL_CSSBoxRight::type_auto)
    error: comparison between 'const enum CL_CSSBoxRight::Type' and 'enum CL_CSSBoxLeft::Type'

    replace with ?
    273 if (properties.right.type == CL_CSSBoxRight::type_auto || properties.right.type == CL_CSSBoxRight::type_auto)
    __________________________________________________ _____________________________

  5. #5
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    Heh heh, that will teach me for fixing detect_cpu_ext for i386 but not testing it for #__amd64__

    Interesting errors for CSSLayout. It is strange I did not get that for 64bit ubuntu, unless the code was submitted to svn after I installed 32bit ubuntu.

    Thanks

  6. #6
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    Updated to SVN 4725
    Last edited by rombust; 07-08-2010 at 12:09 PM.

  7. #7

    Default

    Looks like I removed some option to the compiler... it makes it a bit more pedantic...

    Here is the first part of the bug repport
    __________________________________________________ ______________________________
    Core/CSS/css_document_impl.cpp: In static member function 'static int CL_CSSDocument_Impl::style_load_until(const char*, const CL_StringRef&, int)':
    Core/CSS/css_document_impl.cpp:373: error: comparison between signed and unsigned integer expressions

    style_text.length() is unsigned int, pos is int
    __________________________________________________ ______________________________
    Core/IOData/virtual_directory_listing.cpp: In member function 'bool CL_VirtualDirectoryListing_Impl::next()':
    Core/IOData/virtual_directory_listing.cpp:101: error: comparison between signed and unsigned integer expressions

    this->index is int, list_entries.size() is unsigned int
    __________________________________________________ ______________________________
    Core/Math/ear_clip_triangulator_impl.cpp: In destructor 'virtual CL_EarClipTriangulator_Impl::~CL_EarClipTriangulat or_Impl()':
    Core/Math/ear_clip_triangulator_impl.cpp:50: error: comparison between signed and unsigned integer expressions
    Core/Math/ear_clip_triangulator_impl.cpp:55: error: comparison between signed and unsigned integer expressions
    Core/Math/ear_clip_triangulator_impl.cpp: In member function 'std::vector<CL_Pointf, std::allocator<CL_Pointf> > CL_EarClipTriangulator_Impl::get_vertices()':
    Core/Math/ear_clip_triangulator_impl.cpp:68: error: comparison between signed and unsigned integer expressions
    Core/Math/ear_clip_triangulator_impl.cpp: In member function 'void CL_EarClipTriangulator_Impl::clear()':
    Core/Math/ear_clip_triangulator_impl.cpp:102: error: comparison between signed and unsigned integer expressions
    Core/Math/ear_clip_triangulator_impl.cpp: In member function 'void CL_EarClipTriangulator_Impl::end_hole()':
    Core/Math/ear_clip_triangulator_impl.cpp:243: error: comparison between signed and unsigned integer expressions
    Core/Math/ear_clip_triangulator_impl.cpp:247: error: comparison between signed and unsigned integer expressions

    change for loop variables from int type to unsigned int type in Core/Math/ear_clip_triangulator_impl.cpp
    __________________________________________________ ______________________________
    Core/Math/rect_packer_impl.h: In constructor 'CL_RectPacker_Impl::CL_RectPacker_Impl(const CL_Size&)':
    Core/Math/rect_packer_impl.h:79: error: 'CL_RectPacker_Impl::max_group_size' will be initialized after
    Core/Math/rect_packer_impl.h:73: error: 'CL_RectPacker_Impl::RootNode* CL_RectPacker_Impl::active_root_node'
    Core/Math/rect_packer_impl.cpp:36: error: when initialized here

    Sub-objects must be initialized in the order they are declared.
    Hence, replace (in Core/Math/rect_packer_impl.cpp)
    37 : max_group_size(max_group_size), active_root_node(0), next_node_id(0)
    with :
    37 : active_root_node(0), next_node_id(0), max_group_size(max_group_size)
    __________________________________________________ ______________________________
    Core/System/datetime.cpp: In member function 'void CL_DateTime::throw_if_invalid_date(int, int, int, int, int, int, int) const':
    Core/System/datetime.cpp:871: error: suggest parentheses around comparison in operand of '|'

    871 if (year < 1900 || year > 2900 | month < 1 || month > 12 || day < 1 || day > 31 || minute < 0 || minute > 59 || seconds < 0 || seconds > 60 || nanoseconds >= 1000000000)
    lacks a | (after 2900)
    871 if (year < 1900 || year > 2900 || month < 1 || month > 12 || day < 1 || day > 31 || minute < 0 || minute > 59 || seconds < 0 || seconds > 60 || nanoseconds >= 1000000000)
    __________________________________________________ ______________________________
    Core/System/keep_alive.cpp: In static member function 'static void CL_KeepAlive:rocess(int)':
    Core/System/keep_alive.cpp:83: error: comparison between signed and unsigned integer expressions

    events.size() is unsigned int, wakup_reason is int **AND CAN BE NEGATIVE !**
    __________________________________________________ ______________________________
    Core/System/timer.cpp: In member function 'void CL_Timer_Thread::start(int, unsigned int, bool)':
    Core/System/timer.cpp:88: error: comparison between signed and unsigned integer expressions

    new_timeout is unsigned int, timeout is int **AND CAN BE NEGATIVE !**
    __________________________________________________ ______________________________
    Core/Text/string_help.cpp: In static member function 'static CL_TempString8 CL_StringHelp::wchar_to_utf8(wchar_t)':
    Core/Text/string_help.cpp:186: error: comparison between signed and unsigned integer expressions

    GCC thinks that wchat_t is signed. A possible workaround is :
    140 CL_TempString8 CL_StringHelp::wchar_to_utf8(unsigned wchar_t value)

    which requires to change the API to match the new prototype.
    __________________________________________________ ______________________________
    Core/Text/utf8_reader.cpp: In constructor 'CL_UTF8_Reader_Impl::CL_UTF8_Reader_Impl(const CL_StringRef8&)':
    Core/Text/utf8_reader.cpp:41: error: 'CL_UTF8_Reader_Impl::data' will be initialized after
    Core/Text/utf8_reader.cpp:39: error: 'unsigned int CL_UTF8_Reader_Impl::current_position'
    Core/Text/utf8_reader.cpp:50: error: when initialized here

    change line
    51 : data( (unsigned char *) text.data()), current_position(0), length(text.length())
    with
    51 : current_position(0), length(text.length()), data( (unsigned char *) text.data())
    __________________________________________________ ______________________________
    XML/xpath_evaluator_impl.cpp: In member function 'void CL_XPathEvaluator_Impl::evaluate_location_step(con st CL_DomNode&, const std::vector<CL_XPathLocationStep, std::allocator<CL_XPathLocationStep> >&, int, const CL_StringRef&, std::vector<CL_DomNode, std::allocator<CL_DomNode> >&)':
    XML/xpath_evaluator_impl.cpp:979: error: comparison between signed and unsigned integer expressions

    step_index is int but steps.size() is unsigned int
    __________________________________________________ ______________________________

  8. #8

    Default

    Next part of the bug report :
    __________________________________________________ ______________________________
    Display/2D/rounded_rect_impl.cpp: In member function 'void CL_RoundedRect_Impl::triangulate()':
    Display/2D/rounded_rect_impl.cpp:200: error: comparison between signed and unsigned integer expressions
    Display/2D/rounded_rect_impl.cpp:212: error: comparison between signed and unsigned integer expressions
    Display/2D/sprite.cpp: In member function 'void CL_Sprite::set_linear_filter(bool)':
    Display/2D/sprite.cpp:518: error: comparison between signed and unsigned integer expressions
    Display/2D/sprite.cpp: In member function 'void CL_Sprite::set_delay(int)':
    Display/2D/sprite.cpp:552: error: comparison between signed and unsigned integer expressions

    int in for loops shoud be unsigned int
    __________________________________________________ ______________________________
    2D/span_layout_impl.cpp: In member function 'CL_SpanLayout_Impl::TextSizeResult CL_SpanLayout_Impl::find_text_size(CL_GraphicConte xt&, const CL_SpanLayout_Impl::TextBlock&, int, int)':
    2D/span_layout_impl.cpp:343: error: comparison between signed and unsigned integer expressions
    2D/span_layout_impl.cpp: In member function 'std::vector<CL_SpanLayout_Impl::TextBlock, std::allocator<CL_SpanLayout_Impl::TextBlock> > CL_SpanLayout_Impl::find_text_blocks()':
    2D/span_layout_impl.cpp:384: error: comparison between signed and unsigned integer expressions

    __________________________________________________ ______________________________
    Collision/collision_outline_generic.cpp: In member function 'void CL_CollisionOutline_Generic::set_translation(float , float, bool)':
    Collision/collision_outline_generic.cpp:162: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:166: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:172: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:176: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp: In member function 'void CL_CollisionOutline_Generic::rotate(const CL_Angle&)':
    Collision/collision_outline_generic.cpp:189: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:193: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:199: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:203: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp: In member function 'void CL_CollisionOutline_Generic::set_angle(const CL_Angle&)':
    Collision/collision_outline_generic.cpp:218: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:222: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:228: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:232: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp: In member function 'void CL_CollisionOutline_Generic::set_scale(float, float)':
    Collision/collision_outline_generic.cpp:253: error: comparison between signed and unsigned integer expressions
    Collision/collision_outline_generic.cpp:257: error: comparison between signed and unsigned integer expressions

    sed 's/for (int/for (unsigned int/g'
    __________________________________________________ ______________________________

    At this point, I disabled warnings... and the compilation ended without errors, raising the temperature of the room by some more degrees.

  9. #9

    Default

    I did some more testing.
    The fps I gave you yesterday were without -O2
    Here is what I get with -O3 ^^"

    It seems that X errors occur when GL2+ is used. The examples worked fine with CL2.1.1. So, either they were using GL2.1 or something broke…

    3D/
    - Chess3D doesn't compile because of lacks of 3ds lib
    - BumpMapping, GeometryShader, Instancing, LightSurface, Quaternion, Shadow, SpotLight and VertexBuffer raise X Errors
    - Object3D works fine

    Core/
    works fine

    Database/
    works fine

    Display/
    - Basic2D works fine
    - DisplayTarget
    * SW : 250 fps
    * GL1.3 : 737 fps
    * GL2+ : raises X error
    - MultiWindow raises X error

    Display_GL/
    - CubeGL1 works fine
    - CustomeGL works fine

    Display_Render/ everything fail with X error
    I tried to build Blend with USE_OPENGL_1, I had to add the GL1 lib and keep the GL lib in the makefile. then, it worked well…

    Display_Shaders/ everything fail with X error

    Display_Text/ idem

    Game/
    - Pacman : 224 frames per second
    - Dicewar
    * Makefile lacks a "clean" target
    * Client depends on Collada which uses cstdlib functions (atoi, aotf), however, <cstdlib> isn't included anywhere.
    * fails with X error
    - SpriteRTS works fine

    GUI/
    - GUI, GUI3D, GUICustomComponent fail with X error
    - GUIBasc, GUILayout work fine

    Input/ works fine

    Sound/ works fine

  10. #10
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    I'm very happy with that.

    The GL target error will be caused by the opengl 3.0 context selection. That's the only difference with it and the GL1 target.

  11. #11

    Default

    Ok but then, is the X error a clanlib bug, or a feature (lack of support of something on my computer) ?
    In the first case, is it possible to do some more testing to identify the error ? (with as hidden top-secret aim to make it work on my system ^^")
    Last edited by captnfab; 07-09-2010 at 02:17 PM.

  12. #12
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    I am 95% sure it's a ClanLib bug.

    I added OpenGL 3.0 context creation about 2 months ago, but I did not fully test it.

    In CL_OpenGLWindowProvider_GLX::create_context() (GL/GLX/opengl_window_provider_glx.cpp ) : -

    I guess it will work if you remove the following lines of code:

    Code:
    	if (glXCreateContextAttribs)
    	{
    		GLXContext context_gl3;
    		context_gl3 = glXCreateContextAttribs(x11_window.get_display(), opengl_visual_info, shared_context, GL_TRUE, attribs);
    		if (context_gl3)
    		{
    			glx.glXDestroyContext(x11_window.get_display(), context);
    			context = context_gl3;
    		}
    	}
    If that does fix it, then it needs fixed. If not, then something else needs fixed

  13. #13

    Default

    No more error with these lines of code removed.
    Now you know where the problem is

  14. #14
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    All fixes applied

    Updated to SVN 4737

    http://esoteric.clanlib.org/~rombust/ClanLib-2.2.0.tgz <--- linux line feeds, without Microsoft Windows themes
    http://esoteric.clanlib.org/~rombust/ClanLib-2.2.0.zip <--- windows line feeds, including Microsoft Windows themes

  15. #15
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    (Note, the planned release is on hold until the removal of UNICODE is complete)

  16. #16
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    Updated to SVN 4757

    Note: Utilities/TexturePacker does not work at the moment

    Code:
    int CssPacker::load(const CL_String &filename)
    {
    	doc.load(filename);
    
    	std::vector<CL_CSSImport> &imports = doc.get_imports();
    
    	return imports.size();
    }
    
    void CssPacker::save(const CL_String &filename)
    {
    	CL_File output_file(filename, CL_File::create_always, CL_File::access_write);
    	doc.save(output_file);
    }
    CL_CSSImport does not have get_imports(). And CL_CSSDocument does not have save()
    Last edited by rombust; 07-16-2010 at 02:18 PM.

  17. #17
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

  18. #18

    Default

    Well I built ClanLib on CentOS 5 32bit and CentOS 6 64bit and there is no problem
    (With support of SWRender, OpenGL1 & 2)
    Maybe I can update your tutorial for building ClanLib on CentOS (the dependencies are not exactly the same)

  19. #19
    ClanLib Developer
    Join Date
    Sep 2006
    Location
    Bergen, Norway
    Posts
    588

    Default

    Feel free, the wiki is opened for anyone to edit if you register first.

Similar Threads

  1. Preview of ClanLib 2.0.3 - Layered Windows In OpenGL
    By rombust in forum Official ClanLib SDK Forums
    Replies: 1
    Last Post: 06-23-2009, 05:05 PM
  2. Some requested things to implement
    By SLATE in forum Funeral Quest
    Replies: 6
    Last Post: 09-27-2004, 04:59 PM

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •