Commit 91c9544a authored by Davis King's avatar Davis King
Browse files

set the subversion eol-style to native for these files

--HG--
extra : convert_revision : svn%3Afdd8eb12-d10e-0410-9acb-85c331704f74/trunk%402354
parent 8fa33842
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>API Wrappers</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<p>
These wrappers provide a portable object oriented interface for networking, multithreading,
GUI development, and file browsing.
Programs written using them can be compiled under POSIX or MS Windows platforms without changing the code.
</p>
<p>One important thing to note about the API wrappers (except the threading wrappers)
is that some platforms
need to be initialized in some way or another before the API will work right.
Because of this it is never safe to call API wrapper functions before
main() has been entered. This means no global objects with
constructors that call them or any weird stuff like that.</p>
</body>
<!-- ************************************************************************* -->
<menu width="180">
<top>
<section>
<name>API</name>
<item>
<name>gui_widgets</name>
<sub>
<item nolink="true">
<name>widgets</name>
<sub>
<item>
<name>dragable</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#dragable</link>
</item>
<item>
<name>arrow_button</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#arrow_button</link>
</item>
<item>
<name>tooltip</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#tooltip</link>
</item>
<item>
<name>button_action</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#button_action</link>
</item>
<item>
<name>scrollable_region</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#scrollable_region</link>
</item>
<item>
<name>zoomable_region</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#zoomable_region</link>
</item>
<item>
<name>mouse_over_event</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#mouse_over_event</link>
</item>
<item>
<name>scroll_bar</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#scroll_bar</link>
</item>
<item>
<name>widget_group</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#widget_group</link>
</item>
<item>
<name>image_widget</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#image_widget</link>
</item>
<item>
<name>popup_menu</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#popup_menu</link>
</item>
<item>
<name>menu_item</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#menu_item</link>
</item>
<item>
<name>menu_item_text</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#menu_item_text</link>
</item>
<item>
<name>menu_item_separator</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#menu_item_separator</link>
</item>
<item>
<name>menu_item_submenu</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#menu_item_submenu</link>
</item>
<item>
<name>named_rectangle</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#named_rectangle</link>
</item>
<item>
<name>menu_bar</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#menu_bar</link>
</item>
<item>
<name>message_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#message_box</link>
</item>
<item>
<name>message_box_blocking</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#message_box</link>
</item>
<item>
<name>open_file_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#open_file_box</link>
</item>
<item>
<name>open_existing_file_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#open_existing_file_box</link>
</item>
<item>
<name>save_file_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#save_file_box</link>
</item>
<item>
<name>label</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#label</link>
</item>
<item>
<name>button</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#button</link>
</item>
<item>
<name>toggle_button</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#toggle_button</link>
</item>
<item>
<name>text_grid</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#text_grid</link>
</item>
<item>
<name>directed_graph_drawer</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#directed_graph_drawer</link>
</item>
<item>
<name>list_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#list_box</link>
</item>
<item>
<name>check_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#check_box</link>
</item>
<item>
<name>radio_button</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#radio_button</link>
</item>
<item>
<name>text_field</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#text_field</link>
</item>
<item>
<name>tabbed_display</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#tabbed_display</link>
</item>
<item>
<name>mouse_tracker</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#mouse_tracker</link>
</item>
</sub>
</item>
<item nolink="true">
<name>styles</name>
<sub>
<item>
<name>button_style</name>
<link>dlib/gui_widgets/style_abstract.h.html#button_style</link>
</item>
<item>
<name>button_style_default</name>
<link>dlib/gui_widgets/style_abstract.h.html#button_style_default</link>
</item>
<item>
<name>button_style_toolbar1</name>
<link>dlib/gui_widgets/style_abstract.h.html#button_style_toolbar1</link>
</item>
<item>
<name>button_style_toolbar_icon1</name>
<link>dlib/gui_widgets/style_abstract.h.html#button_style_toolbar_icon1</link>
</item>
<item>
<name>toggle_button_style</name>
<link>dlib/gui_widgets/style_abstract.h.html#toggle_button_style</link>
</item>
<item>
<name>toggle_button_style_default</name>
<link>dlib/gui_widgets/style_abstract.h.html#toggle_button_style_default</link>
</item>
<item>
<name>toggle_button_style_check_box</name>
<link>dlib/gui_widgets/style_abstract.h.html#toggle_button_style_check_box</link>
</item>
<item>
<name>toggle_button_style_radio_button</name>
<link>dlib/gui_widgets/style_abstract.h.html#toggle_button_style_radio_button</link>
</item>
</sub>
</item>
<item nolink="true">
<name>canvas drawing functions</name>
<sub>
<item>
<name>draw_line</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_line</link>
</item>
<item>
<name>draw_rectangle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_rectangle</link>
</item>
<item>
<name>draw_circle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_circle</link>
</item>
<item>
<name>draw_pixel</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_pixel</link>
</item>
<item>
<name>draw_solid_circle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_solid_circle</link>
</item>
<item>
<name>draw_button_down</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_button_down</link>
</item>
<item>
<name>draw_sunken_rectangle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_sunken_rectangle</link>
</item>
<item>
<name>draw_button_up</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_button_up</link>
</item>
<item>
<name>draw_checkered</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_checkered</link>
</item>
<item>
<name>draw_image</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_image</link>
</item>
<item>
<name>fill_rect</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#fill_rect</link>
</item>
<item>
<name>fill_rect_with_vertical_gradient</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#fill_rect_with_vertical_gradient</link>
</item>
<item>
<name>fill_gradient_rounded</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#fill_gradient_rounded</link>
</item>
<item>
<name>draw_rounded_rectangle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_rounded_rectangle</link>
</item>
</sub>
</item>
<item>
<name>drawable</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#drawable</link>
<sub>
<item>
<name>set_main_font</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#set_main_font</link>
</item>
<item>
<name>main_font</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#main_font</link>
</item>
<item>
<name>z_order</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#z_order</link>
</item>
<item>
<name>next_free_user_event_number</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#next_free_user_event_number</link>
</item>
<item>
<name>set_z_order</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#set_z_order</link>
</item>
<item nolink="true">
<name>shape</name>
<sub>
<item>
<name>get_rect</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#get_rect</link>
</item>
<item>
<name>bottom</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#bottom</link>
</item>
<item>
<name>top</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#top</link>
</item>
<item>
<name>left</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#left</link>
</item>
<item>
<name>right</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#right</link>
</item>
<item>
<name>width</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#width</link>
</item>
<item>
<name>height</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#height</link>
</item>
</sub>
</item>
<item>
<name>set_pos</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#set_pos</link>
</item>
<item>
<name>is_enabled</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#is_enabled</link>
</item>
<item>
<name>enable</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#enable</link>
</item>
<item>
<name>disable</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#disable</link>
</item>
<item>
<name>is_hidden</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#is_hidden</link>
</item>
<item>
<name>show</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#show</link>
</item>
<item>
<name>hide</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#hide</link>
</item>
<item>
<name>parent_window</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#parent_window</link>
</item>
<item>
<name>enable_events</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#enable_events</link>
</item>
<item>
<name>events_are_enabled</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#events_are_enabled</link>
</item>
<item>
<name>disable_events</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#disable_events</link>
</item>
<item nolink="true">
<name>events</name>
<sub>
<item>
<name>on_window_resized</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_window_resized</link>
</item>
<item>
<name>on_window_moved</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_window_moved</link>
</item>
<item>
<name>on_focus_gained</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_focus_gained</link>
</item>
<item>
<name>on_focus_lost</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_focus_lost</link>
</item>
<item>
<name>on_mouse_up</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_up</link>
</item>
<item>
<name>on_mouse_move</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_move</link>
</item>
<item>
<name>on_mouse_enter</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_enter</link>
</item>
<item>
<name>on_mouse_leave</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_leave</link>
</item>
<item>
<name>on_mouse_down</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_down</link>
</item>
<item>
<name>on_wheel_up</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_wheel_up</link>
</item>
<item>
<name>on_wheel_down</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_wheel_down</link>
</item>
<item>
<name>on_keydown</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_keydown</link>
</item>
<item>
<name>on_string_put</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_string_put</link>
</item>
<item>
<name>on_user_event</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_user_event</link>
</item>
<item>
<name>draw</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#draw</link>
</item>
</sub>
</item>
</sub>
</item>
<item>
<name>drawable_window</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#drawable_window</link>
</item>
<item nolink="true">
<name>fonts</name>
<sub>
<item>
<name>letter</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#letter</link>
</item>
<item>
<name>font</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#font</link>
</item>
<item>
<name>default_font</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#default_font</link>
</item>
<item>
<name>get_native_font</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#get_native_font</link>
</item>
<item>
<name>bdf_font</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#bdf_font</link>
</item>
</sub>
</item>
</sub>
</item>
<item>
<name>gui_core</name>
<sub>
<item>
<name>base_window</name>
<link>dlib/gui_core/gui_core_kernel_abstract.h.html#base_window</link>
</item>
<item>
<name>canvas</name>
<link>dlib/gui_core/gui_core_kernel_abstract.h.html#canvas</link>
</item>
<item>
<name>get_from_clipboard</name>
<link>dlib/gui_core/gui_core_kernel_abstract.h.html#get_from_clipboard</link>
</item>
<item>
<name>put_on_clipboard</name>
<link>dlib/gui_core/gui_core_kernel_abstract.h.html#put_on_clipboard</link>
</item>
</sub>
</item>
<item>
<name>dir_nav</name>
<sub>
<item>
<name>get_filesystem_roots</name>
<link>dlib/dir_nav/dir_nav_kernel_abstract.h.html#get_filesystem_roots</link>
</item>
<item>
<name>file</name>
<link>dlib/dir_nav/dir_nav_kernel_abstract.h.html#file</link>
</item>
<item>
<name>directory</name>
<link>dlib/dir_nav/dir_nav_kernel_abstract.h.html#directory</link>
</item>
</sub>
</item>
<item>
<name>misc_api</name>
<sub>
<item>
<name>sleep</name>
<link>dlib/misc_api/misc_api_kernel_abstract.h.html#sleep</link>
</item>
<item>
<name>get_current_dir</name>
<link>dlib/misc_api/misc_api_kernel_abstract.h.html#get_current_dir</link>
</item>
<item>
<name>create_directory</name>
<link>dlib/misc_api/misc_api_kernel_abstract.h.html#create_directory</link>
</item>
<item>
<name>timestamper</name>
<link>dlib/misc_api/misc_api_kernel_abstract.h.html#timestamper</link>
</item>
</sub>
</item>
<item>
<name>threads</name>
<sub>
<item nolink="true">
<name>extensions</name>
<sub>
<item>
<name>thread_specific_data</name>
<link>dlib/threads/thread_specific_data_extension_abstract.h.html</link>
</item>
<item>
<name>create_new_thread extension</name>
<link>dlib/threads/create_new_thread_extension_abstract.h.html#create_new_thread</link>
</item>
<item>
<name>rsignaler</name>
<link>dlib/threads/rsignaler_extension_abstract.h.html#rsignaler</link>
</item>
<item>
<name>rmutex</name>
<link>dlib/threads/rmutex_extension_abstract.h.html#rmutex</link>
</item>
<item>
<name>auto_mutex</name>
<link>dlib/threads/auto_mutex_extension_abstract.h.html#auto_mutex</link>
</item>
<item>
<name>auto_unlock</name>
<link>dlib/threads/auto_unlock_extension_abstract.h.html#auto_unlock</link>
</item>
<item>
<name>threaded_object</name>
<link>dlib/threads/threaded_object_extension_abstract.h.html#threaded_object</link>
</item>
<item>
<name>thread_function</name>
<link>dlib/threads/thread_function_extension_abstract.h.html#thread_function</link>
</item>
<item>
<name>multithreaded_object</name>
<link>dlib/threads/multithreaded_object_extension_abstract.h.html#multithreaded_object</link>
</item>
</sub>
</item>
<item>
<name>is_dlib_thread</name>
<link>dlib/threads/threads_kernel_abstract.h.html#is_dlib_thread</link>
</item>
<item>
<name>create_new_thread</name>
<link>dlib/threads/threads_kernel_abstract.h.html#create_new_thread</link>
</item>
<item>
<name>mutex</name>
<link>dlib/threads/threads_kernel_abstract.h.html#mutex</link>
</item>
<item>
<name>register_thread_end_handler</name>
<link>dlib/threads/threads_kernel_abstract.h.html#register_thread_end_handler</link>
</item>
<item>
<name>register_program_ending_handler</name>
<link>dlib/threads/threads_kernel_abstract.h.html#register_program_ending_handler</link>
</item>
<item>
<name>signaler</name>
<link>dlib/threads/threads_kernel_abstract.h.html#signaler</link>
</item>
<item>
<name>get_thread_id</name>
<link>dlib/threads/threads_kernel_abstract.h.html#get_thread_id</link>
</item>
</sub>
</item>
<item>
<name>sockets</name>
<sub>
<item nolink="true">
<name>extensions</name>
<sub>
<item>
<name>connect</name>
<link>dlib/sockets/sockets_extensions_abstract.h.html#connect</link>
</item>
<item>
<name>is_ip_address</name>
<link>dlib/sockets/sockets_extensions_abstract.h.html#is_ip_address</link>
</item>
<item>
<name>close_gracefully</name>
<link>dlib/sockets/sockets_extensions_abstract.h.html#close_gracefully</link>
</item>
</sub>
</item>
<item nolink="true">
<name>objects</name>
<sub>
<item>
<name>connection</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#connection</link>
</item>
<item>
<name>listener</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#listener</link>
</item>
</sub>
</item>
<item nolink="true">
<name>functions</name>
<sub>
<item>
<name>create_connection</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#create_connection</link>
</item>
<item>
<name>create_listener</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#create_listener</link>
</item>
<item>
<name>get_local_hostname</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#get_local_hostname</link>
</item>
<item>
<name>hostname_to_ip</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#hostname_to_ip</link>
</item>
<item>
<name>ip_to_hostname</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#ip_to_hostname</link>
</item>
</sub>
</item>
</sub>
</item>
</section>
</top>
</menu>
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<components>
<component>
<name>dir_nav</name>
<file>dlib/dir_nav.h</file>
<spec_file>dlib/dir_nav/dir_nav_kernel_abstract.h</spec_file>
<description>
This is a set of objects that provide an easy and portable way to traverse a directory tree.
</description>
<examples>
<example>dir_nav_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>dir_nav_kernel_1</name>
<file>dlib/dir_nav/dir_nav_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>dir_nav_kernel_2</name>
<file>dlib/dir_nav/dir_nav_kernel_2.h</file>
<description>
POSIX implementation
</description>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>gui_core</name>
<file>dlib/gui_core.h</file>
<spec_file>dlib/gui_core/gui_core_kernel_abstract.h</spec_file>
<description>
This is a set of objects and functions which provide a very basic
framework for manipulating windows. It is intended to provide a portable
interface which can be used to build a more complex windowing toolkit.
</description>
<implementations>
<implementation>
<name>gui_core_kernel_1</name>
<file>dlib/gui_core/gui_core_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>gui_core_kernel_2</name>
<file>dlib/gui_core/gui_core_kernel_2.h</file>
<description>
X Windows implementation
</description>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>misc_api</name>
<file>dlib/misc_api.h</file>
<spec_file>dlib/misc_api/misc_api_kernel_abstract.h</spec_file>
<description>
This is just a collection of miscellaneous APIs that were small/simple
enough not to warrant their own module.
</description>
<implementations>
<implementation>
<name>misc_api_kernel_1</name>
<file>dlib/misc_api/misc_api_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>misc_api_kernel_2</name>
<file>dlib/misc_api/misc_api_kernel_2.h</file>
<description>
POSIX implementation
</description>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>sockets</name>
<file>dlib/sockets.h</file>
<spec_file>dlib/sockets/sockets_kernel_abstract.h</spec_file>
<description>
This is a set of objects that provides an easy to use and object oriented
interface for dealing with TCP networking. There are currently two implementations,
one for UNIX and another for all versions of Windows after Windows95.
Both provide the exact same interface so programs written with them can be
recompiled on either platform without a problem.
<p>
You also may want to take note of the <a href="other.html#timeout">timeout</a> object.
It provides a mechanism which you can use to add a timeout to a network operation.
</p>
</description>
<examples>
<example>sockets_ex.cpp.html</example>
<example>sockstreambuf_ex.cpp.html</example>
<example>sockets_ex_2.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>sockets_kernel_1</name>
<file>dlib/sockets/sockets_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>sockets_kernel_2</name>
<file>dlib/sockets/sockets_kernel_2.h</file>
<description>
POSIX implementation
</description>
</implementation>
</implementations>
<extensions>
<extension>
<name>sockets_extensions</name>
<spec_file>dlib/sockets/sockets_extensions_abstract.h</spec_file>
<description>
<p>
This is just some miscellaneous extensions to the socket api.
</p>
The implementation of this extension can be found
<a href="dlib/sockets/sockets_extensions.h.html">here</a>.
</description>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>threads</name>
<file>dlib/threads.h</file>
<spec_file>dlib/threads/threads_kernel_abstract.h</spec_file>
<description>
This is a set of objects that provides an easy to use and object oriented interface
for creating multi-threaded programs. There are currently two implementations, one
for UNIX and another for any variant of MS Windows after Windows 95. Both provide
the exact same interface so programs written with them can be recompiled on either
platform without a problem. Both implementations also pool their threads so repeated
calls to create_new_thread are nice and speedy :)
<p>
You also probably want to take note of the <a href="other.html#pipe">pipe</a> object.
It provides an easy to use typesafe mechanism to send messages between threads.
</p>
</description>
<examples>
<example>threads_ex.cpp.html</example>
<example>logger_ex_2.cpp.html</example>
<example>pipe_ex.cpp.html</example>
<example>threaded_object_ex.cpp.html</example>
<example>multithreaded_object_ex.cpp.html</example>
<example>thread_function_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>threads_kernel_1</name>
<file>dlib/threads/threads_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>threads_kernel_2</name>
<file>dlib/threads/threads_kernel_2.h</file>
<description>
POSIX implementation
</description>
</implementation>
</implementations>
<extensions>
<extension>
<name>rsignaler</name>
<spec_file>dlib/threads/rsignaler_extension_abstract.h</spec_file>
<description>
<p>
This extension adds a signaler object that can be used with the rmutex object.
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/rsignaler_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>thread_specific_data</name>
<spec_file>dlib/threads/thread_specific_data_extension_abstract.h</spec_file>
<description>
<p>
This extension adds the ability to easily create thread specific data.
</p>
The implementation of this extension can be found
<a href="dlib/threads/thread_specific_data_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>rmutex</name>
<spec_file>dlib/threads/rmutex_extension_abstract.h</spec_file>
<description>
<p>
This extension adds a mutex object that can handle recursive calls
to lock().
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/rmutex_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>create_new_thread extension</name>
<spec_file>dlib/threads/create_new_thread_extension_abstract.h</spec_file>
<description>
<p>
This extension adds some templated overloads to the
<a href="dlib/threads/threads_kernel_abstract.h.html#create_new_thread">create_new_thread()</a> function. They allow you to create new threads using member functions from a class.
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/create_new_thread_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>auto_mutex</name>
<spec_file>dlib/threads/auto_mutex_extension_abstract.h</spec_file>
<description>
<p>
This extension adds a mechanism to automatically lock and unlock a mutex.
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/auto_mutex_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>thread_function</name>
<spec_file>dlib/threads/thread_function_extension_abstract.h</spec_file>
<description>
<p>
This object represents a thread on a global C++ function. That is, it allows you
to run a global function in its own thread.
</p>
The implementation of this extension can be found
<a href="dlib/threads/thread_function_extension.h.html">here</a>.
</description>
<examples>
<example>thread_function_ex.cpp.html</example>
</examples>
</extension>
<extension>
<name>threaded_object</name>
<spec_file>dlib/threads/threaded_object_extension_abstract.h</spec_file>
<description>
<p>
This extension represents a simple threaded object. It provides a convenient
mechanism to create an object that contains a thread.
</p>
The implementation of this extension can be found
<a href="dlib/threads/threaded_object_extension.h.html">here</a>.
</description>
<examples>
<example>threaded_object_ex.cpp.html</example>
</examples>
</extension>
<extension>
<name>multithreaded_object</name>
<spec_file>dlib/threads/multithreaded_object_extension_abstract.h</spec_file>
<description>
<p>
This object represents a multithreaded object. It is similar to
the <a href="#threaded_object">threaded_object</a> except it allows you to have many threads in a
single object rather than just one.
</p>
The implementation of this extension can be found
<a href="dlib/threads/multithreaded_object_extension.h.html">here</a>.
</description>
<examples>
<example>multithreaded_object_ex.cpp.html</example>
<example>pipe_ex.cpp.html</example>
</examples>
</extension>
<extension>
<name>auto_unlock</name>
<spec_file>dlib/threads/auto_unlock_extension_abstract.h</spec_file>
<description>
<p>
This extension adds a mechanism to automatically unlock a mutex.
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/auto_unlock_extension.h.html">here</a>.
</description>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>gui_widgets</name>
<file>dlib/gui_widgets.h</file>
<description>
<p>
This component is a collection of various windowing widgets such as buttons,
labels, text boxes, and so on. It also includes the drawable
interface, drawable_window, and font handling objects.
<a href="dlib/gui_widgets/widgets_abstract.h.html">dlib/gui_widgets/widgets_abstract.h</a>
defines all of the high level graphical widgets provided by this
component that can appear in a drawable_window. To view the specifications for the other members of this
component look at <a href="dlib/gui_widgets/fonts_abstract.h.html">dlib/gui_widgets/fonts_abstract.h</a>,
<a href="dlib/gui_widgets/drawable_abstract.h.html">dlib/gui_widgets/drawable_abstract.h</a>,
and <a href="dlib/gui_widgets/base_widgets_abstract.h.html">dlib/gui_widgets/base_widgets_abstract.h</a>.
</p>
<p>This component isn't actually a wrapper on top of OS APIs. Rather, it is
implemented on top of the <a href="#gui_core">gui_core</a>
component. I put it on this page just because I expect that people would
look here when searching for the sort of functionality provided by this component.
</p>
</description>
<examples>
<example>gui_api_ex.cpp.html</example>
<example>image_ex.cpp.html</example>
<example>bayes_net_gui_ex.cpp.html</example>
</examples>
</component>
<!-- ************************************************************************* -->
</components>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>API Wrappers</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<p>
These wrappers provide a portable object oriented interface for networking, multithreading,
GUI development, and file browsing.
Programs written using them can be compiled under POSIX or MS Windows platforms without changing the code.
</p>
<p>One important thing to note about the API wrappers (except the threading wrappers)
is that some platforms
need to be initialized in some way or another before the API will work right.
Because of this it is never safe to call API wrapper functions before
main() has been entered. This means no global objects with
constructors that call them or any weird stuff like that.</p>
</body>
<!-- ************************************************************************* -->
<menu width="180">
<top>
<section>
<name>API</name>
<item>
<name>gui_widgets</name>
<sub>
<item nolink="true">
<name>widgets</name>
<sub>
<item>
<name>dragable</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#dragable</link>
</item>
<item>
<name>arrow_button</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#arrow_button</link>
</item>
<item>
<name>tooltip</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#tooltip</link>
</item>
<item>
<name>button_action</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#button_action</link>
</item>
<item>
<name>scrollable_region</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#scrollable_region</link>
</item>
<item>
<name>zoomable_region</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#zoomable_region</link>
</item>
<item>
<name>mouse_over_event</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#mouse_over_event</link>
</item>
<item>
<name>scroll_bar</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#scroll_bar</link>
</item>
<item>
<name>widget_group</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#widget_group</link>
</item>
<item>
<name>image_widget</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#image_widget</link>
</item>
<item>
<name>popup_menu</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#popup_menu</link>
</item>
<item>
<name>menu_item</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#menu_item</link>
</item>
<item>
<name>menu_item_text</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#menu_item_text</link>
</item>
<item>
<name>menu_item_separator</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#menu_item_separator</link>
</item>
<item>
<name>menu_item_submenu</name>
<link>dlib/gui_widgets/base_widgets_abstract.h.html#menu_item_submenu</link>
</item>
<item>
<name>named_rectangle</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#named_rectangle</link>
</item>
<item>
<name>menu_bar</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#menu_bar</link>
</item>
<item>
<name>message_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#message_box</link>
</item>
<item>
<name>message_box_blocking</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#message_box</link>
</item>
<item>
<name>open_file_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#open_file_box</link>
</item>
<item>
<name>open_existing_file_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#open_existing_file_box</link>
</item>
<item>
<name>save_file_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#save_file_box</link>
</item>
<item>
<name>label</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#label</link>
</item>
<item>
<name>button</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#button</link>
</item>
<item>
<name>toggle_button</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#toggle_button</link>
</item>
<item>
<name>text_grid</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#text_grid</link>
</item>
<item>
<name>directed_graph_drawer</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#directed_graph_drawer</link>
</item>
<item>
<name>list_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#list_box</link>
</item>
<item>
<name>check_box</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#check_box</link>
</item>
<item>
<name>radio_button</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#radio_button</link>
</item>
<item>
<name>text_field</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#text_field</link>
</item>
<item>
<name>tabbed_display</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#tabbed_display</link>
</item>
<item>
<name>mouse_tracker</name>
<link>dlib/gui_widgets/widgets_abstract.h.html#mouse_tracker</link>
</item>
</sub>
</item>
<item nolink="true">
<name>styles</name>
<sub>
<item>
<name>button_style</name>
<link>dlib/gui_widgets/style_abstract.h.html#button_style</link>
</item>
<item>
<name>button_style_default</name>
<link>dlib/gui_widgets/style_abstract.h.html#button_style_default</link>
</item>
<item>
<name>button_style_toolbar1</name>
<link>dlib/gui_widgets/style_abstract.h.html#button_style_toolbar1</link>
</item>
<item>
<name>button_style_toolbar_icon1</name>
<link>dlib/gui_widgets/style_abstract.h.html#button_style_toolbar_icon1</link>
</item>
<item>
<name>toggle_button_style</name>
<link>dlib/gui_widgets/style_abstract.h.html#toggle_button_style</link>
</item>
<item>
<name>toggle_button_style_default</name>
<link>dlib/gui_widgets/style_abstract.h.html#toggle_button_style_default</link>
</item>
<item>
<name>toggle_button_style_check_box</name>
<link>dlib/gui_widgets/style_abstract.h.html#toggle_button_style_check_box</link>
</item>
<item>
<name>toggle_button_style_radio_button</name>
<link>dlib/gui_widgets/style_abstract.h.html#toggle_button_style_radio_button</link>
</item>
</sub>
</item>
<item nolink="true">
<name>canvas drawing functions</name>
<sub>
<item>
<name>draw_line</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_line</link>
</item>
<item>
<name>draw_rectangle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_rectangle</link>
</item>
<item>
<name>draw_circle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_circle</link>
</item>
<item>
<name>draw_pixel</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_pixel</link>
</item>
<item>
<name>draw_solid_circle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_solid_circle</link>
</item>
<item>
<name>draw_button_down</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_button_down</link>
</item>
<item>
<name>draw_sunken_rectangle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_sunken_rectangle</link>
</item>
<item>
<name>draw_button_up</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_button_up</link>
</item>
<item>
<name>draw_checkered</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_checkered</link>
</item>
<item>
<name>draw_image</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_image</link>
</item>
<item>
<name>fill_rect</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#fill_rect</link>
</item>
<item>
<name>fill_rect_with_vertical_gradient</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#fill_rect_with_vertical_gradient</link>
</item>
<item>
<name>fill_gradient_rounded</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#fill_gradient_rounded</link>
</item>
<item>
<name>draw_rounded_rectangle</name>
<link>dlib/gui_widgets/canvas_drawing_abstract.h.html#draw_rounded_rectangle</link>
</item>
</sub>
</item>
<item>
<name>drawable</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#drawable</link>
<sub>
<item>
<name>set_main_font</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#set_main_font</link>
</item>
<item>
<name>main_font</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#main_font</link>
</item>
<item>
<name>z_order</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#z_order</link>
</item>
<item>
<name>next_free_user_event_number</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#next_free_user_event_number</link>
</item>
<item>
<name>set_z_order</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#set_z_order</link>
</item>
<item nolink="true">
<name>shape</name>
<sub>
<item>
<name>get_rect</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#get_rect</link>
</item>
<item>
<name>bottom</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#bottom</link>
</item>
<item>
<name>top</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#top</link>
</item>
<item>
<name>left</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#left</link>
</item>
<item>
<name>right</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#right</link>
</item>
<item>
<name>width</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#width</link>
</item>
<item>
<name>height</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#height</link>
</item>
</sub>
</item>
<item>
<name>set_pos</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#set_pos</link>
</item>
<item>
<name>is_enabled</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#is_enabled</link>
</item>
<item>
<name>enable</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#enable</link>
</item>
<item>
<name>disable</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#disable</link>
</item>
<item>
<name>is_hidden</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#is_hidden</link>
</item>
<item>
<name>show</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#show</link>
</item>
<item>
<name>hide</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#hide</link>
</item>
<item>
<name>parent_window</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#parent_window</link>
</item>
<item>
<name>enable_events</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#enable_events</link>
</item>
<item>
<name>events_are_enabled</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#events_are_enabled</link>
</item>
<item>
<name>disable_events</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#disable_events</link>
</item>
<item nolink="true">
<name>events</name>
<sub>
<item>
<name>on_window_resized</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_window_resized</link>
</item>
<item>
<name>on_window_moved</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_window_moved</link>
</item>
<item>
<name>on_focus_gained</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_focus_gained</link>
</item>
<item>
<name>on_focus_lost</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_focus_lost</link>
</item>
<item>
<name>on_mouse_up</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_up</link>
</item>
<item>
<name>on_mouse_move</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_move</link>
</item>
<item>
<name>on_mouse_enter</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_enter</link>
</item>
<item>
<name>on_mouse_leave</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_leave</link>
</item>
<item>
<name>on_mouse_down</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_mouse_down</link>
</item>
<item>
<name>on_wheel_up</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_wheel_up</link>
</item>
<item>
<name>on_wheel_down</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_wheel_down</link>
</item>
<item>
<name>on_keydown</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_keydown</link>
</item>
<item>
<name>on_string_put</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_string_put</link>
</item>
<item>
<name>on_user_event</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#on_user_event</link>
</item>
<item>
<name>draw</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#draw</link>
</item>
</sub>
</item>
</sub>
</item>
<item>
<name>drawable_window</name>
<link>dlib/gui_widgets/drawable_abstract.h.html#drawable_window</link>
</item>
<item nolink="true">
<name>fonts</name>
<sub>
<item>
<name>letter</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#letter</link>
</item>
<item>
<name>font</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#font</link>
</item>
<item>
<name>default_font</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#default_font</link>
</item>
<item>
<name>get_native_font</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#get_native_font</link>
</item>
<item>
<name>bdf_font</name>
<link>dlib/gui_widgets/fonts_abstract.h.html#bdf_font</link>
</item>
</sub>
</item>
</sub>
</item>
<item>
<name>gui_core</name>
<sub>
<item>
<name>base_window</name>
<link>dlib/gui_core/gui_core_kernel_abstract.h.html#base_window</link>
</item>
<item>
<name>canvas</name>
<link>dlib/gui_core/gui_core_kernel_abstract.h.html#canvas</link>
</item>
<item>
<name>get_from_clipboard</name>
<link>dlib/gui_core/gui_core_kernel_abstract.h.html#get_from_clipboard</link>
</item>
<item>
<name>put_on_clipboard</name>
<link>dlib/gui_core/gui_core_kernel_abstract.h.html#put_on_clipboard</link>
</item>
</sub>
</item>
<item>
<name>dir_nav</name>
<sub>
<item>
<name>get_filesystem_roots</name>
<link>dlib/dir_nav/dir_nav_kernel_abstract.h.html#get_filesystem_roots</link>
</item>
<item>
<name>file</name>
<link>dlib/dir_nav/dir_nav_kernel_abstract.h.html#file</link>
</item>
<item>
<name>directory</name>
<link>dlib/dir_nav/dir_nav_kernel_abstract.h.html#directory</link>
</item>
</sub>
</item>
<item>
<name>misc_api</name>
<sub>
<item>
<name>sleep</name>
<link>dlib/misc_api/misc_api_kernel_abstract.h.html#sleep</link>
</item>
<item>
<name>get_current_dir</name>
<link>dlib/misc_api/misc_api_kernel_abstract.h.html#get_current_dir</link>
</item>
<item>
<name>create_directory</name>
<link>dlib/misc_api/misc_api_kernel_abstract.h.html#create_directory</link>
</item>
<item>
<name>timestamper</name>
<link>dlib/misc_api/misc_api_kernel_abstract.h.html#timestamper</link>
</item>
</sub>
</item>
<item>
<name>threads</name>
<sub>
<item nolink="true">
<name>extensions</name>
<sub>
<item>
<name>thread_specific_data</name>
<link>dlib/threads/thread_specific_data_extension_abstract.h.html</link>
</item>
<item>
<name>create_new_thread extension</name>
<link>dlib/threads/create_new_thread_extension_abstract.h.html#create_new_thread</link>
</item>
<item>
<name>rsignaler</name>
<link>dlib/threads/rsignaler_extension_abstract.h.html#rsignaler</link>
</item>
<item>
<name>rmutex</name>
<link>dlib/threads/rmutex_extension_abstract.h.html#rmutex</link>
</item>
<item>
<name>auto_mutex</name>
<link>dlib/threads/auto_mutex_extension_abstract.h.html#auto_mutex</link>
</item>
<item>
<name>auto_unlock</name>
<link>dlib/threads/auto_unlock_extension_abstract.h.html#auto_unlock</link>
</item>
<item>
<name>threaded_object</name>
<link>dlib/threads/threaded_object_extension_abstract.h.html#threaded_object</link>
</item>
<item>
<name>thread_function</name>
<link>dlib/threads/thread_function_extension_abstract.h.html#thread_function</link>
</item>
<item>
<name>multithreaded_object</name>
<link>dlib/threads/multithreaded_object_extension_abstract.h.html#multithreaded_object</link>
</item>
</sub>
</item>
<item>
<name>is_dlib_thread</name>
<link>dlib/threads/threads_kernel_abstract.h.html#is_dlib_thread</link>
</item>
<item>
<name>create_new_thread</name>
<link>dlib/threads/threads_kernel_abstract.h.html#create_new_thread</link>
</item>
<item>
<name>mutex</name>
<link>dlib/threads/threads_kernel_abstract.h.html#mutex</link>
</item>
<item>
<name>register_thread_end_handler</name>
<link>dlib/threads/threads_kernel_abstract.h.html#register_thread_end_handler</link>
</item>
<item>
<name>register_program_ending_handler</name>
<link>dlib/threads/threads_kernel_abstract.h.html#register_program_ending_handler</link>
</item>
<item>
<name>signaler</name>
<link>dlib/threads/threads_kernel_abstract.h.html#signaler</link>
</item>
<item>
<name>get_thread_id</name>
<link>dlib/threads/threads_kernel_abstract.h.html#get_thread_id</link>
</item>
</sub>
</item>
<item>
<name>sockets</name>
<sub>
<item nolink="true">
<name>extensions</name>
<sub>
<item>
<name>connect</name>
<link>dlib/sockets/sockets_extensions_abstract.h.html#connect</link>
</item>
<item>
<name>is_ip_address</name>
<link>dlib/sockets/sockets_extensions_abstract.h.html#is_ip_address</link>
</item>
<item>
<name>close_gracefully</name>
<link>dlib/sockets/sockets_extensions_abstract.h.html#close_gracefully</link>
</item>
</sub>
</item>
<item nolink="true">
<name>objects</name>
<sub>
<item>
<name>connection</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#connection</link>
</item>
<item>
<name>listener</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#listener</link>
</item>
</sub>
</item>
<item nolink="true">
<name>functions</name>
<sub>
<item>
<name>create_connection</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#create_connection</link>
</item>
<item>
<name>create_listener</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#create_listener</link>
</item>
<item>
<name>get_local_hostname</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#get_local_hostname</link>
</item>
<item>
<name>hostname_to_ip</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#hostname_to_ip</link>
</item>
<item>
<name>ip_to_hostname</name>
<link>dlib/sockets/sockets_kernel_abstract.h.html#ip_to_hostname</link>
</item>
</sub>
</item>
</sub>
</item>
</section>
</top>
</menu>
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<components>
<component>
<name>dir_nav</name>
<file>dlib/dir_nav.h</file>
<spec_file>dlib/dir_nav/dir_nav_kernel_abstract.h</spec_file>
<description>
This is a set of objects that provide an easy and portable way to traverse a directory tree.
</description>
<examples>
<example>dir_nav_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>dir_nav_kernel_1</name>
<file>dlib/dir_nav/dir_nav_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>dir_nav_kernel_2</name>
<file>dlib/dir_nav/dir_nav_kernel_2.h</file>
<description>
POSIX implementation
</description>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>gui_core</name>
<file>dlib/gui_core.h</file>
<spec_file>dlib/gui_core/gui_core_kernel_abstract.h</spec_file>
<description>
This is a set of objects and functions which provide a very basic
framework for manipulating windows. It is intended to provide a portable
interface which can be used to build a more complex windowing toolkit.
</description>
<implementations>
<implementation>
<name>gui_core_kernel_1</name>
<file>dlib/gui_core/gui_core_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>gui_core_kernel_2</name>
<file>dlib/gui_core/gui_core_kernel_2.h</file>
<description>
X Windows implementation
</description>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>misc_api</name>
<file>dlib/misc_api.h</file>
<spec_file>dlib/misc_api/misc_api_kernel_abstract.h</spec_file>
<description>
This is just a collection of miscellaneous APIs that were small/simple
enough not to warrant their own module.
</description>
<implementations>
<implementation>
<name>misc_api_kernel_1</name>
<file>dlib/misc_api/misc_api_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>misc_api_kernel_2</name>
<file>dlib/misc_api/misc_api_kernel_2.h</file>
<description>
POSIX implementation
</description>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>sockets</name>
<file>dlib/sockets.h</file>
<spec_file>dlib/sockets/sockets_kernel_abstract.h</spec_file>
<description>
This is a set of objects that provides an easy to use and object oriented
interface for dealing with TCP networking. There are currently two implementations,
one for UNIX and another for all versions of Windows after Windows95.
Both provide the exact same interface so programs written with them can be
recompiled on either platform without a problem.
<p>
You also may want to take note of the <a href="other.html#timeout">timeout</a> object.
It provides a mechanism which you can use to add a timeout to a network operation.
</p>
</description>
<examples>
<example>sockets_ex.cpp.html</example>
<example>sockstreambuf_ex.cpp.html</example>
<example>sockets_ex_2.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>sockets_kernel_1</name>
<file>dlib/sockets/sockets_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>sockets_kernel_2</name>
<file>dlib/sockets/sockets_kernel_2.h</file>
<description>
POSIX implementation
</description>
</implementation>
</implementations>
<extensions>
<extension>
<name>sockets_extensions</name>
<spec_file>dlib/sockets/sockets_extensions_abstract.h</spec_file>
<description>
<p>
This is just some miscellaneous extensions to the socket api.
</p>
The implementation of this extension can be found
<a href="dlib/sockets/sockets_extensions.h.html">here</a>.
</description>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>threads</name>
<file>dlib/threads.h</file>
<spec_file>dlib/threads/threads_kernel_abstract.h</spec_file>
<description>
This is a set of objects that provides an easy to use and object oriented interface
for creating multi-threaded programs. There are currently two implementations, one
for UNIX and another for any variant of MS Windows after Windows 95. Both provide
the exact same interface so programs written with them can be recompiled on either
platform without a problem. Both implementations also pool their threads so repeated
calls to create_new_thread are nice and speedy :)
<p>
You also probably want to take note of the <a href="other.html#pipe">pipe</a> object.
It provides an easy to use typesafe mechanism to send messages between threads.
</p>
</description>
<examples>
<example>threads_ex.cpp.html</example>
<example>logger_ex_2.cpp.html</example>
<example>pipe_ex.cpp.html</example>
<example>threaded_object_ex.cpp.html</example>
<example>multithreaded_object_ex.cpp.html</example>
<example>thread_function_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>threads_kernel_1</name>
<file>dlib/threads/threads_kernel_1.h</file>
<description>
MS Windows implementation
</description>
</implementation>
<implementation>
<name>threads_kernel_2</name>
<file>dlib/threads/threads_kernel_2.h</file>
<description>
POSIX implementation
</description>
</implementation>
</implementations>
<extensions>
<extension>
<name>rsignaler</name>
<spec_file>dlib/threads/rsignaler_extension_abstract.h</spec_file>
<description>
<p>
This extension adds a signaler object that can be used with the rmutex object.
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/rsignaler_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>thread_specific_data</name>
<spec_file>dlib/threads/thread_specific_data_extension_abstract.h</spec_file>
<description>
<p>
This extension adds the ability to easily create thread specific data.
</p>
The implementation of this extension can be found
<a href="dlib/threads/thread_specific_data_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>rmutex</name>
<spec_file>dlib/threads/rmutex_extension_abstract.h</spec_file>
<description>
<p>
This extension adds a mutex object that can handle recursive calls
to lock().
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/rmutex_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>create_new_thread extension</name>
<spec_file>dlib/threads/create_new_thread_extension_abstract.h</spec_file>
<description>
<p>
This extension adds some templated overloads to the
<a href="dlib/threads/threads_kernel_abstract.h.html#create_new_thread">create_new_thread()</a> function. They allow you to create new threads using member functions from a class.
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/create_new_thread_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>auto_mutex</name>
<spec_file>dlib/threads/auto_mutex_extension_abstract.h</spec_file>
<description>
<p>
This extension adds a mechanism to automatically lock and unlock a mutex.
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/auto_mutex_extension.h.html">here</a>.
</description>
</extension>
<extension>
<name>thread_function</name>
<spec_file>dlib/threads/thread_function_extension_abstract.h</spec_file>
<description>
<p>
This object represents a thread on a global C++ function. That is, it allows you
to run a global function in its own thread.
</p>
The implementation of this extension can be found
<a href="dlib/threads/thread_function_extension.h.html">here</a>.
</description>
<examples>
<example>thread_function_ex.cpp.html</example>
</examples>
</extension>
<extension>
<name>threaded_object</name>
<spec_file>dlib/threads/threaded_object_extension_abstract.h</spec_file>
<description>
<p>
This extension represents a simple threaded object. It provides a convenient
mechanism to create an object that contains a thread.
</p>
The implementation of this extension can be found
<a href="dlib/threads/threaded_object_extension.h.html">here</a>.
</description>
<examples>
<example>threaded_object_ex.cpp.html</example>
</examples>
</extension>
<extension>
<name>multithreaded_object</name>
<spec_file>dlib/threads/multithreaded_object_extension_abstract.h</spec_file>
<description>
<p>
This object represents a multithreaded object. It is similar to
the <a href="#threaded_object">threaded_object</a> except it allows you to have many threads in a
single object rather than just one.
</p>
The implementation of this extension can be found
<a href="dlib/threads/multithreaded_object_extension.h.html">here</a>.
</description>
<examples>
<example>multithreaded_object_ex.cpp.html</example>
<example>pipe_ex.cpp.html</example>
</examples>
</extension>
<extension>
<name>auto_unlock</name>
<spec_file>dlib/threads/auto_unlock_extension_abstract.h</spec_file>
<description>
<p>
This extension adds a mechanism to automatically unlock a mutex.
Also note that this extension is included by dlib/threads.h so you don't have to include
anything extra to get it.
</p>
The implementation of this extension can be found
<a href="dlib/threads/auto_unlock_extension.h.html">here</a>.
</description>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>gui_widgets</name>
<file>dlib/gui_widgets.h</file>
<description>
<p>
This component is a collection of various windowing widgets such as buttons,
labels, text boxes, and so on. It also includes the drawable
interface, drawable_window, and font handling objects.
<a href="dlib/gui_widgets/widgets_abstract.h.html">dlib/gui_widgets/widgets_abstract.h</a>
defines all of the high level graphical widgets provided by this
component that can appear in a drawable_window. To view the specifications for the other members of this
component look at <a href="dlib/gui_widgets/fonts_abstract.h.html">dlib/gui_widgets/fonts_abstract.h</a>,
<a href="dlib/gui_widgets/drawable_abstract.h.html">dlib/gui_widgets/drawable_abstract.h</a>,
and <a href="dlib/gui_widgets/base_widgets_abstract.h.html">dlib/gui_widgets/base_widgets_abstract.h</a>.
</p>
<p>This component isn't actually a wrapper on top of OS APIs. Rather, it is
implemented on top of the <a href="#gui_core">gui_core</a>
component. I put it on this page just because I expect that people would
look here when searching for the sort of functionality provided by this component.
</p>
</description>
<examples>
<example>gui_api_ex.cpp.html</example>
<example>image_ex.cpp.html</example>
<example>bayes_net_gui_ex.cpp.html</example>
</examples>
</component>
<!-- ************************************************************************* -->
</components>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>Change Log</title>
<body from_file="svnlog.txt">
<br/>
<center><a href="old_change_log.html">Old Change Logs</a></center>
<br/>
</body>
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>Change Log</title>
<body from_file="svnlog.txt">
<br/>
<center><a href="old_change_log.html">Old Change Logs</a></center>
<br/>
</body>
</doc>
The Table of Contents.hhc file is auto generated by the toc.xml and htmlhelp_stylesheet.xsl files.
You really can edit it if you want but I suggest you use the stylesheet to auto generate it instead.
If you want to regenerate the table of contents file you can do so with
The Table of Contents.hhc file is auto generated by the toc.xml and htmlhelp_stylesheet.xsl files.
You really can edit it if you want but I suggest you use the stylesheet to auto generate it instead.
If you want to regenerate the table of contents file you can do so with
the command "msxsl toc.xml htmlhelp_stylesheet.xsl" if you are using msxsl.exe.
\ No newline at end of file
<TITLE>dlib C++ library</TITLE>
<SCRIPT LANGUAGE="JavaScript"><!--
function redirect () { window.location.href = "docs/index.html"; }
//--></SCRIPT>
</HEAD>
<BODY onLoad="redirect()">
<p>
<a href="docs/index.html">click here to go to the documentation</a>
</p>
</BODY>
<TITLE>dlib C++ library</TITLE>
<SCRIPT LANGUAGE="JavaScript"><!--
function redirect () { window.location.href = "docs/index.html"; }
//--></SCRIPT>
</HEAD>
<BODY onLoad="redirect()">
<p>
<a href="docs/index.html">click here to go to the documentation</a>
</p>
</BODY>
</HTML>
\ No newline at end of file
<?xml version="1.0" encoding="ISO-8859-1" ?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method='html' version='1.0' encoding='UTF-8' indent='yes' />
<xsl:variable name="main_menu" select="/htmlhelp_toc/main_menu_file"/>
<xsl:variable name="docs" select="/htmlhelp_toc/docs_folder"/>
<xsl:variable name="show_include_file" select="/htmlhelp_toc/show_include_file"/>
<!-- ************************************************************************* -->
<xsl:variable name="lcletters">abcdefghijklmnopqrstuvwxyz </xsl:variable>
<xsl:variable name="ucletters">ABCDEFGHIJKLMNOPQRSTUVWXYZ </xsl:variable>
<!-- ************************************************************************* -->
<xsl:template match="/htmlhelp_toc">
<HTML>
<HEAD>
</HEAD><BODY>
<UL>
<xsl:apply-templates select="document($main_menu)/doc/menu"/>
</UL>
</BODY></HTML>
</xsl:template>
<!-- ************************************************************************* -->
<xsl:template match="section">
<xsl:param name="html_file" />
<xsl:param name="xml_file" />
<xsl:choose>
<xsl:when test="count(/doc/menu/top/section) != 1">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="{name}"/>
</OBJECT>
</LI>
<UL>
<xsl:for-each select="item">
<xsl:sort select="translate(concat(name,.),$lcletters, $ucletters)"/>
<xsl:apply-templates select=".">
<xsl:with-param name="xml_file" select="$xml_file"/>
<xsl:with-param name="html_file" select="$html_file"/>
</xsl:apply-templates>
</xsl:for-each>
</UL>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="item">
<xsl:sort select="translate(concat(name,.),$lcletters, $ucletters)"/>
<xsl:apply-templates select=".">
<xsl:with-param name="xml_file" select="$xml_file"/>
<xsl:with-param name="html_file" select="$html_file"/>
</xsl:apply-templates>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- ************************************************************************* -->
<xsl:template match="menu">
<xsl:param name="html_file" />
<xsl:param name="xml_file" />
<xsl:for-each select="top/section">
<xsl:apply-templates select=".">
<xsl:with-param name="xml_file" select="$xml_file"/>
<xsl:with-param name="html_file" select="$html_file"/>
</xsl:apply-templates>
</xsl:for-each>
</xsl:template>
<!-- ************************************************************************* -->
<xsl:template match="item">
<xsl:param name="html_file" />
<xsl:param name="xml_file" />
<xsl:choose>
<xsl:when test="name != ''">
<LI><OBJECT type="text/sitemap">
<param name="Name" value="{name}"/>
<xsl:choose>
<xsl:when test="link">
<param name="Local" value="{$docs}\{link}"/>
</xsl:when>
<xsl:when test="@nolink = 'true'">
</xsl:when>
<xsl:otherwise>
<param name="Local" value="{$docs}\{$html_file}#{name}"/>
</xsl:otherwise>
</xsl:choose>
</OBJECT>
</LI>
<xsl:choose>
<xsl:when test="sub">
<UL>
<xsl:for-each select="sub/item">
<xsl:sort select="translate(concat(name,.),$lcletters, $ucletters)"/>
<xsl:apply-templates select=".">
<xsl:with-param name="xml_file" select="$xml_file"/>
<xsl:with-param name="html_file" select="$html_file"/>
</xsl:apply-templates>
</xsl:for-each>
</UL>
</xsl:when>
<xsl:when test="chm_sub">
<UL>
<xsl:apply-templates select="document(chm_sub)/doc/menu">
<xsl:with-param name="xml_file" select="chm_sub"/>
<xsl:with-param name="html_file" select="link"/>
</xsl:apply-templates>
</UL>
</xsl:when>
</xsl:choose>
</xsl:when>
<xsl:when test="@nolink = 'true'">
</xsl:when>
<xsl:otherwise>
<LI><OBJECT type="text/sitemap">
<param name="Name" value="{.}"/>
<param name="Local" value="{$docs}\{$html_file}#{.}"/>
</OBJECT>
</LI>
<xsl:variable name="cname" select="."/>
<xsl:for-each select="document($xml_file)/doc/components/component">
<xsl:if test="name = $cname">
<UL>
<xsl:if test="spec_file">
<xsl:choose>
<xsl:when test="spec_file/@link = 'true'">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="specification"/>
<param name="Local" value="{$docs}\{spec_file}.html#{name}"/>
</OBJECT>
</LI>
</xsl:when>
<xsl:otherwise>
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="specification"/>
<param name="Local" value="{$docs}\{spec_file}.html"/>
</OBJECT>
</LI>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
<xsl:if test="$show_include_file = 'true'">
<xsl:if test="file">
<xsl:choose>
<xsl:when test="spec_file/@link = 'true' ">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="include file"/>
<param name="Local" value="{$docs}\{file}.html"/>
</OBJECT>
</LI>
</xsl:when>
<xsl:when test="spec_file != file">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="include file"/>
<param name="Local" value="{$docs}\{file}.html"/>
</OBJECT>
</LI>
</xsl:when>
</xsl:choose>
</xsl:if>
</xsl:if>
<xsl:if test="body_file">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="body"/>
<param name="Local" value="{$docs}\{body_file}.html#{name}"/>
</OBJECT>
</LI>
</xsl:if>
<xsl:if test="extensions">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="extensions"/>
</OBJECT>
</LI>
<UL>
<xsl:for-each select="extensions/extension">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="{name}"/>
<param name="Local" value="{$docs}\{spec_file}.html"/>
</OBJECT>
</LI>
</xsl:for-each>
</UL>
</xsl:if>
</UL>
</xsl:if>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- ************************************************************************* -->
<xsl:template match="sub">
<ul>
<xsl:for-each select="item">
<xsl:sort select="translate(concat(name,.),$lcletters, $ucletters)"/>
<xsl:apply-templates select="."/>
</xsl:for-each>
</ul>
</xsl:template>
<!-- ************************************************************************* -->
</xsl:stylesheet>
<?xml version="1.0" encoding="ISO-8859-1" ?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method='html' version='1.0' encoding='UTF-8' indent='yes' />
<xsl:variable name="main_menu" select="/htmlhelp_toc/main_menu_file"/>
<xsl:variable name="docs" select="/htmlhelp_toc/docs_folder"/>
<xsl:variable name="show_include_file" select="/htmlhelp_toc/show_include_file"/>
<!-- ************************************************************************* -->
<xsl:variable name="lcletters">abcdefghijklmnopqrstuvwxyz </xsl:variable>
<xsl:variable name="ucletters">ABCDEFGHIJKLMNOPQRSTUVWXYZ </xsl:variable>
<!-- ************************************************************************* -->
<xsl:template match="/htmlhelp_toc">
<HTML>
<HEAD>
</HEAD><BODY>
<UL>
<xsl:apply-templates select="document($main_menu)/doc/menu"/>
</UL>
</BODY></HTML>
</xsl:template>
<!-- ************************************************************************* -->
<xsl:template match="section">
<xsl:param name="html_file" />
<xsl:param name="xml_file" />
<xsl:choose>
<xsl:when test="count(/doc/menu/top/section) != 1">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="{name}"/>
</OBJECT>
</LI>
<UL>
<xsl:for-each select="item">
<xsl:sort select="translate(concat(name,.),$lcletters, $ucletters)"/>
<xsl:apply-templates select=".">
<xsl:with-param name="xml_file" select="$xml_file"/>
<xsl:with-param name="html_file" select="$html_file"/>
</xsl:apply-templates>
</xsl:for-each>
</UL>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="item">
<xsl:sort select="translate(concat(name,.),$lcletters, $ucletters)"/>
<xsl:apply-templates select=".">
<xsl:with-param name="xml_file" select="$xml_file"/>
<xsl:with-param name="html_file" select="$html_file"/>
</xsl:apply-templates>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- ************************************************************************* -->
<xsl:template match="menu">
<xsl:param name="html_file" />
<xsl:param name="xml_file" />
<xsl:for-each select="top/section">
<xsl:apply-templates select=".">
<xsl:with-param name="xml_file" select="$xml_file"/>
<xsl:with-param name="html_file" select="$html_file"/>
</xsl:apply-templates>
</xsl:for-each>
</xsl:template>
<!-- ************************************************************************* -->
<xsl:template match="item">
<xsl:param name="html_file" />
<xsl:param name="xml_file" />
<xsl:choose>
<xsl:when test="name != ''">
<LI><OBJECT type="text/sitemap">
<param name="Name" value="{name}"/>
<xsl:choose>
<xsl:when test="link">
<param name="Local" value="{$docs}\{link}"/>
</xsl:when>
<xsl:when test="@nolink = 'true'">
</xsl:when>
<xsl:otherwise>
<param name="Local" value="{$docs}\{$html_file}#{name}"/>
</xsl:otherwise>
</xsl:choose>
</OBJECT>
</LI>
<xsl:choose>
<xsl:when test="sub">
<UL>
<xsl:for-each select="sub/item">
<xsl:sort select="translate(concat(name,.),$lcletters, $ucletters)"/>
<xsl:apply-templates select=".">
<xsl:with-param name="xml_file" select="$xml_file"/>
<xsl:with-param name="html_file" select="$html_file"/>
</xsl:apply-templates>
</xsl:for-each>
</UL>
</xsl:when>
<xsl:when test="chm_sub">
<UL>
<xsl:apply-templates select="document(chm_sub)/doc/menu">
<xsl:with-param name="xml_file" select="chm_sub"/>
<xsl:with-param name="html_file" select="link"/>
</xsl:apply-templates>
</UL>
</xsl:when>
</xsl:choose>
</xsl:when>
<xsl:when test="@nolink = 'true'">
</xsl:when>
<xsl:otherwise>
<LI><OBJECT type="text/sitemap">
<param name="Name" value="{.}"/>
<param name="Local" value="{$docs}\{$html_file}#{.}"/>
</OBJECT>
</LI>
<xsl:variable name="cname" select="."/>
<xsl:for-each select="document($xml_file)/doc/components/component">
<xsl:if test="name = $cname">
<UL>
<xsl:if test="spec_file">
<xsl:choose>
<xsl:when test="spec_file/@link = 'true'">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="specification"/>
<param name="Local" value="{$docs}\{spec_file}.html#{name}"/>
</OBJECT>
</LI>
</xsl:when>
<xsl:otherwise>
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="specification"/>
<param name="Local" value="{$docs}\{spec_file}.html"/>
</OBJECT>
</LI>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
<xsl:if test="$show_include_file = 'true'">
<xsl:if test="file">
<xsl:choose>
<xsl:when test="spec_file/@link = 'true' ">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="include file"/>
<param name="Local" value="{$docs}\{file}.html"/>
</OBJECT>
</LI>
</xsl:when>
<xsl:when test="spec_file != file">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="include file"/>
<param name="Local" value="{$docs}\{file}.html"/>
</OBJECT>
</LI>
</xsl:when>
</xsl:choose>
</xsl:if>
</xsl:if>
<xsl:if test="body_file">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="body"/>
<param name="Local" value="{$docs}\{body_file}.html#{name}"/>
</OBJECT>
</LI>
</xsl:if>
<xsl:if test="extensions">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="extensions"/>
</OBJECT>
</LI>
<UL>
<xsl:for-each select="extensions/extension">
<LI> <OBJECT type="text/sitemap">
<param name="Name" value="{name}"/>
<param name="Local" value="{$docs}\{spec_file}.html"/>
</OBJECT>
</LI>
</xsl:for-each>
</UL>
</xsl:if>
</UL>
</xsl:if>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- ************************************************************************* -->
<xsl:template match="sub">
<ul>
<xsl:for-each select="item">
<xsl:sort select="translate(concat(name,.),$lcletters, $ucletters)"/>
<xsl:apply-templates select="."/>
</xsl:for-each>
</ul>
</xsl:template>
<!-- ************************************************************************* -->
</xsl:stylesheet>
[OPTIONS]
Binary TOC=Yes
Compatibility=1.1 or later
Compiled file=help.chm
Contents file=Table of Contents.hhc
Default topic=docs/index.html
Display compile progress=Yes
Full-text search=Yes
Language=0x409 English (United States)
Title=dLib
[FILES]
docs/api.html
docs/dlib/test/makefile
docs/right.gif
docs/down.gif
docs/plus.gif
docs/minus.gif
docs/change_log.html
docs/compile.html
docs/compress_stream_ex.cpp.html
docs/compression.html
docs/containers.html
docs/dir_nav_ex.cpp.html
docs/gui_api_ex.cpp.html
docs/index.html
docs/intro.html
docs/kernel_1a.html
docs/kernel_1b.html
docs/kernel_1c.html
docs/kernel_1da.html
docs/kernel_1db.html
docs/kernel_1ea.html
docs/kernel_1eb.html
docs/kernel_1ec.html
docs/kernel_2a.html
docs/kernel_3a.html
docs/kernel_3b.html
docs/license.html
docs/network.html
docs/other.html
docs/metaprogramming.html
docs/imaging.html
docs/parsing.html
docs/queue_ex.cpp.html
docs/release_notes.html
docs/old_release_notes.html
docs/sockets_ex.cpp.html
[INFOTYPES]
[OPTIONS]
Binary TOC=Yes
Compatibility=1.1 or later
Compiled file=help.chm
Contents file=Table of Contents.hhc
Default topic=docs/index.html
Display compile progress=Yes
Full-text search=Yes
Language=0x409 English (United States)
Title=dLib
[FILES]
docs/api.html
docs/dlib/test/makefile
docs/right.gif
docs/down.gif
docs/plus.gif
docs/minus.gif
docs/change_log.html
docs/compile.html
docs/compress_stream_ex.cpp.html
docs/compression.html
docs/containers.html
docs/dir_nav_ex.cpp.html
docs/gui_api_ex.cpp.html
docs/index.html
docs/intro.html
docs/kernel_1a.html
docs/kernel_1b.html
docs/kernel_1c.html
docs/kernel_1da.html
docs/kernel_1db.html
docs/kernel_1ea.html
docs/kernel_1eb.html
docs/kernel_1ec.html
docs/kernel_2a.html
docs/kernel_3a.html
docs/kernel_3b.html
docs/license.html
docs/network.html
docs/other.html
docs/metaprogramming.html
docs/imaging.html
docs/parsing.html
docs/queue_ex.cpp.html
docs/release_notes.html
docs/old_release_notes.html
docs/sockets_ex.cpp.html
[INFOTYPES]
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="htmlhelp_stylesheet.xsl"?>
<htmlhelp_toc>
<docs_folder>docs</docs_folder>
<main_menu_file>../main_menu.xml</main_menu_file>
<show_include_file>false</show_include_file>
</htmlhelp_toc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="htmlhelp_stylesheet.xsl"?>
<htmlhelp_toc>
<docs_folder>docs</docs_folder>
<main_menu_file>../main_menu.xml</main_menu_file>
<show_include_file>false</show_include_file>
</htmlhelp_toc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>How to compile</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<p>
To use this library all you have to do is extract the library somewhere, make sure the folder <i>containing</i>
the dlib folder is in your include path, and finally add <a href="dlib/all/source.cpp.html">dlib/all/source.cpp</a>
to your project.
</p>
<p>
An example makefile that uses this library can be found here:
<a href="dlib/test/makefile">dlib/test/makefile</a>. It is the makefile used to build the regression
test suite for this library. There is also a
<web> <a href="http://www.cmake.org">CMake</a> </web> <chm>CMake</chm> makefile that builds the
regression test suite at <a href="dlib/test/CMakeLists.txt.html">dlib/test/CMakeLists.txt</a> and another
CMake makefile that builds all the example programs at
<a href="examples/CMakeLists.txt.html">examples/CMakeLists.txt</a>
</p>
<p>
I try to make sure everything compiles fine under Visual Studio .NET 2003 (and above) and gcc. The compilers that will give you trouble are listed at the bottom of the page.
</p>
<p>
Again, note that you should <b><i>not</i></b> add the dlib folder itself to your compiler's include path.
Doing so will cause the
build to fail because of name collisions (such as dlib/string.h and string.h from the standard library).
Instead you should add the folder that contains the dlib folder to your include search path and then use
include statements of the form <tt>#include &lt;dlib/queue.h&gt;</tt>. This will ensure that everything
builds correctly.
</p>
<center><h1>Preprocessor Directives</h1></center>
<p>
There are a few preprocessor directives that you can supply during the build process to cause the
library to build in various optional ways. The most people will probably not want
to mess with these at all and just use the library in its default build. But they are listed
here in the event that you need to use them.
</p>
<anchor>DLIB_THREAD_POOL_TIMEOUT</anchor>
<h3>#define DLIB_ISO_CPP_ONLY</h3>
<p>
This is a #define directive that you can set to cause the library to exclude all non ISO C++ code (The things in the <a href="api.html">API wrappers</a> section and any objects that depend on those wrappers).
This is useful if you are trying to build on a system that isn't fully supported by the library or if you
just decide you don't want any of that stuff compiled into your program for your own reasons.
</p>
<anchor>DLIB_NO_GUI_SUPPORT</anchor>
<h3>#define DLIB_NO_GUI_SUPPORT</h3>
<p>
This is just like the DLIB_ISO_CPP_ONLY option except that it excludes only the GUI part of the library.
An example of when you might want to use this would be if you don't need GUI support and you are building
on a UNIX platform that doesn't have the X11 headers installed.
</p>
<anchor>NO_MAKEFILE</anchor>
<h3>#define NO_MAKEFILE</h3>
<p>
This preprocessor directive causes the dlib headers to pull in all the
code that would normally be built in dlib/all/source.cpp. Thus if you #define NO_MAKEFILE you won't
have to add dlib/all/source.cpp to your project. The <i>only</i> time this is useful is when your
project consists of a single translation unit (i.e. a single cpp file). In this instance NO_MAKEFILE
allows you to easily build your project on the command line by saying something like <tt>g++ -DNO_MAKEFILE
project.cpp</tt>. But again, this is only for single cpp file projects. If you use NO_MAKEFILE with projects
that contain more than one cpp file you will get linker errors about multiply defined symbols.
</p>
<p>
Also note that if you use this macro then the <a href="metaprogramming.html#DLIB_STACK_TRACE">stack trace</a>
functionality in the library will be disabled.
</p>
<anchor>DLIB_THREAD_POOL_TIMEOUT</anchor>
<h3>#define DLIB_THREAD_POOL_TIMEOUT &lt;time-in-milliseconds&gt;</h3>
<p>
If you use the <a href="dlib/threads/threads_kernel_abstract.h#create_new_thread">create_new_thread</a> function
to create your threads then you receive the benefit of the dlib thread pool. This pool enables the create_new_thread
function to spawn new threads very rapidly since it draws threads back out of its thread pool when the pool isn't
empty.
</p>
<p>
Thus, when a thread that was created by create_new_thread ends it actually goes back into the dlib thread pool
and waits DLIB_THREAD_POOL_TIMEOUT milliseconds before totally terminating and releasing its resources back
to the operating system. The default timeout used by this library is 30,000 milliseconds (30 seconds). You
may however change this to whatever you like by defining DLIB_THREAD_POOL_TIMEOUT to some new value.
</p>
<center><h1>Compilers</h1></center>
<h2>Visual Studio .NET 2003</h2>
<p>You need to link to one of the multithreaded C run-time libraries if you are using the threading stuff. You can do
this by setting it in the project options. If you don't you will get some error about _beginthreadex not linking.
</p>
<h2>Visual C++ toolkit 2003</h2>
<p>
This is a pretty good compiler and it is free. But it can be a major pain to use.
To get it working you have to download the platform sdk along with the toolkit itself.
both of these things are available from the microsoft web page for free.
</p>
<p>
Once you have the toolkit and platform sdk installed you should be ready to go.
Go to start -> programs -> microsoft visual c++ toolkit 2003 -> Visual C++ Toolkit 2003 Command Prompt. Then switch to the directory that contains your source and the dlib folder.
</p>
<p>
The following is the command I use and yours should look similar:
<tt>cl /O2 -DNO_MAKEFILE /EHsc /MT "%1"</tt> <br/>
The %1 should be replaced with the cpp file(s) you want to compile.
</p>
<p>
You may also have to tell the compiler where the include and lib folders are in the platform sdk.
If the above command doesn't work try this one (change paths appropriately for your system):
<tt>cl /O2 -DNO_MAKEFILE /EHsc /MT /I"C:\Program Files\Microsoft Platform SDK\Include" "%1" /link /LIBPATH:"C:\Program Files\Microsoft Platform SDK\Lib\" </tt>
</p>
<h2>gcc</h2>
<p>
I generally use gcc version 4.1 but most other versions of gcc work just fine also (except 2.95, see below).
</p>
<p>
The command line I generally use is "g++ -D NO_MAKEFILE -lnsl -lpthread file.cpp" I think you need to
tell it to link nsl to make the threading stuff work right, I honestly can't remember what part of
the library requires it I have just been doing it for so long :)
</p>
<p>
If you are using the sockets stuff then on some platforms you need to supply the -lsocket option. Or if you are using the gui stuff you will need to supply the -lX11 option.
</p>
<p>
If you compile on solaris you have to give the -lsocket
option if you use the sockets API.
</p>
<h2>gcc on windows</h2>
<p>
The commands for gcc on windows are the same as above but you may also have to link (via the -l option) to the following libraries: gdi32, comctl32, user32, ws2_32, or imm32.
</p>
<center><h1>Problem Compilers</h1></center>
<p>
Below is a list of the problems I can remember with various compilers. All the problems here are
bugs in the compiler and are a pain to write workarounds for (or the workarounds are slow/unsatisfactory) so I have no plans to deal with them. Just avoid these compilers in the
given situations.
</p>
<li/> <b> Visual Studio .NET and earlier versions </b>
<ul>
These compilers don't compile standard C++ very well. Visual Studio 6
doesn't even make any pretenses about being standards compliant. Visual Studio .NET is a lot
better but has some bugs with how it implements namespace lookups so most of my code will not
compile in Visual Studio .NET. (Note that Visual Studio .NET <I>2003</I> works just fine)
</ul>
<li/> <b> gcc 2.95 </b>
<ul>
<p>
The dir_nav component will not be able to list directories that contain files bigger than 4GB because
I had to use stat() rather than stat64() when compiling under this compiler.
</p>
<p>
There are also some other problems with gcc 2.95.
I believe all the containers work and all the API wrappers
but the GUI stuff works. It is sort of touch and go though.
</p>
</ul>
</body>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>How to compile</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<p>
To use this library all you have to do is extract the library somewhere, make sure the folder <i>containing</i>
the dlib folder is in your include path, and finally add <a href="dlib/all/source.cpp.html">dlib/all/source.cpp</a>
to your project.
</p>
<p>
An example makefile that uses this library can be found here:
<a href="dlib/test/makefile">dlib/test/makefile</a>. It is the makefile used to build the regression
test suite for this library. There is also a
<web> <a href="http://www.cmake.org">CMake</a> </web> <chm>CMake</chm> makefile that builds the
regression test suite at <a href="dlib/test/CMakeLists.txt.html">dlib/test/CMakeLists.txt</a> and another
CMake makefile that builds all the example programs at
<a href="examples/CMakeLists.txt.html">examples/CMakeLists.txt</a>
</p>
<p>
I try to make sure everything compiles fine under Visual Studio .NET 2003 (and above) and gcc. The compilers that will give you trouble are listed at the bottom of the page.
</p>
<p>
Again, note that you should <b><i>not</i></b> add the dlib folder itself to your compiler's include path.
Doing so will cause the
build to fail because of name collisions (such as dlib/string.h and string.h from the standard library).
Instead you should add the folder that contains the dlib folder to your include search path and then use
include statements of the form <tt>#include &lt;dlib/queue.h&gt;</tt>. This will ensure that everything
builds correctly.
</p>
<center><h1>Preprocessor Directives</h1></center>
<p>
There are a few preprocessor directives that you can supply during the build process to cause the
library to build in various optional ways. The most people will probably not want
to mess with these at all and just use the library in its default build. But they are listed
here in the event that you need to use them.
</p>
<anchor>DLIB_THREAD_POOL_TIMEOUT</anchor>
<h3>#define DLIB_ISO_CPP_ONLY</h3>
<p>
This is a #define directive that you can set to cause the library to exclude all non ISO C++ code (The things in the <a href="api.html">API wrappers</a> section and any objects that depend on those wrappers).
This is useful if you are trying to build on a system that isn't fully supported by the library or if you
just decide you don't want any of that stuff compiled into your program for your own reasons.
</p>
<anchor>DLIB_NO_GUI_SUPPORT</anchor>
<h3>#define DLIB_NO_GUI_SUPPORT</h3>
<p>
This is just like the DLIB_ISO_CPP_ONLY option except that it excludes only the GUI part of the library.
An example of when you might want to use this would be if you don't need GUI support and you are building
on a UNIX platform that doesn't have the X11 headers installed.
</p>
<anchor>NO_MAKEFILE</anchor>
<h3>#define NO_MAKEFILE</h3>
<p>
This preprocessor directive causes the dlib headers to pull in all the
code that would normally be built in dlib/all/source.cpp. Thus if you #define NO_MAKEFILE you won't
have to add dlib/all/source.cpp to your project. The <i>only</i> time this is useful is when your
project consists of a single translation unit (i.e. a single cpp file). In this instance NO_MAKEFILE
allows you to easily build your project on the command line by saying something like <tt>g++ -DNO_MAKEFILE
project.cpp</tt>. But again, this is only for single cpp file projects. If you use NO_MAKEFILE with projects
that contain more than one cpp file you will get linker errors about multiply defined symbols.
</p>
<p>
Also note that if you use this macro then the <a href="metaprogramming.html#DLIB_STACK_TRACE">stack trace</a>
functionality in the library will be disabled.
</p>
<anchor>DLIB_THREAD_POOL_TIMEOUT</anchor>
<h3>#define DLIB_THREAD_POOL_TIMEOUT &lt;time-in-milliseconds&gt;</h3>
<p>
If you use the <a href="dlib/threads/threads_kernel_abstract.h#create_new_thread">create_new_thread</a> function
to create your threads then you receive the benefit of the dlib thread pool. This pool enables the create_new_thread
function to spawn new threads very rapidly since it draws threads back out of its thread pool when the pool isn't
empty.
</p>
<p>
Thus, when a thread that was created by create_new_thread ends it actually goes back into the dlib thread pool
and waits DLIB_THREAD_POOL_TIMEOUT milliseconds before totally terminating and releasing its resources back
to the operating system. The default timeout used by this library is 30,000 milliseconds (30 seconds). You
may however change this to whatever you like by defining DLIB_THREAD_POOL_TIMEOUT to some new value.
</p>
<center><h1>Compilers</h1></center>
<h2>Visual Studio .NET 2003</h2>
<p>You need to link to one of the multithreaded C run-time libraries if you are using the threading stuff. You can do
this by setting it in the project options. If you don't you will get some error about _beginthreadex not linking.
</p>
<h2>Visual C++ toolkit 2003</h2>
<p>
This is a pretty good compiler and it is free. But it can be a major pain to use.
To get it working you have to download the platform sdk along with the toolkit itself.
both of these things are available from the microsoft web page for free.
</p>
<p>
Once you have the toolkit and platform sdk installed you should be ready to go.
Go to start -> programs -> microsoft visual c++ toolkit 2003 -> Visual C++ Toolkit 2003 Command Prompt. Then switch to the directory that contains your source and the dlib folder.
</p>
<p>
The following is the command I use and yours should look similar:
<tt>cl /O2 -DNO_MAKEFILE /EHsc /MT "%1"</tt> <br/>
The %1 should be replaced with the cpp file(s) you want to compile.
</p>
<p>
You may also have to tell the compiler where the include and lib folders are in the platform sdk.
If the above command doesn't work try this one (change paths appropriately for your system):
<tt>cl /O2 -DNO_MAKEFILE /EHsc /MT /I"C:\Program Files\Microsoft Platform SDK\Include" "%1" /link /LIBPATH:"C:\Program Files\Microsoft Platform SDK\Lib\" </tt>
</p>
<h2>gcc</h2>
<p>
I generally use gcc version 4.1 but most other versions of gcc work just fine also (except 2.95, see below).
</p>
<p>
The command line I generally use is "g++ -D NO_MAKEFILE -lnsl -lpthread file.cpp" I think you need to
tell it to link nsl to make the threading stuff work right, I honestly can't remember what part of
the library requires it I have just been doing it for so long :)
</p>
<p>
If you are using the sockets stuff then on some platforms you need to supply the -lsocket option. Or if you are using the gui stuff you will need to supply the -lX11 option.
</p>
<p>
If you compile on solaris you have to give the -lsocket
option if you use the sockets API.
</p>
<h2>gcc on windows</h2>
<p>
The commands for gcc on windows are the same as above but you may also have to link (via the -l option) to the following libraries: gdi32, comctl32, user32, ws2_32, or imm32.
</p>
<center><h1>Problem Compilers</h1></center>
<p>
Below is a list of the problems I can remember with various compilers. All the problems here are
bugs in the compiler and are a pain to write workarounds for (or the workarounds are slow/unsatisfactory) so I have no plans to deal with them. Just avoid these compilers in the
given situations.
</p>
<li/> <b> Visual Studio .NET and earlier versions </b>
<ul>
These compilers don't compile standard C++ very well. Visual Studio 6
doesn't even make any pretenses about being standards compliant. Visual Studio .NET is a lot
better but has some bugs with how it implements namespace lookups so most of my code will not
compile in Visual Studio .NET. (Note that Visual Studio .NET <I>2003</I> works just fine)
</ul>
<li/> <b> gcc 2.95 </b>
<ul>
<p>
The dir_nav component will not be able to list directories that contain files bigger than 4GB because
I had to use stat() rather than stat64() when compiling under this compiler.
</p>
<p>
There are also some other problems with gcc 2.95.
I believe all the containers work and all the API wrappers
but the GUI stuff works. It is sort of touch and go though.
</p>
</ul>
</body>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>Data Compression</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<p>
This page contains a bunch of objects that implement various parts of compression algorithms.
They can be put together in different ways to construct many different algorithms.
Note that the <a href="#compress_stream">compress_stream</a> object contains complete compression algorithms. So if you
just want to compress some data then you can easily use that object and not bother with the others.
</p>
<p>
In the column to the right you can see benchmark data for each of the compress_stream
typedefs. The times measured are the time it takes to compress and then
decompress each file. It was run on a 3.0ghz P4. For reference see the Canterbury corpus
<a href="http://corpus.canterbury.ac.nz/">web site</a>.
</p>
</body>
<!-- ************************************************************************* -->
<menu width="200">
<top>
<section>
<name>Objects</name>
<item>compress_stream</item>
<item>conditioning_class</item>
<item>entropy_decoder</item>
<item>entropy_encoder</item>
<item>entropy_decoder_model</item>
<item>entropy_encoder_model</item>
<item>lz77_buffer</item>
<item>lzp_buffer</item>
</section>
<section>
<name>Benchmarks</name>
<item>
<name>kernel_1a</name>
<link>kernel_1a.html</link>
</item>
<item>
<name>kernel_1b</name>
<link>kernel_1b.html</link>
</item>
<item>
<name>kernel_1c</name>
<link>kernel_1c.html</link>
</item>
<item>
<name>kernel_1da</name>
<link>kernel_1da.html</link>
</item>
<item>
<name>kernel_1db</name>
<link>kernel_1db.html</link>
</item>
<item>
<name>kernel_1ea</name>
<link>kernel_1ea.html</link>
</item>
<item>
<name>kernel_1eb</name>
<link>kernel_1eb.html</link>
</item>
<item>
<name>kernel_1ec</name>
<link>kernel_1ec.html</link>
</item>
<item>
<name>kernel_2a</name>
<link>kernel_2a.html</link>
</item>
<item>
<name>kernel_3a</name>
<link>kernel_3a.html</link>
</item>
<item>
<name>kernel_3b</name>
<link>kernel_3b.html</link>
</item>
</section>
</top>
</menu>
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<components>
<!-- ************************************************************************* -->
<component>
<name>compress_stream</name>
<file>dlib/compress_stream.h</file>
<spec_file>dlib/compress_stream/compress_stream_kernel_abstract.h</spec_file>
<description>
This object is pretty straight forward. It has no state and just
contains the functions compress and decompress.
They do just what their names imply to iostream objects.
</description>
<examples>
<example>compress_stream_ex.cpp.html</example>
<example>file_to_code_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>compress_stream_kernel_1</name>
<file>dlib/compress_stream/compress_stream_kernel_1.h</file>
<description>
This implementation is done using the <a href="#entropy_encoder_model">entropy_encoder_model</a> and
<a href="#entropy_decoder_model">entropy_decoder_model</a> objects.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_1b and entropy_decoder_model_kernel_1b</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_2b and entropy_decoder_model_kernel_2b </description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_3b and entropy_decoder_model_kernel_3b </description>
</typedef>
<typedef>
<name>kernel_1da</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_4a and entropy_decoder_model_kernel_4a </description>
</typedef>
<typedef>
<name>kernel_1db</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_4b and entropy_decoder_model_kernel_4b </description>
</typedef>
<typedef>
<name>kernel_1ea</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_5a and entropy_decoder_model_kernel_5a </description>
</typedef>
<typedef>
<name>kernel_1eb</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_5b and entropy_decoder_model_kernel_5b </description>
</typedef>
<typedef>
<name>kernel_1ec</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_5c and entropy_decoder_model_kernel_5c </description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>compress_stream_kernel_2</name>
<file>dlib/compress_stream/compress_stream_kernel_2.h</file>
<description>
This implementation is done using the <a href="#entropy_encoder_model">entropy_encoder_model</a> and
<a href="#entropy_decoder_model">entropy_decoder_model</a> objects. It also uses the
<a href="#lz77_buffer">lz77_buffer</a> object. It uses the entropy coder models to
encode symbols when there is no match found by the lz77_buffer.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for compress_stream_kernel_2 which uses entropy_encoder_model_kernel_2b, entropy_decoder_model_kernel_2b, and lz77_buffer_kernel_2a.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>compress_stream_kernel_3</name>
<file>dlib/compress_stream/compress_stream_kernel_3.h</file>
<description>
This implementation is done using the the <a href="#lzp_buffer">lzp_buffer</a> object and
<a href="other.html#crc32">crc32</a> object. It does not use any sort of entropy coding, instead
a byte aligned output method is used.
</description>
<typedefs>
<typedef>
<name>kernel_3a</name>
<description>is a typedef for compress_stream_kernel_3 which uses lzp_buffer_kernel_1.</description>
</typedef>
<typedef>
<name>kernel_3b</name>
<description>is a typedef for compress_stream_kernel_3 which uses lzp_buffer_kernel_2.</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>conditioning_class</name>
<file>dlib/conditioning_class.h</file>
<spec_file>dlib/conditioning_class/conditioning_class_kernel_abstract.h</spec_file>
<description>
This object represents a conditioning class used for arithmetic style
compression. It maintains the cumulative counts which are needed
by the entropy_encoder and entropy_decoder objects below.
</description>
<implementations>
<implementation>
<name>conditioning_class_kernel_1</name>
<file>dlib/conditioning_class/conditioning_class_kernel_1.h</file>
<description>
This implementation is done using an array to store all the counts and they are summed
whenever the cumulative counts are requested. It's pretty straight forward.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for conditioning_class_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>conditioning_class_kernel_2</name>
<file>dlib/conditioning_class/conditioning_class_kernel_2.h</file>
<description>
This implementation is done using a binary tree where each node in the tree represents one symbol and
contains that symbols count and the sum of all the counts for the nodes to the left. This way
when you request a cumulative count it can be computed by visiting log n nodes where n is the
size of the alphabet.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for conditioning_class_kernel_2</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>conditioning_class_kernel_3</name>
<file>dlib/conditioning_class/conditioning_class_kernel_3.h</file>
<description>
This implementation is done using an array to store all the counts and they are
summed whenever the cumulative counts are requested. The counts are also kept in
semi-sorted order to speed up the calculation of the cumulative count.
</description>
<typedefs>
<typedef>
<name>kernel_3a</name>
<description>is a typedef for conditioning_class_kernel_3</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>conditioning_class_kernel_4</name>
<file>dlib/conditioning_class/conditioning_class_kernel_4.h</file>
<description>
This implementation is done using a linked list to store all the counts and they are
summed whenever the cumulative counts are requested. The counts are also kept in
semi-sorted order to speed up the calculation of the cumulative count. This implementation
also uses the <a href="other.html#memory_manager">memory_manager</a> component to create a
memory pool of linked list nodes. This implementation is especially useful for high order
contexts and/or very large and sparce alphabets.
</description>
<typedefs>
<typedef>
<name>kernel_4a</name>
<description>is a typedef for conditioning_class_kernel_4 with a memory pool of 10,000 nodes.</description>
</typedef>
<typedef>
<name>kernel_4b</name>
<description>is a typedef for conditioning_class_kernel_4 with a memory pool of 100,000 nodes.</description>
</typedef>
<typedef>
<name>kernel_4c</name>
<description>is a typedef for conditioning_class_kernel_4 with a memory pool of 1,000,000 nodes.</description>
</typedef>
<typedef>
<name>kernel_4d</name>
<description>is a typedef for conditioning_class_kernel_4 with a memory pool of 10,000,000 nodes.</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>entropy_decoder</name>
<file>dlib/entropy_decoder.h</file>
<spec_file>dlib/entropy_decoder/entropy_decoder_kernel_abstract.h</spec_file>
<description>
This object represents an entropy decoder. E.g. the decoding part of
an arithmetic coder.
</description>
<implementations>
<implementation>
<name>entropy_decoder_kernel_1</name>
<file>dlib/entropy_decoder/entropy_decoder_kernel_1.h</file>
<description>
This object is implemented using arithmetic coding and is done in the
straight forward way using integers and fixed precision math.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for entropy_decoder_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_kernel_2</name>
<file>dlib/entropy_decoder/entropy_decoder_kernel_2.h</file>
<description>
This object is implemented using "range" coding and is done
in the straight forward way using integers and fixed precision math.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for entropy_decoder_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>entropy_encoder</name>
<file>dlib/entropy_encoder.h</file>
<spec_file>dlib/entropy_encoder/entropy_encoder_kernel_abstract.h</spec_file>
<description>
This object represents an entropy encoder. E.g. the encoding part of
an arithmetic coder.
</description>
<implementations>
<implementation>
<name>entropy_encoder_kernel_1</name>
<file>dlib/entropy_encoder/entropy_encoder_kernel_1.h</file>
<description>
This object is implemented using arithmetic coding and is done in the
straight forward way using integers and fixed precision math.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for entropy_encoder_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_kernel_2</name>
<file>dlib/entropy_encoder/entropy_encoder_kernel_2.h</file>
<description>
This object is implemented using "range" coding and is done
in the straight forward way using integers and fixed precision math.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for entropy_encoder_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>entropy_decoder_model</name>
<file>dlib/entropy_decoder_model.h</file>
<spec_file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_abstract.h</spec_file>
<description>
This object represents some kind of statistical model. You
can use it to read symbols from an entropy_decoder and it will calculate
the cumulative counts/probabilities and manage contexts for you.
</description>
<implementations>
<implementation>
<name>entropy_decoder_model_kernel_1</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_1.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for entropy_decoder_model_kernel_1 that uses conditioning_class_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for entropy_decoder_model_kernel_1 that uses conditioning_class_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for entropy_decoder_model_kernel_1 that uses conditioning_class_kernel_3a</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_2</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_2.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-1-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for entropy_decoder_model_kernel_2 that uses conditioning_class_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_2b</name>
<description>is a typedef for entropy_decoder_model_kernel_2 that uses conditioning_class_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_2c</name>
<description>is a typedef for entropy_decoder_model_kernel_2 that uses conditioning_class_kernel_3a</description>
</typedef>
<typedef>
<name>kernel_2d</name>
<description>is a typedef for entropy_decoder_model_kernel_2 that uses conditioning_class_kernel_2a for its order-0
context and conditioning_class_kernel_4b for its order-1 context.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_3</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_3.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-2-1-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_3a</name>
<description> is a typedef for entropy_decoder_model_kernel_3 that uses conditioning_class_kernel_1a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
<typedef>
<name>kernel_3b</name>
<description> is a typedef for entropy_decoder_model_kernel_3 that uses conditioning_class_kernel_2a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
<typedef>
<name>kernel_3c</name>
<description> is a typedef for entropy_decoder_model_kernel_3 that uses conditioning_class_kernel_3a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_4</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_4.h</file>
<description>
This object is implemented using a variation of the PPM algorithm described by Alistair Moffat in his paper "Implementing
the PPM data compression scheme."
It provides template arguments to select the maximum order and maximum memory to use. For speed,
exclusions are not used. The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_4a</name>
<description> is a typedef for entropy_decoder_model_kernel_4 with the max order set to 4 and the max number
of nodes set to 200,000</description>
</typedef>
<typedef>
<name>kernel_4b</name>
<description> is a typedef for entropy_decoder_model_kernel_4 with the max order set to 5 and the max number
of nodes set to 1,000,000</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_5</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_5.h</file>
<description>
This object is implemented using a variation of the PPM algorithm described by Alistair Moffat in his paper "Implementing
the PPM data compression scheme."
It provides template arguments to select the maximum order and maximum memory to use. Exclusions are used. The escape method used is method D.
This implementation is very much like kernel_4 except it is tuned for higher compression rather than speed.
This also uses Dmitry Shkarin's Information Inheritance scheme.
</description>
<typedefs>
<typedef>
<name>kernel_5a</name>
<description> is a typedef for entropy_decoder_model_kernel_5 with the max order set to 4 and the max number
of nodes set to 200,000</description>
</typedef>
<typedef>
<name>kernel_5b</name>
<description> is a typedef for entropy_decoder_model_kernel_5 with the max order set to 5 and the max number
of nodes set to 1,000,000</description>
</typedef>
<typedef>
<name>kernel_5c</name>
<description> is a typedef for entropy_decoder_model_kernel_5 with the max order set to 7 and the max number
of nodes set to 2,500,000</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_6</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_6.h</file>
<description>
This object just assigns every symbol the same probability. I.e. it uses an <i>order-(-1)</i> model.
</description>
<typedefs>
<typedef>
<name>kernel_6a</name>
<description>is a typedef for entropy_decoder_model_kernel_6</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>entropy_encoder_model</name>
<file>dlib/entropy_encoder_model.h</file>
<spec_file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_abstract.h</spec_file>
<description>
This object represents some kind of statistical model. You
can use it to write symbols to an entropy_encoder and it will calculate
the cumulative counts/probabilities and manage contexts for you.
</description>
<implementations>
<implementation>
<name>entropy_encoder_model_kernel_1</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_1.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for entropy_encoder_model_kernel_1 that uses conditioning_class_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for entropy_encoder_model_kernel_1 that uses conditioning_class_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for entropy_encoder_model_kernel_1 that uses conditioning_class_kernel_3a</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_2</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_2.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-1-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for entropy_encoder_model_kernel_2 that uses conditioning_class_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_2b</name>
<description>is a typedef for entropy_encoder_model_kernel_2 that uses conditioning_class_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_2c</name>
<description>is a typedef for entropy_encoder_model_kernel_2 that uses conditioning_class_kernel_3a</description>
</typedef>
<typedef>
<name>kernel_2d</name>
<description>is a typedef for entropy_encoder_model_kernel_2 that uses conditioning_class_kernel_2a for its order-0
context and conditioning_class_kernel_4b for its order-1 context.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_3</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_3.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-2-1-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_3a</name>
<description> is a typedef for entropy_encoder_model_kernel_3 that uses conditioning_class_kernel_1a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
<typedef>
<name>kernel_3b</name>
<description> is a typedef for entropy_encoder_model_kernel_3 that uses conditioning_class_kernel_2a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
<typedef>
<name>kernel_3c</name>
<description> is a typedef for entropy_encoder_model_kernel_3 that uses conditioning_class_kernel_3a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_4</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_4.h</file>
<description>
This object is implemented using a variation of the PPM algorithm described by Alistair Moffat in his paper "Implementing
the PPM data compression scheme."
It provides template arguments to select the maximum order and maximum memory to use. For speed,
exclusions are not used. The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_4a</name>
<description> is a typedef for entropy_encoder_model_kernel_4 with the max order set to 4 and the max number
of nodes set to 200,000</description>
</typedef>
<typedef>
<name>kernel_4b</name>
<description> is a typedef for entropy_encoder_model_kernel_4 with the max order set to 5 and the max number
of nodes set to 1,000,000</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_5</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_5.h</file>
<description>
This object is implemented using a variation of the PPM algorithm described by Alistair Moffat in his paper "Implementing
the PPM data compression scheme."
It provides template arguments to select the maximum order and maximum memory to use. Exclusions are used. The escape method used is method D.
This implementation is very much like kernel_4 except it is tuned for higher compression rather than speed.
This also uses Dmitry Shkarin's Information Inheritance scheme.
</description>
<typedefs>
<typedef>
<name>kernel_5a</name>
<description> is a typedef for entropy_encoder_model_kernel_5 with the max order set to 4 and the max number
of nodes set to 200,000</description>
</typedef>
<typedef>
<name>kernel_5b</name>
<description> is a typedef for entropy_encoder_model_kernel_5 with the max order set to 5 and the max number
of nodes set to 1,000,000</description>
</typedef>
<typedef>
<name>kernel_5c</name>
<description> is a typedef for entropy_encoder_model_kernel_5 with the max order set to 7 and the max number
of nodes set to 2,500,000</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_6</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_6.h</file>
<description>
This object just assigns every symbol the same probability. I.e. it uses an <i>order-(-1)</i> model.
</description>
<typedefs>
<typedef>
<name>kernel_6a</name>
<description>is a typedef for entropy_encoder_model_kernel_6</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>lz77_buffer</name>
<file>dlib/lz77_buffer.h</file>
<spec_file>dlib/lz77_buffer/lz77_buffer_kernel_abstract.h</spec_file>
<description>
This object represents a pair of buffers (history and lookahead buffers)
used during lz77 style compression.
</description>
<implementations>
<implementation>
<name>lz77_buffer_kernel_1</name>
<file>dlib/lz77_buffer/lz77_buffer_kernel_1.h</file>
<description>
This object is implemented using the <a href="containers.html#sliding_buffer">sliding_buffer</a> and it
just does simple linear searches of the history buffer to find matches.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for lz77_buffer_kernel_1 that uses sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>lz77_buffer_kernel_2</name>
<file>dlib/lz77_buffer/lz77_buffer_kernel_2.h</file>
<description>
This object is implemented using the <a href="containers.html#sliding_buffer">sliding_buffer</a>. It
finds matches by using a hash table.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for lz77_buffer_kernel_2 that uses sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>lzp_buffer</name>
<file>dlib/lzp_buffer.h</file>
<spec_file>dlib/lzp_buffer/lzp_buffer_kernel_abstract.h</spec_file>
<description>
This object represents some varation on the LZP algorithm
described by Charles Bloom in his paper "LZP: a new data
compression algorithm"
</description>
<implementations>
<implementation>
<name>lzp_buffer_kernel_1</name>
<file>dlib/lzp_buffer/lzp_buffer_kernel_1.h</file>
<description>
This object is implemented using the <a href="containers.html#sliding_buffer">sliding_buffer</a> and uses
an order-3 model to predict matches.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for lzp_buffer_kernel_1 that uses sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>lzp_buffer_kernel_2</name>
<file>dlib/lzp_buffer/lzp_buffer_kernel_2.h</file>
<description>
This object is implemented using the <a href="containers.html#sliding_buffer">sliding_buffer</a> and uses
an order-5-4-3 model to predict matches.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for lzp_buffer_kernel_2 that uses sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
</components>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>Data Compression</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<p>
This page contains a bunch of objects that implement various parts of compression algorithms.
They can be put together in different ways to construct many different algorithms.
Note that the <a href="#compress_stream">compress_stream</a> object contains complete compression algorithms. So if you
just want to compress some data then you can easily use that object and not bother with the others.
</p>
<p>
In the column to the right you can see benchmark data for each of the compress_stream
typedefs. The times measured are the time it takes to compress and then
decompress each file. It was run on a 3.0ghz P4. For reference see the Canterbury corpus
<a href="http://corpus.canterbury.ac.nz/">web site</a>.
</p>
</body>
<!-- ************************************************************************* -->
<menu width="200">
<top>
<section>
<name>Objects</name>
<item>compress_stream</item>
<item>conditioning_class</item>
<item>entropy_decoder</item>
<item>entropy_encoder</item>
<item>entropy_decoder_model</item>
<item>entropy_encoder_model</item>
<item>lz77_buffer</item>
<item>lzp_buffer</item>
</section>
<section>
<name>Benchmarks</name>
<item>
<name>kernel_1a</name>
<link>kernel_1a.html</link>
</item>
<item>
<name>kernel_1b</name>
<link>kernel_1b.html</link>
</item>
<item>
<name>kernel_1c</name>
<link>kernel_1c.html</link>
</item>
<item>
<name>kernel_1da</name>
<link>kernel_1da.html</link>
</item>
<item>
<name>kernel_1db</name>
<link>kernel_1db.html</link>
</item>
<item>
<name>kernel_1ea</name>
<link>kernel_1ea.html</link>
</item>
<item>
<name>kernel_1eb</name>
<link>kernel_1eb.html</link>
</item>
<item>
<name>kernel_1ec</name>
<link>kernel_1ec.html</link>
</item>
<item>
<name>kernel_2a</name>
<link>kernel_2a.html</link>
</item>
<item>
<name>kernel_3a</name>
<link>kernel_3a.html</link>
</item>
<item>
<name>kernel_3b</name>
<link>kernel_3b.html</link>
</item>
</section>
</top>
</menu>
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<components>
<!-- ************************************************************************* -->
<component>
<name>compress_stream</name>
<file>dlib/compress_stream.h</file>
<spec_file>dlib/compress_stream/compress_stream_kernel_abstract.h</spec_file>
<description>
This object is pretty straight forward. It has no state and just
contains the functions compress and decompress.
They do just what their names imply to iostream objects.
</description>
<examples>
<example>compress_stream_ex.cpp.html</example>
<example>file_to_code_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>compress_stream_kernel_1</name>
<file>dlib/compress_stream/compress_stream_kernel_1.h</file>
<description>
This implementation is done using the <a href="#entropy_encoder_model">entropy_encoder_model</a> and
<a href="#entropy_decoder_model">entropy_decoder_model</a> objects.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_1b and entropy_decoder_model_kernel_1b</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_2b and entropy_decoder_model_kernel_2b </description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_3b and entropy_decoder_model_kernel_3b </description>
</typedef>
<typedef>
<name>kernel_1da</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_4a and entropy_decoder_model_kernel_4a </description>
</typedef>
<typedef>
<name>kernel_1db</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_4b and entropy_decoder_model_kernel_4b </description>
</typedef>
<typedef>
<name>kernel_1ea</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_5a and entropy_decoder_model_kernel_5a </description>
</typedef>
<typedef>
<name>kernel_1eb</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_5b and entropy_decoder_model_kernel_5b </description>
</typedef>
<typedef>
<name>kernel_1ec</name>
<description>is a typedef for compress_stream_kernel_1 which uses entropy_decoder_model_kernel_5c and entropy_decoder_model_kernel_5c </description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>compress_stream_kernel_2</name>
<file>dlib/compress_stream/compress_stream_kernel_2.h</file>
<description>
This implementation is done using the <a href="#entropy_encoder_model">entropy_encoder_model</a> and
<a href="#entropy_decoder_model">entropy_decoder_model</a> objects. It also uses the
<a href="#lz77_buffer">lz77_buffer</a> object. It uses the entropy coder models to
encode symbols when there is no match found by the lz77_buffer.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for compress_stream_kernel_2 which uses entropy_encoder_model_kernel_2b, entropy_decoder_model_kernel_2b, and lz77_buffer_kernel_2a.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>compress_stream_kernel_3</name>
<file>dlib/compress_stream/compress_stream_kernel_3.h</file>
<description>
This implementation is done using the the <a href="#lzp_buffer">lzp_buffer</a> object and
<a href="other.html#crc32">crc32</a> object. It does not use any sort of entropy coding, instead
a byte aligned output method is used.
</description>
<typedefs>
<typedef>
<name>kernel_3a</name>
<description>is a typedef for compress_stream_kernel_3 which uses lzp_buffer_kernel_1.</description>
</typedef>
<typedef>
<name>kernel_3b</name>
<description>is a typedef for compress_stream_kernel_3 which uses lzp_buffer_kernel_2.</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>conditioning_class</name>
<file>dlib/conditioning_class.h</file>
<spec_file>dlib/conditioning_class/conditioning_class_kernel_abstract.h</spec_file>
<description>
This object represents a conditioning class used for arithmetic style
compression. It maintains the cumulative counts which are needed
by the entropy_encoder and entropy_decoder objects below.
</description>
<implementations>
<implementation>
<name>conditioning_class_kernel_1</name>
<file>dlib/conditioning_class/conditioning_class_kernel_1.h</file>
<description>
This implementation is done using an array to store all the counts and they are summed
whenever the cumulative counts are requested. It's pretty straight forward.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for conditioning_class_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>conditioning_class_kernel_2</name>
<file>dlib/conditioning_class/conditioning_class_kernel_2.h</file>
<description>
This implementation is done using a binary tree where each node in the tree represents one symbol and
contains that symbols count and the sum of all the counts for the nodes to the left. This way
when you request a cumulative count it can be computed by visiting log n nodes where n is the
size of the alphabet.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for conditioning_class_kernel_2</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>conditioning_class_kernel_3</name>
<file>dlib/conditioning_class/conditioning_class_kernel_3.h</file>
<description>
This implementation is done using an array to store all the counts and they are
summed whenever the cumulative counts are requested. The counts are also kept in
semi-sorted order to speed up the calculation of the cumulative count.
</description>
<typedefs>
<typedef>
<name>kernel_3a</name>
<description>is a typedef for conditioning_class_kernel_3</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>conditioning_class_kernel_4</name>
<file>dlib/conditioning_class/conditioning_class_kernel_4.h</file>
<description>
This implementation is done using a linked list to store all the counts and they are
summed whenever the cumulative counts are requested. The counts are also kept in
semi-sorted order to speed up the calculation of the cumulative count. This implementation
also uses the <a href="other.html#memory_manager">memory_manager</a> component to create a
memory pool of linked list nodes. This implementation is especially useful for high order
contexts and/or very large and sparce alphabets.
</description>
<typedefs>
<typedef>
<name>kernel_4a</name>
<description>is a typedef for conditioning_class_kernel_4 with a memory pool of 10,000 nodes.</description>
</typedef>
<typedef>
<name>kernel_4b</name>
<description>is a typedef for conditioning_class_kernel_4 with a memory pool of 100,000 nodes.</description>
</typedef>
<typedef>
<name>kernel_4c</name>
<description>is a typedef for conditioning_class_kernel_4 with a memory pool of 1,000,000 nodes.</description>
</typedef>
<typedef>
<name>kernel_4d</name>
<description>is a typedef for conditioning_class_kernel_4 with a memory pool of 10,000,000 nodes.</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>entropy_decoder</name>
<file>dlib/entropy_decoder.h</file>
<spec_file>dlib/entropy_decoder/entropy_decoder_kernel_abstract.h</spec_file>
<description>
This object represents an entropy decoder. E.g. the decoding part of
an arithmetic coder.
</description>
<implementations>
<implementation>
<name>entropy_decoder_kernel_1</name>
<file>dlib/entropy_decoder/entropy_decoder_kernel_1.h</file>
<description>
This object is implemented using arithmetic coding and is done in the
straight forward way using integers and fixed precision math.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for entropy_decoder_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_kernel_2</name>
<file>dlib/entropy_decoder/entropy_decoder_kernel_2.h</file>
<description>
This object is implemented using "range" coding and is done
in the straight forward way using integers and fixed precision math.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for entropy_decoder_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>entropy_encoder</name>
<file>dlib/entropy_encoder.h</file>
<spec_file>dlib/entropy_encoder/entropy_encoder_kernel_abstract.h</spec_file>
<description>
This object represents an entropy encoder. E.g. the encoding part of
an arithmetic coder.
</description>
<implementations>
<implementation>
<name>entropy_encoder_kernel_1</name>
<file>dlib/entropy_encoder/entropy_encoder_kernel_1.h</file>
<description>
This object is implemented using arithmetic coding and is done in the
straight forward way using integers and fixed precision math.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for entropy_encoder_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_kernel_2</name>
<file>dlib/entropy_encoder/entropy_encoder_kernel_2.h</file>
<description>
This object is implemented using "range" coding and is done
in the straight forward way using integers and fixed precision math.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for entropy_encoder_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>entropy_decoder_model</name>
<file>dlib/entropy_decoder_model.h</file>
<spec_file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_abstract.h</spec_file>
<description>
This object represents some kind of statistical model. You
can use it to read symbols from an entropy_decoder and it will calculate
the cumulative counts/probabilities and manage contexts for you.
</description>
<implementations>
<implementation>
<name>entropy_decoder_model_kernel_1</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_1.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for entropy_decoder_model_kernel_1 that uses conditioning_class_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for entropy_decoder_model_kernel_1 that uses conditioning_class_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for entropy_decoder_model_kernel_1 that uses conditioning_class_kernel_3a</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_2</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_2.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-1-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for entropy_decoder_model_kernel_2 that uses conditioning_class_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_2b</name>
<description>is a typedef for entropy_decoder_model_kernel_2 that uses conditioning_class_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_2c</name>
<description>is a typedef for entropy_decoder_model_kernel_2 that uses conditioning_class_kernel_3a</description>
</typedef>
<typedef>
<name>kernel_2d</name>
<description>is a typedef for entropy_decoder_model_kernel_2 that uses conditioning_class_kernel_2a for its order-0
context and conditioning_class_kernel_4b for its order-1 context.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_3</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_3.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-2-1-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_3a</name>
<description> is a typedef for entropy_decoder_model_kernel_3 that uses conditioning_class_kernel_1a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
<typedef>
<name>kernel_3b</name>
<description> is a typedef for entropy_decoder_model_kernel_3 that uses conditioning_class_kernel_2a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
<typedef>
<name>kernel_3c</name>
<description> is a typedef for entropy_decoder_model_kernel_3 that uses conditioning_class_kernel_3a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_4</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_4.h</file>
<description>
This object is implemented using a variation of the PPM algorithm described by Alistair Moffat in his paper "Implementing
the PPM data compression scheme."
It provides template arguments to select the maximum order and maximum memory to use. For speed,
exclusions are not used. The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_4a</name>
<description> is a typedef for entropy_decoder_model_kernel_4 with the max order set to 4 and the max number
of nodes set to 200,000</description>
</typedef>
<typedef>
<name>kernel_4b</name>
<description> is a typedef for entropy_decoder_model_kernel_4 with the max order set to 5 and the max number
of nodes set to 1,000,000</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_5</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_5.h</file>
<description>
This object is implemented using a variation of the PPM algorithm described by Alistair Moffat in his paper "Implementing
the PPM data compression scheme."
It provides template arguments to select the maximum order and maximum memory to use. Exclusions are used. The escape method used is method D.
This implementation is very much like kernel_4 except it is tuned for higher compression rather than speed.
This also uses Dmitry Shkarin's Information Inheritance scheme.
</description>
<typedefs>
<typedef>
<name>kernel_5a</name>
<description> is a typedef for entropy_decoder_model_kernel_5 with the max order set to 4 and the max number
of nodes set to 200,000</description>
</typedef>
<typedef>
<name>kernel_5b</name>
<description> is a typedef for entropy_decoder_model_kernel_5 with the max order set to 5 and the max number
of nodes set to 1,000,000</description>
</typedef>
<typedef>
<name>kernel_5c</name>
<description> is a typedef for entropy_decoder_model_kernel_5 with the max order set to 7 and the max number
of nodes set to 2,500,000</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_decoder_model_kernel_6</name>
<file>dlib/entropy_decoder_model/entropy_decoder_model_kernel_6.h</file>
<description>
This object just assigns every symbol the same probability. I.e. it uses an <i>order-(-1)</i> model.
</description>
<typedefs>
<typedef>
<name>kernel_6a</name>
<description>is a typedef for entropy_decoder_model_kernel_6</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>entropy_encoder_model</name>
<file>dlib/entropy_encoder_model.h</file>
<spec_file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_abstract.h</spec_file>
<description>
This object represents some kind of statistical model. You
can use it to write symbols to an entropy_encoder and it will calculate
the cumulative counts/probabilities and manage contexts for you.
</description>
<implementations>
<implementation>
<name>entropy_encoder_model_kernel_1</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_1.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for entropy_encoder_model_kernel_1 that uses conditioning_class_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for entropy_encoder_model_kernel_1 that uses conditioning_class_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for entropy_encoder_model_kernel_1 that uses conditioning_class_kernel_3a</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_2</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_2.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-1-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for entropy_encoder_model_kernel_2 that uses conditioning_class_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_2b</name>
<description>is a typedef for entropy_encoder_model_kernel_2 that uses conditioning_class_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_2c</name>
<description>is a typedef for entropy_encoder_model_kernel_2 that uses conditioning_class_kernel_3a</description>
</typedef>
<typedef>
<name>kernel_2d</name>
<description>is a typedef for entropy_encoder_model_kernel_2 that uses conditioning_class_kernel_2a for its order-0
context and conditioning_class_kernel_4b for its order-1 context.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_3</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_3.h</file>
<description>
This object is implemented using the <a href="#conditioning_class">conditioning_class</a> component.
It implements an <i>order-2-1-0</i> finite context model and uses lazy exclusions and update exclusions.
The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_3a</name>
<description> is a typedef for entropy_encoder_model_kernel_3 that uses conditioning_class_kernel_1a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
<typedef>
<name>kernel_3b</name>
<description> is a typedef for entropy_encoder_model_kernel_3 that uses conditioning_class_kernel_2a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
<typedef>
<name>kernel_3c</name>
<description> is a typedef for entropy_encoder_model_kernel_3 that uses conditioning_class_kernel_3a for orders 0 and 1
and conditioning_class_kernel_4b for order-2.</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_4</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_4.h</file>
<description>
This object is implemented using a variation of the PPM algorithm described by Alistair Moffat in his paper "Implementing
the PPM data compression scheme."
It provides template arguments to select the maximum order and maximum memory to use. For speed,
exclusions are not used. The escape method used is method D.
</description>
<typedefs>
<typedef>
<name>kernel_4a</name>
<description> is a typedef for entropy_encoder_model_kernel_4 with the max order set to 4 and the max number
of nodes set to 200,000</description>
</typedef>
<typedef>
<name>kernel_4b</name>
<description> is a typedef for entropy_encoder_model_kernel_4 with the max order set to 5 and the max number
of nodes set to 1,000,000</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_5</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_5.h</file>
<description>
This object is implemented using a variation of the PPM algorithm described by Alistair Moffat in his paper "Implementing
the PPM data compression scheme."
It provides template arguments to select the maximum order and maximum memory to use. Exclusions are used. The escape method used is method D.
This implementation is very much like kernel_4 except it is tuned for higher compression rather than speed.
This also uses Dmitry Shkarin's Information Inheritance scheme.
</description>
<typedefs>
<typedef>
<name>kernel_5a</name>
<description> is a typedef for entropy_encoder_model_kernel_5 with the max order set to 4 and the max number
of nodes set to 200,000</description>
</typedef>
<typedef>
<name>kernel_5b</name>
<description> is a typedef for entropy_encoder_model_kernel_5 with the max order set to 5 and the max number
of nodes set to 1,000,000</description>
</typedef>
<typedef>
<name>kernel_5c</name>
<description> is a typedef for entropy_encoder_model_kernel_5 with the max order set to 7 and the max number
of nodes set to 2,500,000</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>entropy_encoder_model_kernel_6</name>
<file>dlib/entropy_encoder_model/entropy_encoder_model_kernel_6.h</file>
<description>
This object just assigns every symbol the same probability. I.e. it uses an <i>order-(-1)</i> model.
</description>
<typedefs>
<typedef>
<name>kernel_6a</name>
<description>is a typedef for entropy_encoder_model_kernel_6</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>lz77_buffer</name>
<file>dlib/lz77_buffer.h</file>
<spec_file>dlib/lz77_buffer/lz77_buffer_kernel_abstract.h</spec_file>
<description>
This object represents a pair of buffers (history and lookahead buffers)
used during lz77 style compression.
</description>
<implementations>
<implementation>
<name>lz77_buffer_kernel_1</name>
<file>dlib/lz77_buffer/lz77_buffer_kernel_1.h</file>
<description>
This object is implemented using the <a href="containers.html#sliding_buffer">sliding_buffer</a> and it
just does simple linear searches of the history buffer to find matches.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for lz77_buffer_kernel_1 that uses sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>lz77_buffer_kernel_2</name>
<file>dlib/lz77_buffer/lz77_buffer_kernel_2.h</file>
<description>
This object is implemented using the <a href="containers.html#sliding_buffer">sliding_buffer</a>. It
finds matches by using a hash table.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for lz77_buffer_kernel_2 that uses sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>lzp_buffer</name>
<file>dlib/lzp_buffer.h</file>
<spec_file>dlib/lzp_buffer/lzp_buffer_kernel_abstract.h</spec_file>
<description>
This object represents some varation on the LZP algorithm
described by Charles Bloom in his paper "LZP: a new data
compression algorithm"
</description>
<implementations>
<implementation>
<name>lzp_buffer_kernel_1</name>
<file>dlib/lzp_buffer/lzp_buffer_kernel_1.h</file>
<description>
This object is implemented using the <a href="containers.html#sliding_buffer">sliding_buffer</a> and uses
an order-3 model to predict matches.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for lzp_buffer_kernel_1 that uses sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>lzp_buffer_kernel_2</name>
<file>dlib/lzp_buffer/lzp_buffer_kernel_2.h</file>
<description>
This object is implemented using the <a href="containers.html#sliding_buffer">sliding_buffer</a> and uses
an order-5-4-3 model to predict matches.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for lzp_buffer_kernel_2 that uses sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
</components>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>Containers</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<p>
Many of these containers were inspired by the RESOLVE/C++ course sequence at Ohio State. As such, most of
the objects do not support copying in any form, only swapping is allowed. That is, when objects
are added or removed from any of these containers they are swapped in and out, not copied.
This allows you to do things like have containers of containers of containers without encountering the
overhead of the massive copying that would likely result if you did the same thing with the STL.
</p>
<p>
To use any of these containers all you need to do is #include the file indicated in the
short section about the component you would like to use. Then pick which implementation you
would like and typedef it to something nice. Here is an example of creating a typedef for
a set of integers using the first kernel implementation. <br/>
<tt>typedef dlib::set&lt;int&gt;::kernel_1a set_of_ints;</tt>
</p>
<p>
Note that it is assumed by these containers that swap() and operator&lt; do not throw. They
may not function correctly if this assumption is broken. Also note that the built in types (int, long,
char, etc...) and std::string will not cause operator&lt; or swap() to throw.
</p>
<p>
Note also that most of the containers inherit from the <a href="#enumerable">enumerable</a>
interface. Thus, all the member functions inherited from enumerable are defined
in the enumerable class and their documentation is not repeated in each
container's documentation. This includes the size() member function in each
container.
</p>
</body>
<!-- ************************************************************************* -->
<menu width="150">
<top>
<section>
<name>Objects</name>
<item>static_set</item>
<item>array</item>
<item>array2d</item>
<item>binary_search_tree</item>
<item>hash_map</item>
<item>hash_set</item>
<item>hash_table</item>
<item>directed_graph</item>
<item>graph</item>
<item>map</item>
<item>matrix</item>
<item>queue</item>
<item>reference_counter</item>
<item>sequence</item>
<item>set</item>
<item>stack</item>
<item>std_vector_c</item>
<item>static_map</item>
<item>sliding_buffer</item>
<item>tuple</item>
<item nolink="true">
<name>smart pointers</name>
<sub>
<item>scoped_ptr</item>
<item>shared_ptr</item>
<item>weak_ptr</item>
</sub>
</item>
</section>
<section>
<name>Interfaces</name>
<item>map_pair</item>
<item>enumerable</item>
<item>
<name>remover</name>
<sub>
<item>
<name>remover</name>
<link>dlib/interfaces/remover.h.html#remover</link>
</item>
<item>
<name>asc_remover</name>
<link>dlib/interfaces/remover.h.html#asc_remover</link>
</item>
<item>
<name>pair_remover</name>
<link>dlib/interfaces/remover.h.html#pair_remover</link>
</item>
<item>
<name>asc_pair_remover</name>
<link>dlib/interfaces/remover.h.html#asc_pair_remover</link>
</item>
</sub>
</item>
</section>
</top>
</menu>
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<components>
<component checked="true">
<name>array</name>
<file>dlib/array.h</file>
<spec_file>dlib/array/array_kernel_abstract.h</spec_file>
<description>
This object is just like a C style array and the accessor functions operate
in constant time.
</description>
<implementations>
<implementation>
<name>array_kernel_1</name>
<file>dlib/array/array_kernel_1.h</file>
<description>
This implementation is done using an array of pointers, each of which point to
small sections of the array. This implementation allows the array to use only
about as much memory as it needs at any given time.
It does not use the <a href="other.html#memory_manager">memory_manager</a> at all.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for array_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>array_kernel_2</name>
<file>dlib/array/array_kernel_2.h</file>
<description>
This implementation is done using a single array of max_size() elements. So this
is just a simple layer on top of a C style array.
It uses the <a href="other.html#memory_manager">memory_manager</a> for all
memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for array_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>array_sort</name>
<spec_file>dlib/array/array_sort_abstract.h</spec_file>
<description>
This extension gives an array the ability to sort its contents.
</description>
<implementations>
<implementation>
<name>array_sort_1</name>
<file>dlib/array/array_sort_1.h</file>
<description>
This is a version of the QuickSort algorithm. It swaps the entire array into a C
style array, sorts it and then swaps it back into the array object.
</description>
<typedefs>
<typedef>
<name>sort_1a</name>
<description>is a typedef for array_kernel_1a extended by array_sort_1</description>
</typedef>
<typedef>
<name>sort_1b</name>
<description>is a typedef for array_kernel_2a extended by array_sort_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>array_sort_2</name>
<file>dlib/array/array_sort_2.h</file>
<description>
This is a version of the QuickSort algorithm.
</description>
<typedefs>
<typedef>
<name>sort_2a</name>
<description>is a typedef for array_kernel_1a extended by array_sort_2</description>
</typedef>
<typedef>
<name>sort_2b</name>
<description>is a typedef for array_kernel_2a extended by array_sort_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
<extension>
<name>array_expand</name>
<spec_file>dlib/array/array_expand_abstract.h</spec_file>
<description>
This extension gives an array the ability to expand its size() beyond
its max_size() without clearing out all its elements. It also adds a set of pop/push_back()
functions similar to the ones in the std::vector object.
</description>
<implementations>
<implementation>
<name>array_expand_1</name>
<file>dlib/array/array_expand_1.h</file>
<description>
This is implemented by creating a new bigger array if max_size() isn't big enough,
swapping everything into that new array, and then swapping that array with *this.
</description>
<typedefs>
<typedef>
<name>expand_1a</name>
<description>is a typedef for array_sort_1a extended by array_expand_1</description>
</typedef>
<typedef>
<name>expand_1b</name>
<description>is a typedef for array_sort_1b extended by array_expand_1</description>
</typedef>
<typedef>
<name>expand_1c</name>
<description>is a typedef for array_sort_2a extended by array_expand_1</description>
</typedef>
<typedef>
<name>expand_1d</name>
<description>is a typedef for array_sort_2b extended by array_expand_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>sliding_buffer</name>
<file>dlib/sliding_buffer.h</file>
<spec_file>dlib/sliding_buffer/sliding_buffer_kernel_abstract.h</spec_file>
<description>
This object represents an array with the ability to rotate its contents
left or right.
</description>
<implementations>
<implementation>
<name>sliding_buffer_kernel_1</name>
<file>dlib/sliding_buffer/sliding_buffer_kernel_1.h</file>
<description>
This object is implemented using a C style array in the obvious way. See the code for details.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>array2d</name>
<file>dlib/array2d.h</file>
<spec_file>dlib/array2d/array2d_kernel_abstract.h</spec_file>
<description>
This object represents a 2-Dimensional array of objects.
</description>
<examples>
<example>image_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>array2d_kernel_1</name>
<file>dlib/array2d/array2d_kernel_1.h</file>
<description>
This is implemented in the obvious way. See the source for details.
It uses the <a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for array2d_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>binary_search_tree</name>
<file>dlib/binary_search_tree.h</file>
<spec_file>dlib/binary_search_tree/binary_search_tree_kernel_abstract.h</spec_file>
<description>
This object represents a data dictionary that is built on top of some kind of binary search tree.
</description>
<implementations>
<implementation>
<name>binary_search_tree_kernel_1</name>
<file>dlib/binary_search_tree/binary_search_tree_kernel_1.h</file>
<description>
This implementation is done using an AVL binary search tree. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for binary_search_tree_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>binary_search_tree_kernel_2</name>
<file>dlib/binary_search_tree/binary_search_tree_kernel_2.h</file>
<description>
This implementation is done using a red-black binary search tree. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for binary_search_tree_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>hash_map</name>
<file>dlib/hash_map.h</file>
<spec_file>dlib/hash_map/hash_map_kernel_abstract.h</spec_file>
<description>
This object represents a hashed mapping of items of type domain onto items of type range.
</description>
<implementations>
<implementation>
<name>hash_map_kernel_1</name>
<file>dlib/hash_map/hash_map_kernel_1.h</file>
<description>
This implementation is done using a <a href="#hash_table">hash_table</a> object. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for hash_map_kernel_1 that uses hash_table_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for hash_map_kernel_1 that uses hash_table_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for hash_map_kernel_1 that uses hash_table_kernel_2b</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>hash_set</name>
<file>dlib/hash_set.h</file>
<spec_file>dlib/hash_set/hash_set_kernel_abstract.h</spec_file>
<description>
This object represents a hashed unordered and unaddressed collection of unique items.
</description>
<implementations>
<implementation>
<name>hash_set_kernel_1</name>
<file>dlib/hash_set/hash_set_kernel_1.h</file>
<description>
This implementation is done using a <a href="#hash_table">hash_table</a> object. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for hash_set_kernel_1 that uses hash_table_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for hash_set_kernel_1 that uses hash_table_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for hash_set_kernel_1 that uses hash_table_kernel_2b</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>hash_table</name>
<file>dlib/hash_table.h</file>
<spec_file>dlib/hash_table/hash_table_kernel_abstract.h</spec_file>
<description>
This object represents a data dictionary that is built on top of some kind of
hash table.
</description>
<implementations>
<implementation>
<name>hash_table_kernel_1</name>
<file>dlib/hash_table/hash_table_kernel_1.h</file>
<description>
This implementation is done using singly linked lists as hashing buckets. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for hash_table_kernel_1. </description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>hash_table_kernel_2</name>
<file>dlib/hash_table/hash_table_kernel_2.h</file>
<description>
This implementation is done using <a href="#binary_search_tree">
binary_search_tree</a> objects as hashing buckets. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for hash_table_kernel_2 that uses binary_search_tree_kernel_1</description>
</typedef>
<typedef>
<name>kernel_2b</name>
<description>is a typedef for hash_table_kernel_2 that uses binary_search_tree_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>map</name>
<file>dlib/map.h</file>
<spec_file>dlib/map/map_kernel_abstract.h</spec_file>
<description>
This object represents a mapping of items of type domain onto items of type range.
</description>
<implementations>
<implementation>
<name>map_kernel_1</name>
<file>dlib/map/map_kernel_1.h</file>
<description>
This is implemented using the <a href="#binary_search_tree">binary_search_tree</a> component. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for map_kernel_1 that uses binary_search_tree_kernel_1</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for map_kernel_1 that uses binary_search_tree_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>enumerable</name>
<file>dlib/interfaces/enumerable.h</file>
<spec_file>dlib/interfaces/enumerable.h</spec_file>
<description>
This object is an abstract class which represents an interface for iterating over
all the elements of a container.
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>map_pair</name>
<file>dlib/interfaces/map_pair.h</file>
<spec_file>dlib/interfaces/map_pair.h</spec_file>
<description>
This object is an abstract class which represents an interface for accessing a
pair from a container such as the map, hash_table, etc...
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>remover</name>
<file>dlib/interfaces/remover.h</file>
<spec_file>dlib/interfaces/remover.h</spec_file>
<description>
This is a set of interfaces which gives the ability to remove all the items in a
container without actually knowing what kind of container contains them.
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>weak_ptr</name>
<file>dlib/smart_pointers.h</file>
<spec_file>dlib/smart_pointers/weak_ptr_abstract.h</spec_file>
<description>
<p>
The weak_ptr class template stores a weak reference to an object that is
already managed by a shared_ptr. To access the object, a weak_ptr can
be converted to a shared_ptr using the member function lock().
</p>
<p>
This is an implementation of the std::tr1::weak_ptr template from the
document ISO/IEC PDTR 19768, Proposed Draft Technical Report on C++
Library Extensions. The only deviation from that document is that this
shared_ptr is declared inside the dlib namespace rather than std::tr1.
</p>
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>shared_ptr</name>
<file>dlib/smart_pointers.h</file>
<spec_file>dlib/smart_pointers/shared_ptr_abstract.h</spec_file>
<description>
<p>
This object represents a reference counted smart pointer. Each shared_ptr
contains a pointer to some object and when the last shared_ptr that points
to the object is destructed or reset() then the object is guaranteed to be
deleted.
</p>
<p>
This is an implementation of the std::tr1::shared_ptr template from the
document ISO/IEC PDTR 19768, Proposed Draft Technical Report on C++
Library Extensions. The only deviation from that document is that this
shared_ptr is declared inside the dlib namespace rather than std::tr1.
</p>
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>tuple</name>
<file>dlib/tuple.h</file>
<spec_file>dlib/tuple/tuple_abstract.h</spec_file>
<description>
This is an implementation of a very simple templated container object.
It contains between 0 and 31 objects where each object is listed
explicity in the tuple's template arguments.
<p>
Note that there is only one implementation of this object so there aren't any
different kernels to choose from when you create instances of the matrix object.
So for example, you
could declare a tuple of 3 ints using the following statement:
<tt>dlib::tuple&lt;int,int,int&gt; t;</tt>
</p>
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>scoped_ptr</name>
<file>dlib/smart_pointers.h</file>
<spec_file>dlib/smart_pointers/scoped_ptr_abstract.h</spec_file>
<description>
This is a implementation of the scoped_ptr class found in the Boost C++
library. It is a simple smart pointer class which guarantees that the
pointer contained within it will always be deleted.
The class does not permit copying and so does not do any kind of
reference counting. Thus it is very simple and quite fast.
</description>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>graph</name>
<file>dlib/graph.h</file>
<spec_file>dlib/graph/graph_kernel_abstract.h</spec_file>
<description>
This object represents a graph which is a set of nodes with undirected
edges connecting various nodes.
</description>
<implementations>
<implementation>
<name>graph_kernel_1</name>
<file>dlib/graph/graph_kernel_1.h</file>
<description>
This is implemented using std::vector to contain all the nodes and edges.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for graph_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>directed_graph</name>
<file>dlib/directed_graph.h</file>
<spec_file>dlib/directed_graph/directed_graph_kernel_abstract.h</spec_file>
<description>
This object represents a directed graph which is a set of nodes with directed
edges connecting various nodes.
</description>
<implementations>
<implementation>
<name>directed_graph_kernel_1</name>
<file>dlib/directed_graph/directed_graph_kernel_1.h</file>
<description>
This is implemented using std::vector to contain all the nodes and edges.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for directed_graph_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>queue</name>
<file>dlib/queue.h</file>
<spec_file>dlib/queue/queue_kernel_abstract.h</spec_file>
<description>
This object represents a first in first out queue.
</description>
<examples>
<example>dir_nav_ex.cpp.html</example>
<example>queue_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>queue_kernel_1</name>
<file>dlib/queue/queue_kernel_1.h</file>
<description>
This is implemented in the obvious way using a singly linked list. It does not use the
<a href="other.html#memory_manager">memory_manager</a> at all.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for queue_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>queue_kernel_2</name>
<file>dlib/queue/queue_kernel_2.h</file>
<description>
This is implemented using a singly linked list and each node in the list
contains block_size (a template parameter) elements. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for queue_kernel_2 with a block_size of 20</description>
</typedef>
<typedef>
<name>kernel_2b</name>
<description>is a typedef for queue_kernel_2 with a block_size of 100</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>queue_sort</name>
<spec_file>dlib/queue/queue_sort_abstract.h</spec_file>
<description>
This extension gives a queue the ability to sort its contents.
</description>
<implementations>
<implementation>
<name>queue_sort_1</name>
<file>dlib/queue/queue_sort_1.h</file>
<description>
This is a version of the QuickSort algorithm.
</description>
<typedefs>
<typedef>
<name>sort_1a</name>
<description>is a typedef for queue_kernel_1a extended by queue_sort_1</description>
</typedef>
<typedef>
<name>sort_1b</name>
<description>is a typedef for queue_kernel_2a extended by queue_sort_1</description>
</typedef>
<typedef>
<name>sort_1c</name>
<description>is a typedef for queue_kernel_2b extended by queue_sort_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>reference_counter</name>
<file>dlib/reference_counter.h</file>
<spec_file>dlib/reference_counter/reference_counter_kernel_abstract.h</spec_file>
<description>
This object represents a container for an object and provides reference counting
capabilities for the object it contains.
</description>
<implementations>
<implementation>
<name>reference_counter_kernel_1</name>
<file>dlib/reference_counter/reference_counter_kernel_1.h</file>
<description>
This implementation is done using pointers in the obvious way.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for reference_counter_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>sequence</name>
<file>dlib/sequence.h</file>
<spec_file>dlib/sequence/sequence_kernel_abstract.h</spec_file>
<description>
This object represents an ordered sequence of items, each item is
associated with an integer value. The items are numbered from 0 to the number of items in the
sequence minus 1.
</description>
<implementations>
<implementation>
<name>sequence_kernel_1</name>
<file>dlib/sequence/sequence_kernel_1.h</file>
<description>
This is implemented as an AVL binary search tree.
Accessing(or adding or removing) an element always takes O(log n) time.
It uses the <a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for sequence_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>sequence_kernel_2</name>
<file>dlib/sequence/sequence_kernel_2.h</file>
<description>
This implementation is done using a doubly linked list in the shape of a ring.
It will remember the last element accessed(or added or removed) and give O(1)
access time to the elements just left and right of it. Aside from that,
accessing(or adding or removing) a random element will take O(n) and in the worst
case it will take time proportional to the size of the sequence/2.
<p>
It does not use the
<a href="other.html#memory_manager">memory_manager</a> at all.
</p>
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for sequence_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>sequence_sort</name>
<spec_file>dlib/sequence/sequence_sort_abstract.h</spec_file>
<description>
This extension gives a sequence the ability to sort its contents.
</description>
<implementations>
<implementation>
<name>sequence_sort_1</name>
<file>dlib/sequence/sequence_sort_1.h</file>
<description>
This is a version of the QuickSort algorithm and it sorts sequences of less
than 30 elements with a selection sort. This implementation is fastest when
used with sequence_kernel_2 and fairly slow when used with sequence_kernel_1
</description>
<typedefs>
<typedef>
<name>sort_1a</name>
<description>is a typedef for sequence_kernel_2a extended by sequence_sort_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>sequence_sort_2</name>
<file>dlib/sequence/sequence_sort_2.h</file>
<description>
This is a version of the QuickSort algorithm. This implementation of sort is
the best to use with sequence_kernel_1 objects but gives extremely poor performance
with sequence_kernel_2 objects.
</description>
<typedefs>
<typedef>
<name>sort_2a</name>
<description>is a typedef for sequence_kernel_1a extended by sequence_sort_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
<extension>
<name>sequence_compare</name>
<spec_file>dlib/sequence/sequence_compare_abstract.h</spec_file>
<description>
This extension gives sequences the ability to compare themselves using
operator&lt; and operator==. Thus they can be used in the other container classes
that require this ability. (maps, sets, etc...)
</description>
<implementations>
<implementation>
<name>sequence_compare_1</name>
<file>dlib/sequence/sequence_compare_1.h</file>
<description>
The implementation is obvious. Click on the sequence_compare_1 link if you want to see.
</description>
<typedefs>
<typedef>
<name>compare_1a</name>
<description>is a typedef for sequence_kernel_1a extended by sequence_compare_1</description>
</typedef>
<typedef>
<name>compare_1b</name>
<description>is a typedef for sequence_kernel_2a extended by sequence_compare_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>set</name>
<file>dlib/set.h</file>
<spec_file>dlib/set/set_kernel_abstract.h</spec_file>
<description>
This object represents an unordered and unaddressed collection of unique items.
</description>
<implementations>
<implementation>
<name>set_kernel_1</name>
<file>dlib/set/set_kernel_1.h</file>
<description>
This is implemented using the <a href="#binary_search_tree">binary_search_tree</a> component. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for set_kernel_1 that uses binary_search_tree_kernel_1</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for set_kernel_1 that uses binary_search_tree_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>set_compare</name>
<spec_file>dlib/set/set_compare_abstract.h</spec_file>
<description>
This extension gives sets the ability to compare themselves using operator&lt; and
operator==. Thus they can be used in the other container classes that require
this ability. (maps, sets, etc...)
</description>
<implementations>
<implementation>
<name>set_compare_1</name>
<file>dlib/set/set_compare_1.h</file>
<description>
The implementation is obvious. Click on the set_compare_1 link if you want to see.
</description>
<typedefs>
<typedef>
<name>compare_1a</name>
<description>is a typedef for set_kernel_1a extended by set_compare_1</description>
</typedef>
<typedef>
<name>compare_1b</name>
<description>is a typedef for set_kernel_1b extended by set_compare_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>stack</name>
<file>dlib/stack.h</file>
<spec_file>dlib/stack/stack_kernel_abstract.h</spec_file>
<description>
This object represents a last in first out stack.
</description>
<implementations>
<implementation>
<name>stack_kernel_1</name>
<file>dlib/stack/stack_kernel_1.h</file>
<description>
This implementation is done in the obvious way using a singly linked list. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for stack_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>static_map</name>
<file>dlib/static_map.h</file>
<spec_file>dlib/static_map/static_map_kernel_abstract.h</spec_file>
<description>
This object represents a mapping of items of type domain onto items of type range.
The difference between this object and the normal <a href="#map">map</a> object is that it does not support adding
or removing individual objects from itself. This allows implementations to focus on using less memory and
achieving faster searching.
</description>
<implementations>
<implementation>
<name>static_map_kernel_1</name>
<file>dlib/static_map/static_map_kernel_1.h</file>
<description>
This implementation is just a sorted array which can be searched using a binary search.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for static_map_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>static_set</name>
<file>dlib/static_set.h</file>
<spec_file>dlib/static_set/static_set_kernel_abstract.h</spec_file>
<description>
This object represents an unordered and unaddressed collection of items.
The difference between this object and the normal <a href="#set">set</a> object is that it does not support adding
or removing individual objects from itself. This allows implementations to focus on using less memory and
achieving faster searching.
</description>
<examples>
<example>dir_nav_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>static_set_kernel_1</name>
<file>dlib/static_set/static_set_kernel_1.h</file>
<description>
This implementation is just a sorted array which can be searched using a binary search.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for static_set_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>static_set_compare</name>
<spec_file>dlib/static_set/static_set_compare_abstract.h</spec_file>
<description>
This extension gives static_sets the ability to compare themselves using operator&lt; and
operator==. Thus they can be used in the other container classes that require
this ability. (maps, static_sets, etc...)
</description>
<implementations>
<implementation>
<name>static_set_compare_1</name>
<file>dlib/static_set/static_set_compare_1.h</file>
<description>
The implementation is obvious. Click on the static_set_compare_1 link if you want to see.
</description>
<typedefs>
<typedef>
<name>compare_1a</name>
<description>is a typedef for static_set_kernel_1a extended by static_set_compare_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>matrix</name>
<file>dlib/matrix.h</file>
<spec_file link="true">dlib/matrix/matrix_abstract.h</spec_file>
<description>
This is a 2D matrix object. It is implemented using the expression templates
technique which allows us to eliminate the temporary matrix objects that would
normally be returned from expressions such as M = A+B+C+D; Normally each
invocation of the + operator would construct and return a temporary matrix
object but using this technique we can avoid creating all of these temporary
objects and receive a large speed boost.
<p>
Note that there is only one implementation of this object so there aren't any
different kernels to choose from when you create instances of the matrix object.
So for example, you
could declare a matrix of 2 rows and 3 columns using the following statement:
<tt>dlib::matrix&lt;float,2,3&gt; m;</tt>
</p>
<p>
It should also be noted that matrix multiplication is fastest when the two matrices
being multiplied are not complex matrix_exp objects returned from other expressions
(such as other matrix multiplies). This is because the matrix multiply operator will
evaluate each element of the matrices it is multiplying many times, and a matrix_exp
computes its elements' values each time they are queried. However, the matrix multiply
operator is the only one that evaluates its argument's elements multiple times so you can
stack up all the other operators however you want without any performance penalty. If
you want to multiply two complex matrix_exp expressions together you can easily convert them into
fully evaluated temporary matrix objects by using the tmp() function. For example, to
multiply four matrices together you should use an expression such as <tt>result = tmp(a*b)*tmp(c*d);</tt>
</p>
</description>
<examples>
<example>matrix_ex.cpp.html</example>
</examples>
<extensions>
<extension>
<name>matrix_utilities</name>
<spec_file>dlib/matrix/matrix_utilities_abstract.h</spec_file>
<description>This extension contains miscellaneous utility functions
for manipulating matrix objects. Note that you don't need to #include
anything to get them. They are included by the <a href="dlib/matrix.h.html">dlib/matrix.h</a> file for you.
</description>
</extension>
<extension>
<name>matrix_math_functions</name>
<spec_file>dlib/matrix/matrix_math_functions_abstract.h</spec_file>
<description>This extension contains mathematical functions that operate on each
element of a matrix independently. Note that you don't need to #include
anything to get them. They are included by the <a href="dlib/matrix.h.html">dlib/matrix.h</a> file for you.
</description>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>std_vector_c</name>
<file>dlib/stl_checked.h</file>
<spec_file link="true">dlib/stl_checked/std_vector_c_abstract.h</spec_file>
<description>
This object is a simple wrapper around the std::vector object. It
provides an identical interface but also checks the preconditions of
each member function. That is, if you violate a requires
clause the dlib::fatal_error exception is thrown.
</description>
</component>
<!-- ************************************************************************* -->
</components>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>Containers</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<p>
Many of these containers were inspired by the RESOLVE/C++ course sequence at Ohio State. As such, most of
the objects do not support copying in any form, only swapping is allowed. That is, when objects
are added or removed from any of these containers they are swapped in and out, not copied.
This allows you to do things like have containers of containers of containers without encountering the
overhead of the massive copying that would likely result if you did the same thing with the STL.
</p>
<p>
To use any of these containers all you need to do is #include the file indicated in the
short section about the component you would like to use. Then pick which implementation you
would like and typedef it to something nice. Here is an example of creating a typedef for
a set of integers using the first kernel implementation. <br/>
<tt>typedef dlib::set&lt;int&gt;::kernel_1a set_of_ints;</tt>
</p>
<p>
Note that it is assumed by these containers that swap() and operator&lt; do not throw. They
may not function correctly if this assumption is broken. Also note that the built in types (int, long,
char, etc...) and std::string will not cause operator&lt; or swap() to throw.
</p>
<p>
Note also that most of the containers inherit from the <a href="#enumerable">enumerable</a>
interface. Thus, all the member functions inherited from enumerable are defined
in the enumerable class and their documentation is not repeated in each
container's documentation. This includes the size() member function in each
container.
</p>
</body>
<!-- ************************************************************************* -->
<menu width="150">
<top>
<section>
<name>Objects</name>
<item>static_set</item>
<item>array</item>
<item>array2d</item>
<item>binary_search_tree</item>
<item>hash_map</item>
<item>hash_set</item>
<item>hash_table</item>
<item>directed_graph</item>
<item>graph</item>
<item>map</item>
<item>matrix</item>
<item>queue</item>
<item>reference_counter</item>
<item>sequence</item>
<item>set</item>
<item>stack</item>
<item>std_vector_c</item>
<item>static_map</item>
<item>sliding_buffer</item>
<item>tuple</item>
<item nolink="true">
<name>smart pointers</name>
<sub>
<item>scoped_ptr</item>
<item>shared_ptr</item>
<item>weak_ptr</item>
</sub>
</item>
</section>
<section>
<name>Interfaces</name>
<item>map_pair</item>
<item>enumerable</item>
<item>
<name>remover</name>
<sub>
<item>
<name>remover</name>
<link>dlib/interfaces/remover.h.html#remover</link>
</item>
<item>
<name>asc_remover</name>
<link>dlib/interfaces/remover.h.html#asc_remover</link>
</item>
<item>
<name>pair_remover</name>
<link>dlib/interfaces/remover.h.html#pair_remover</link>
</item>
<item>
<name>asc_pair_remover</name>
<link>dlib/interfaces/remover.h.html#asc_pair_remover</link>
</item>
</sub>
</item>
</section>
</top>
</menu>
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<!-- ************************************************************************* -->
<components>
<component checked="true">
<name>array</name>
<file>dlib/array.h</file>
<spec_file>dlib/array/array_kernel_abstract.h</spec_file>
<description>
This object is just like a C style array and the accessor functions operate
in constant time.
</description>
<implementations>
<implementation>
<name>array_kernel_1</name>
<file>dlib/array/array_kernel_1.h</file>
<description>
This implementation is done using an array of pointers, each of which point to
small sections of the array. This implementation allows the array to use only
about as much memory as it needs at any given time.
It does not use the <a href="other.html#memory_manager">memory_manager</a> at all.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for array_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>array_kernel_2</name>
<file>dlib/array/array_kernel_2.h</file>
<description>
This implementation is done using a single array of max_size() elements. So this
is just a simple layer on top of a C style array.
It uses the <a href="other.html#memory_manager">memory_manager</a> for all
memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for array_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>array_sort</name>
<spec_file>dlib/array/array_sort_abstract.h</spec_file>
<description>
This extension gives an array the ability to sort its contents.
</description>
<implementations>
<implementation>
<name>array_sort_1</name>
<file>dlib/array/array_sort_1.h</file>
<description>
This is a version of the QuickSort algorithm. It swaps the entire array into a C
style array, sorts it and then swaps it back into the array object.
</description>
<typedefs>
<typedef>
<name>sort_1a</name>
<description>is a typedef for array_kernel_1a extended by array_sort_1</description>
</typedef>
<typedef>
<name>sort_1b</name>
<description>is a typedef for array_kernel_2a extended by array_sort_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>array_sort_2</name>
<file>dlib/array/array_sort_2.h</file>
<description>
This is a version of the QuickSort algorithm.
</description>
<typedefs>
<typedef>
<name>sort_2a</name>
<description>is a typedef for array_kernel_1a extended by array_sort_2</description>
</typedef>
<typedef>
<name>sort_2b</name>
<description>is a typedef for array_kernel_2a extended by array_sort_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
<extension>
<name>array_expand</name>
<spec_file>dlib/array/array_expand_abstract.h</spec_file>
<description>
This extension gives an array the ability to expand its size() beyond
its max_size() without clearing out all its elements. It also adds a set of pop/push_back()
functions similar to the ones in the std::vector object.
</description>
<implementations>
<implementation>
<name>array_expand_1</name>
<file>dlib/array/array_expand_1.h</file>
<description>
This is implemented by creating a new bigger array if max_size() isn't big enough,
swapping everything into that new array, and then swapping that array with *this.
</description>
<typedefs>
<typedef>
<name>expand_1a</name>
<description>is a typedef for array_sort_1a extended by array_expand_1</description>
</typedef>
<typedef>
<name>expand_1b</name>
<description>is a typedef for array_sort_1b extended by array_expand_1</description>
</typedef>
<typedef>
<name>expand_1c</name>
<description>is a typedef for array_sort_2a extended by array_expand_1</description>
</typedef>
<typedef>
<name>expand_1d</name>
<description>is a typedef for array_sort_2b extended by array_expand_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>sliding_buffer</name>
<file>dlib/sliding_buffer.h</file>
<spec_file>dlib/sliding_buffer/sliding_buffer_kernel_abstract.h</spec_file>
<description>
This object represents an array with the ability to rotate its contents
left or right.
</description>
<implementations>
<implementation>
<name>sliding_buffer_kernel_1</name>
<file>dlib/sliding_buffer/sliding_buffer_kernel_1.h</file>
<description>
This object is implemented using a C style array in the obvious way. See the code for details.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for sliding_buffer_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>array2d</name>
<file>dlib/array2d.h</file>
<spec_file>dlib/array2d/array2d_kernel_abstract.h</spec_file>
<description>
This object represents a 2-Dimensional array of objects.
</description>
<examples>
<example>image_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>array2d_kernel_1</name>
<file>dlib/array2d/array2d_kernel_1.h</file>
<description>
This is implemented in the obvious way. See the source for details.
It uses the <a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for array2d_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>binary_search_tree</name>
<file>dlib/binary_search_tree.h</file>
<spec_file>dlib/binary_search_tree/binary_search_tree_kernel_abstract.h</spec_file>
<description>
This object represents a data dictionary that is built on top of some kind of binary search tree.
</description>
<implementations>
<implementation>
<name>binary_search_tree_kernel_1</name>
<file>dlib/binary_search_tree/binary_search_tree_kernel_1.h</file>
<description>
This implementation is done using an AVL binary search tree. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for binary_search_tree_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>binary_search_tree_kernel_2</name>
<file>dlib/binary_search_tree/binary_search_tree_kernel_2.h</file>
<description>
This implementation is done using a red-black binary search tree. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for binary_search_tree_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>hash_map</name>
<file>dlib/hash_map.h</file>
<spec_file>dlib/hash_map/hash_map_kernel_abstract.h</spec_file>
<description>
This object represents a hashed mapping of items of type domain onto items of type range.
</description>
<implementations>
<implementation>
<name>hash_map_kernel_1</name>
<file>dlib/hash_map/hash_map_kernel_1.h</file>
<description>
This implementation is done using a <a href="#hash_table">hash_table</a> object. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for hash_map_kernel_1 that uses hash_table_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for hash_map_kernel_1 that uses hash_table_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for hash_map_kernel_1 that uses hash_table_kernel_2b</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>hash_set</name>
<file>dlib/hash_set.h</file>
<spec_file>dlib/hash_set/hash_set_kernel_abstract.h</spec_file>
<description>
This object represents a hashed unordered and unaddressed collection of unique items.
</description>
<implementations>
<implementation>
<name>hash_set_kernel_1</name>
<file>dlib/hash_set/hash_set_kernel_1.h</file>
<description>
This implementation is done using a <a href="#hash_table">hash_table</a> object. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for hash_set_kernel_1 that uses hash_table_kernel_1a</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for hash_set_kernel_1 that uses hash_table_kernel_2a</description>
</typedef>
<typedef>
<name>kernel_1c</name>
<description>is a typedef for hash_set_kernel_1 that uses hash_table_kernel_2b</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>hash_table</name>
<file>dlib/hash_table.h</file>
<spec_file>dlib/hash_table/hash_table_kernel_abstract.h</spec_file>
<description>
This object represents a data dictionary that is built on top of some kind of
hash table.
</description>
<implementations>
<implementation>
<name>hash_table_kernel_1</name>
<file>dlib/hash_table/hash_table_kernel_1.h</file>
<description>
This implementation is done using singly linked lists as hashing buckets. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for hash_table_kernel_1. </description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>hash_table_kernel_2</name>
<file>dlib/hash_table/hash_table_kernel_2.h</file>
<description>
This implementation is done using <a href="#binary_search_tree">
binary_search_tree</a> objects as hashing buckets. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for hash_table_kernel_2 that uses binary_search_tree_kernel_1</description>
</typedef>
<typedef>
<name>kernel_2b</name>
<description>is a typedef for hash_table_kernel_2 that uses binary_search_tree_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>map</name>
<file>dlib/map.h</file>
<spec_file>dlib/map/map_kernel_abstract.h</spec_file>
<description>
This object represents a mapping of items of type domain onto items of type range.
</description>
<implementations>
<implementation>
<name>map_kernel_1</name>
<file>dlib/map/map_kernel_1.h</file>
<description>
This is implemented using the <a href="#binary_search_tree">binary_search_tree</a> component. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for map_kernel_1 that uses binary_search_tree_kernel_1</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for map_kernel_1 that uses binary_search_tree_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component>
<name>enumerable</name>
<file>dlib/interfaces/enumerable.h</file>
<spec_file>dlib/interfaces/enumerable.h</spec_file>
<description>
This object is an abstract class which represents an interface for iterating over
all the elements of a container.
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>map_pair</name>
<file>dlib/interfaces/map_pair.h</file>
<spec_file>dlib/interfaces/map_pair.h</spec_file>
<description>
This object is an abstract class which represents an interface for accessing a
pair from a container such as the map, hash_table, etc...
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>remover</name>
<file>dlib/interfaces/remover.h</file>
<spec_file>dlib/interfaces/remover.h</spec_file>
<description>
This is a set of interfaces which gives the ability to remove all the items in a
container without actually knowing what kind of container contains them.
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>weak_ptr</name>
<file>dlib/smart_pointers.h</file>
<spec_file>dlib/smart_pointers/weak_ptr_abstract.h</spec_file>
<description>
<p>
The weak_ptr class template stores a weak reference to an object that is
already managed by a shared_ptr. To access the object, a weak_ptr can
be converted to a shared_ptr using the member function lock().
</p>
<p>
This is an implementation of the std::tr1::weak_ptr template from the
document ISO/IEC PDTR 19768, Proposed Draft Technical Report on C++
Library Extensions. The only deviation from that document is that this
shared_ptr is declared inside the dlib namespace rather than std::tr1.
</p>
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>shared_ptr</name>
<file>dlib/smart_pointers.h</file>
<spec_file>dlib/smart_pointers/shared_ptr_abstract.h</spec_file>
<description>
<p>
This object represents a reference counted smart pointer. Each shared_ptr
contains a pointer to some object and when the last shared_ptr that points
to the object is destructed or reset() then the object is guaranteed to be
deleted.
</p>
<p>
This is an implementation of the std::tr1::shared_ptr template from the
document ISO/IEC PDTR 19768, Proposed Draft Technical Report on C++
Library Extensions. The only deviation from that document is that this
shared_ptr is declared inside the dlib namespace rather than std::tr1.
</p>
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>tuple</name>
<file>dlib/tuple.h</file>
<spec_file>dlib/tuple/tuple_abstract.h</spec_file>
<description>
This is an implementation of a very simple templated container object.
It contains between 0 and 31 objects where each object is listed
explicity in the tuple's template arguments.
<p>
Note that there is only one implementation of this object so there aren't any
different kernels to choose from when you create instances of the matrix object.
So for example, you
could declare a tuple of 3 ints using the following statement:
<tt>dlib::tuple&lt;int,int,int&gt; t;</tt>
</p>
</description>
</component>
<!-- ************************************************************************* -->
<component>
<name>scoped_ptr</name>
<file>dlib/smart_pointers.h</file>
<spec_file>dlib/smart_pointers/scoped_ptr_abstract.h</spec_file>
<description>
This is a implementation of the scoped_ptr class found in the Boost C++
library. It is a simple smart pointer class which guarantees that the
pointer contained within it will always be deleted.
The class does not permit copying and so does not do any kind of
reference counting. Thus it is very simple and quite fast.
</description>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>graph</name>
<file>dlib/graph.h</file>
<spec_file>dlib/graph/graph_kernel_abstract.h</spec_file>
<description>
This object represents a graph which is a set of nodes with undirected
edges connecting various nodes.
</description>
<implementations>
<implementation>
<name>graph_kernel_1</name>
<file>dlib/graph/graph_kernel_1.h</file>
<description>
This is implemented using std::vector to contain all the nodes and edges.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for graph_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>directed_graph</name>
<file>dlib/directed_graph.h</file>
<spec_file>dlib/directed_graph/directed_graph_kernel_abstract.h</spec_file>
<description>
This object represents a directed graph which is a set of nodes with directed
edges connecting various nodes.
</description>
<implementations>
<implementation>
<name>directed_graph_kernel_1</name>
<file>dlib/directed_graph/directed_graph_kernel_1.h</file>
<description>
This is implemented using std::vector to contain all the nodes and edges.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for directed_graph_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>queue</name>
<file>dlib/queue.h</file>
<spec_file>dlib/queue/queue_kernel_abstract.h</spec_file>
<description>
This object represents a first in first out queue.
</description>
<examples>
<example>dir_nav_ex.cpp.html</example>
<example>queue_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>queue_kernel_1</name>
<file>dlib/queue/queue_kernel_1.h</file>
<description>
This is implemented in the obvious way using a singly linked list. It does not use the
<a href="other.html#memory_manager">memory_manager</a> at all.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for queue_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>queue_kernel_2</name>
<file>dlib/queue/queue_kernel_2.h</file>
<description>
This is implemented using a singly linked list and each node in the list
contains block_size (a template parameter) elements. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for queue_kernel_2 with a block_size of 20</description>
</typedef>
<typedef>
<name>kernel_2b</name>
<description>is a typedef for queue_kernel_2 with a block_size of 100</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>queue_sort</name>
<spec_file>dlib/queue/queue_sort_abstract.h</spec_file>
<description>
This extension gives a queue the ability to sort its contents.
</description>
<implementations>
<implementation>
<name>queue_sort_1</name>
<file>dlib/queue/queue_sort_1.h</file>
<description>
This is a version of the QuickSort algorithm.
</description>
<typedefs>
<typedef>
<name>sort_1a</name>
<description>is a typedef for queue_kernel_1a extended by queue_sort_1</description>
</typedef>
<typedef>
<name>sort_1b</name>
<description>is a typedef for queue_kernel_2a extended by queue_sort_1</description>
</typedef>
<typedef>
<name>sort_1c</name>
<description>is a typedef for queue_kernel_2b extended by queue_sort_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>reference_counter</name>
<file>dlib/reference_counter.h</file>
<spec_file>dlib/reference_counter/reference_counter_kernel_abstract.h</spec_file>
<description>
This object represents a container for an object and provides reference counting
capabilities for the object it contains.
</description>
<implementations>
<implementation>
<name>reference_counter_kernel_1</name>
<file>dlib/reference_counter/reference_counter_kernel_1.h</file>
<description>
This implementation is done using pointers in the obvious way.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for reference_counter_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>sequence</name>
<file>dlib/sequence.h</file>
<spec_file>dlib/sequence/sequence_kernel_abstract.h</spec_file>
<description>
This object represents an ordered sequence of items, each item is
associated with an integer value. The items are numbered from 0 to the number of items in the
sequence minus 1.
</description>
<implementations>
<implementation>
<name>sequence_kernel_1</name>
<file>dlib/sequence/sequence_kernel_1.h</file>
<description>
This is implemented as an AVL binary search tree.
Accessing(or adding or removing) an element always takes O(log n) time.
It uses the <a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for sequence_kernel_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>sequence_kernel_2</name>
<file>dlib/sequence/sequence_kernel_2.h</file>
<description>
This implementation is done using a doubly linked list in the shape of a ring.
It will remember the last element accessed(or added or removed) and give O(1)
access time to the elements just left and right of it. Aside from that,
accessing(or adding or removing) a random element will take O(n) and in the worst
case it will take time proportional to the size of the sequence/2.
<p>
It does not use the
<a href="other.html#memory_manager">memory_manager</a> at all.
</p>
</description>
<typedefs>
<typedef>
<name>kernel_2a</name>
<description>is a typedef for sequence_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>sequence_sort</name>
<spec_file>dlib/sequence/sequence_sort_abstract.h</spec_file>
<description>
This extension gives a sequence the ability to sort its contents.
</description>
<implementations>
<implementation>
<name>sequence_sort_1</name>
<file>dlib/sequence/sequence_sort_1.h</file>
<description>
This is a version of the QuickSort algorithm and it sorts sequences of less
than 30 elements with a selection sort. This implementation is fastest when
used with sequence_kernel_2 and fairly slow when used with sequence_kernel_1
</description>
<typedefs>
<typedef>
<name>sort_1a</name>
<description>is a typedef for sequence_kernel_2a extended by sequence_sort_1</description>
</typedef>
</typedefs>
</implementation>
<implementation>
<name>sequence_sort_2</name>
<file>dlib/sequence/sequence_sort_2.h</file>
<description>
This is a version of the QuickSort algorithm. This implementation of sort is
the best to use with sequence_kernel_1 objects but gives extremely poor performance
with sequence_kernel_2 objects.
</description>
<typedefs>
<typedef>
<name>sort_2a</name>
<description>is a typedef for sequence_kernel_1a extended by sequence_sort_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
<extension>
<name>sequence_compare</name>
<spec_file>dlib/sequence/sequence_compare_abstract.h</spec_file>
<description>
This extension gives sequences the ability to compare themselves using
operator&lt; and operator==. Thus they can be used in the other container classes
that require this ability. (maps, sets, etc...)
</description>
<implementations>
<implementation>
<name>sequence_compare_1</name>
<file>dlib/sequence/sequence_compare_1.h</file>
<description>
The implementation is obvious. Click on the sequence_compare_1 link if you want to see.
</description>
<typedefs>
<typedef>
<name>compare_1a</name>
<description>is a typedef for sequence_kernel_1a extended by sequence_compare_1</description>
</typedef>
<typedef>
<name>compare_1b</name>
<description>is a typedef for sequence_kernel_2a extended by sequence_compare_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>set</name>
<file>dlib/set.h</file>
<spec_file>dlib/set/set_kernel_abstract.h</spec_file>
<description>
This object represents an unordered and unaddressed collection of unique items.
</description>
<implementations>
<implementation>
<name>set_kernel_1</name>
<file>dlib/set/set_kernel_1.h</file>
<description>
This is implemented using the <a href="#binary_search_tree">binary_search_tree</a> component. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for set_kernel_1 that uses binary_search_tree_kernel_1</description>
</typedef>
<typedef>
<name>kernel_1b</name>
<description>is a typedef for set_kernel_1 that uses binary_search_tree_kernel_2</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>set_compare</name>
<spec_file>dlib/set/set_compare_abstract.h</spec_file>
<description>
This extension gives sets the ability to compare themselves using operator&lt; and
operator==. Thus they can be used in the other container classes that require
this ability. (maps, sets, etc...)
</description>
<implementations>
<implementation>
<name>set_compare_1</name>
<file>dlib/set/set_compare_1.h</file>
<description>
The implementation is obvious. Click on the set_compare_1 link if you want to see.
</description>
<typedefs>
<typedef>
<name>compare_1a</name>
<description>is a typedef for set_kernel_1a extended by set_compare_1</description>
</typedef>
<typedef>
<name>compare_1b</name>
<description>is a typedef for set_kernel_1b extended by set_compare_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>stack</name>
<file>dlib/stack.h</file>
<spec_file>dlib/stack/stack_kernel_abstract.h</spec_file>
<description>
This object represents a last in first out stack.
</description>
<implementations>
<implementation>
<name>stack_kernel_1</name>
<file>dlib/stack/stack_kernel_1.h</file>
<description>
This implementation is done in the obvious way using a singly linked list. It uses the
<a href="other.html#memory_manager">memory_manager</a> for all memory allocations.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for stack_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>static_map</name>
<file>dlib/static_map.h</file>
<spec_file>dlib/static_map/static_map_kernel_abstract.h</spec_file>
<description>
This object represents a mapping of items of type domain onto items of type range.
The difference between this object and the normal <a href="#map">map</a> object is that it does not support adding
or removing individual objects from itself. This allows implementations to focus on using less memory and
achieving faster searching.
</description>
<implementations>
<implementation>
<name>static_map_kernel_1</name>
<file>dlib/static_map/static_map_kernel_1.h</file>
<description>
This implementation is just a sorted array which can be searched using a binary search.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for static_map_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</component>
<!-- ************************************************************************* -->
<component checked="true">
<name>static_set</name>
<file>dlib/static_set.h</file>
<spec_file>dlib/static_set/static_set_kernel_abstract.h</spec_file>
<description>
This object represents an unordered and unaddressed collection of items.
The difference between this object and the normal <a href="#set">set</a> object is that it does not support adding
or removing individual objects from itself. This allows implementations to focus on using less memory and
achieving faster searching.
</description>
<examples>
<example>dir_nav_ex.cpp.html</example>
</examples>
<implementations>
<implementation>
<name>static_set_kernel_1</name>
<file>dlib/static_set/static_set_kernel_1.h</file>
<description>
This implementation is just a sorted array which can be searched using a binary search.
</description>
<typedefs>
<typedef>
<name>kernel_1a</name>
<description>is a typedef for static_set_kernel_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
<extensions>
<extension>
<name>static_set_compare</name>
<spec_file>dlib/static_set/static_set_compare_abstract.h</spec_file>
<description>
This extension gives static_sets the ability to compare themselves using operator&lt; and
operator==. Thus they can be used in the other container classes that require
this ability. (maps, static_sets, etc...)
</description>
<implementations>
<implementation>
<name>static_set_compare_1</name>
<file>dlib/static_set/static_set_compare_1.h</file>
<description>
The implementation is obvious. Click on the static_set_compare_1 link if you want to see.
</description>
<typedefs>
<typedef>
<name>compare_1a</name>
<description>is a typedef for static_set_kernel_1a extended by static_set_compare_1</description>
</typedef>
</typedefs>
</implementation>
</implementations>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>matrix</name>
<file>dlib/matrix.h</file>
<spec_file link="true">dlib/matrix/matrix_abstract.h</spec_file>
<description>
This is a 2D matrix object. It is implemented using the expression templates
technique which allows us to eliminate the temporary matrix objects that would
normally be returned from expressions such as M = A+B+C+D; Normally each
invocation of the + operator would construct and return a temporary matrix
object but using this technique we can avoid creating all of these temporary
objects and receive a large speed boost.
<p>
Note that there is only one implementation of this object so there aren't any
different kernels to choose from when you create instances of the matrix object.
So for example, you
could declare a matrix of 2 rows and 3 columns using the following statement:
<tt>dlib::matrix&lt;float,2,3&gt; m;</tt>
</p>
<p>
It should also be noted that matrix multiplication is fastest when the two matrices
being multiplied are not complex matrix_exp objects returned from other expressions
(such as other matrix multiplies). This is because the matrix multiply operator will
evaluate each element of the matrices it is multiplying many times, and a matrix_exp
computes its elements' values each time they are queried. However, the matrix multiply
operator is the only one that evaluates its argument's elements multiple times so you can
stack up all the other operators however you want without any performance penalty. If
you want to multiply two complex matrix_exp expressions together you can easily convert them into
fully evaluated temporary matrix objects by using the tmp() function. For example, to
multiply four matrices together you should use an expression such as <tt>result = tmp(a*b)*tmp(c*d);</tt>
</p>
</description>
<examples>
<example>matrix_ex.cpp.html</example>
</examples>
<extensions>
<extension>
<name>matrix_utilities</name>
<spec_file>dlib/matrix/matrix_utilities_abstract.h</spec_file>
<description>This extension contains miscellaneous utility functions
for manipulating matrix objects. Note that you don't need to #include
anything to get them. They are included by the <a href="dlib/matrix.h.html">dlib/matrix.h</a> file for you.
</description>
</extension>
<extension>
<name>matrix_math_functions</name>
<spec_file>dlib/matrix/matrix_math_functions_abstract.h</spec_file>
<description>This extension contains mathematical functions that operate on each
element of a matrix independently. Note that you don't need to #include
anything to get them. They are included by the <a href="dlib/matrix.h.html">dlib/matrix.h</a> file for you.
</description>
</extension>
</extensions>
</component>
<!-- ************************************************************************* -->
<component>
<name>std_vector_c</name>
<file>dlib/stl_checked.h</file>
<spec_file link="true">dlib/stl_checked/std_vector_c_abstract.h</spec_file>
<description>
This object is a simple wrapper around the std::vector object. It
provides an identical interface but also checks the preconditions of
each member function. That is, if you violate a requires
clause the dlib::fatal_error exception is thrown.
</description>
</component>
<!-- ************************************************************************* -->
</components>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<!-- ************************************************************************* -->
<body>
<center><h1>dlib C++ library</h1></center>
<br/><br/>
<p>
<web>Welcome to the dlib C++ library's homepage. </web>
<chm>Welcome to the dlib C++ library documentation.</chm>
It is a modern C++ library with a focus on portability
and program correctness. It strives to be easy to use right and hard to use wrong.
Thus, it comes with extensive documentation and thorough debugging modes.
</p>
<p>
The library is open source software and is licensed
under the <a href="license.html">Boost Software License</a>.
The <a href="intro.html">introduction</a> contains everything you need to know to get
started using the library. However, if you have any questions, comments, or complaints feel free to
<a href='mailto:davisking@users.sourceforge.net'>email me</a><web> or post in the
sourceforge <a href='http://sourceforge.net/forum/?group_id=130373'>Forums</a></web>.
</p>
<chm>
<p>
For updates to this project check its sourceforge page at <a href="http://dclib.sourceforge.net">http://dclib.sourceforge.net</a>.
</p>
</chm>
<br/>
<p>
<h2>Major Features</h2>
<ul>
<li><b>Documentation</b>
<ul>
<li>Unlike a lot of open source projects, this one provides complete and precise
documentation for every class and function. There are also debugging modes that check the
documented preconditions for functions. When this is enabled it will catch the vast majority of
bugs caused by calling functions incorrectly or using objects in an incorrect manner.
</li>
<li>Lots of example programs are provided</li>
<li><i>I consider the documentation to be the most important part of the library</i>. So if you find anything
that isn't documented, isn't clear, or has out of date documentation, tell me and I will fix it.
</li>
</ul>
</li>
<li><b>Portable Code</b>
<ul>
<li>All non ISO C++ code is isolated inside the OS abstraction layers which are kept as small as possible.
The rest of the library is either layered on top of the OS
abstraction layers or is pure ISO C++. </li>
<li>Big/little endian agnostic</li>
<li>No other packages are required to use the library. Only APIs that are
provided by an out of the box OS are used. </li>
<li>The library is tested regularly on win32, Linux, and Mac OS X systems. However, it should
work on any POSIX system and has been tested on Solaris, HPUX, and the BSDs.</li>
</ul>
</li>
<li><b>Threading</b>
<ul>
<li>The library provides a portable and simple <a href="api.html#threads">threading API</a></li>
<li>A <a href="other.html#pipe">pipe</a> for inter-thread communication</li>
<li>A <a href="other.html#timer">timer</a> object capable of generating events that are regularly spaced in time</li>
<li><a href="api.html#thread_specific_data">Thread specific data</a></li>
<li><a href="api.html#threaded_object">Threaded objects</a></li>
<li><a href="api.html#thread_function">Threaded functions</a></li>
</ul>
</li>
<li><b>Networking</b>
<ul>
<li>The library provides a portable and simple <a href="api.html#sockets">TCP sockets API</a></li>
<li>An object to help you make TCP based <a href="network.html#server">servers</a></li>
<li>A <a href="network.html#sockstreambuf">streambuf</a> object that enables TCP sockets
to interoperate with the C++ iostreams library </li>
<li>A simple <a href="network.html#http">HTTP server</a> object you can use to embed a
web server into your applications</li>
</ul>
</li>
<li><b>Graphical User Interfaces</b>
<ul>
<li>The library provides a portable and simple core <a href="api.html#gui_core">GUI API</a></li>
<li>Implemented on top of the core GUI API are numerous <a href="api.html#gui_widgets">widgets</a></li>
<li>Unlike many other GUI toolkits, the entire dlib GUI toolkit is threadsafe</li>
</ul>
</li>
<li><b>Numerical Algorithms</b>
<ul>
<li>A fast <a href="containers.html#matrix">matrix</a> object implemented using the expression templates technique</li>
<li>Numerous linear algebra and mathematical operations are defined for the matrix object such as the
<a href="dlib/matrix/matrix_utilities_abstract.h.html#svd">singular value decomposition</a>,
<a href="dlib/matrix/matrix_utilities_abstract.h.html#trans">transpose</a>,
<a href="dlib/matrix/matrix_math_functions_abstract.h.html#sin">trig functions</a>, etc...</li>
<li>Unconstrained optimization algorithms such as
<a href="algorithms.html#find_min_conjugate_gradient">conjugate gradient</a> and <a href="algorithms.html#find_min_quasi_newton">quasi newton</a> techniques</li>
<li>A <a href="algorithms.html#bigint">big integer</a> object</li>
<li>A <a href="algorithms.html#rand">random number</a> object</li>
</ul>
</li>
<li><b>Machine Learning Algorithms</b>
<ul>
<li><a href="algorithms.html#mlp">multi layer perceptrons</a> </li>
<li><a href="algorithms.html#svm_nu_train">nu support vector machines</a> for classification</li>
<li>An online <a href="algorithms.html#krls">kernel RLS regression</a> algorithm</li>
<li>An online kernelized <a href="algorithms.html#kcentroid">centroid estimator</a></li>
<li>A kernelized <a href="algorithms.html#kkmeans">k-means</a> clustering algorithm</li>
<li>Bayesian Network inference algorithms such as the
<a href="algorithms.html#bayesian_network_join_tree">join tree</a> algorithm and
<a href="algorithms.html#bayesian_network_gibbs_sampler">Gibbs sampler</a> Markov Chain Monte Carlo algorithm</li>
</ul>
</li>
<li><b>Image Processing</b>
<ul>
<li>Windows BMP <a href="imaging.html#load_bmp">read</a> and <a href="imaging.html#save_bmp">write</a> support</li>
<li>Automatic color space conversion between various pixel types</li>
<li>Common image operations such as edge finding and morphological operations</li>
</ul>
</li>
<li><b>Data Compression and Integrity Algorithms</b>
<ul>
<li>A <a href="algorithms.html#crc32">CRC 32</a> object</li>
<li><a href="algorithms.html#md5">MD5</a> functions</li>
<li>Various abstracted objects representing parts of <a href="compression.html">data compression</a>
algorithms. Many forms of the PPM algorithm are included. </li>
</ul>
</li>
<li><b>Testing</b>
<ul>
<li>A thread safe <a href="other.html#logger">logger</a> object styled after the popular Java logger log4j</li>
<li>A modular <a href="other.html#dlib_testing_suite">unit testing framework</a></li>
<li>Various <a href="metaprogramming.html">assert</a> macros useful for testing preconditions</li>
</ul>
</li>
<li><b>General Utilities</b>
<ul>
<li>A type-safe <a href="other.html#byte_orderer">object</a> to convert between big and little endian byte orderings</li>
<li>A <a href="parsing.html#cmd_line_parser">command line parser</a> with the ability to
parse and validate command lines with various types of arguments and options</li>
<li>An <a href="parsing.html#xml_parser">XML parser</a></li>
<li>An object that can perform <a href="parsing.html#base64">base64</a> conversions</li>
<li>Many <a href="containers.html">container classes</a></li>
<li><a href="other.html#serialize">Serialization support</a></li>
<li>Many <a href="other.html#memory_manager">memory manager</a> objects that implement
differnt memory pooling strategies</li>
</ul>
</li>
</ul>
</p>
</body>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<!-- ************************************************************************* -->
<body>
<center><h1>dlib C++ library</h1></center>
<br/><br/>
<p>
<web>Welcome to the dlib C++ library's homepage. </web>
<chm>Welcome to the dlib C++ library documentation.</chm>
It is a modern C++ library with a focus on portability
and program correctness. It strives to be easy to use right and hard to use wrong.
Thus, it comes with extensive documentation and thorough debugging modes.
</p>
<p>
The library is open source software and is licensed
under the <a href="license.html">Boost Software License</a>.
The <a href="intro.html">introduction</a> contains everything you need to know to get
started using the library. However, if you have any questions, comments, or complaints feel free to
<a href='mailto:davisking@users.sourceforge.net'>email me</a><web> or post in the
sourceforge <a href='http://sourceforge.net/forum/?group_id=130373'>Forums</a></web>.
</p>
<chm>
<p>
For updates to this project check its sourceforge page at <a href="http://dclib.sourceforge.net">http://dclib.sourceforge.net</a>.
</p>
</chm>
<br/>
<p>
<h2>Major Features</h2>
<ul>
<li><b>Documentation</b>
<ul>
<li>Unlike a lot of open source projects, this one provides complete and precise
documentation for every class and function. There are also debugging modes that check the
documented preconditions for functions. When this is enabled it will catch the vast majority of
bugs caused by calling functions incorrectly or using objects in an incorrect manner.
</li>
<li>Lots of example programs are provided</li>
<li><i>I consider the documentation to be the most important part of the library</i>. So if you find anything
that isn't documented, isn't clear, or has out of date documentation, tell me and I will fix it.
</li>
</ul>
</li>
<li><b>Portable Code</b>
<ul>
<li>All non ISO C++ code is isolated inside the OS abstraction layers which are kept as small as possible.
The rest of the library is either layered on top of the OS
abstraction layers or is pure ISO C++. </li>
<li>Big/little endian agnostic</li>
<li>No other packages are required to use the library. Only APIs that are
provided by an out of the box OS are used. </li>
<li>The library is tested regularly on win32, Linux, and Mac OS X systems. However, it should
work on any POSIX system and has been tested on Solaris, HPUX, and the BSDs.</li>
</ul>
</li>
<li><b>Threading</b>
<ul>
<li>The library provides a portable and simple <a href="api.html#threads">threading API</a></li>
<li>A <a href="other.html#pipe">pipe</a> for inter-thread communication</li>
<li>A <a href="other.html#timer">timer</a> object capable of generating events that are regularly spaced in time</li>
<li><a href="api.html#thread_specific_data">Thread specific data</a></li>
<li><a href="api.html#threaded_object">Threaded objects</a></li>
<li><a href="api.html#thread_function">Threaded functions</a></li>
</ul>
</li>
<li><b>Networking</b>
<ul>
<li>The library provides a portable and simple <a href="api.html#sockets">TCP sockets API</a></li>
<li>An object to help you make TCP based <a href="network.html#server">servers</a></li>
<li>A <a href="network.html#sockstreambuf">streambuf</a> object that enables TCP sockets
to interoperate with the C++ iostreams library </li>
<li>A simple <a href="network.html#http">HTTP server</a> object you can use to embed a
web server into your applications</li>
</ul>
</li>
<li><b>Graphical User Interfaces</b>
<ul>
<li>The library provides a portable and simple core <a href="api.html#gui_core">GUI API</a></li>
<li>Implemented on top of the core GUI API are numerous <a href="api.html#gui_widgets">widgets</a></li>
<li>Unlike many other GUI toolkits, the entire dlib GUI toolkit is threadsafe</li>
</ul>
</li>
<li><b>Numerical Algorithms</b>
<ul>
<li>A fast <a href="containers.html#matrix">matrix</a> object implemented using the expression templates technique</li>
<li>Numerous linear algebra and mathematical operations are defined for the matrix object such as the
<a href="dlib/matrix/matrix_utilities_abstract.h.html#svd">singular value decomposition</a>,
<a href="dlib/matrix/matrix_utilities_abstract.h.html#trans">transpose</a>,
<a href="dlib/matrix/matrix_math_functions_abstract.h.html#sin">trig functions</a>, etc...</li>
<li>Unconstrained optimization algorithms such as
<a href="algorithms.html#find_min_conjugate_gradient">conjugate gradient</a> and <a href="algorithms.html#find_min_quasi_newton">quasi newton</a> techniques</li>
<li>A <a href="algorithms.html#bigint">big integer</a> object</li>
<li>A <a href="algorithms.html#rand">random number</a> object</li>
</ul>
</li>
<li><b>Machine Learning Algorithms</b>
<ul>
<li><a href="algorithms.html#mlp">multi layer perceptrons</a> </li>
<li><a href="algorithms.html#svm_nu_train">nu support vector machines</a> for classification</li>
<li>An online <a href="algorithms.html#krls">kernel RLS regression</a> algorithm</li>
<li>An online kernelized <a href="algorithms.html#kcentroid">centroid estimator</a></li>
<li>A kernelized <a href="algorithms.html#kkmeans">k-means</a> clustering algorithm</li>
<li>Bayesian Network inference algorithms such as the
<a href="algorithms.html#bayesian_network_join_tree">join tree</a> algorithm and
<a href="algorithms.html#bayesian_network_gibbs_sampler">Gibbs sampler</a> Markov Chain Monte Carlo algorithm</li>
</ul>
</li>
<li><b>Image Processing</b>
<ul>
<li>Windows BMP <a href="imaging.html#load_bmp">read</a> and <a href="imaging.html#save_bmp">write</a> support</li>
<li>Automatic color space conversion between various pixel types</li>
<li>Common image operations such as edge finding and morphological operations</li>
</ul>
</li>
<li><b>Data Compression and Integrity Algorithms</b>
<ul>
<li>A <a href="algorithms.html#crc32">CRC 32</a> object</li>
<li><a href="algorithms.html#md5">MD5</a> functions</li>
<li>Various abstracted objects representing parts of <a href="compression.html">data compression</a>
algorithms. Many forms of the PPM algorithm are included. </li>
</ul>
</li>
<li><b>Testing</b>
<ul>
<li>A thread safe <a href="other.html#logger">logger</a> object styled after the popular Java logger log4j</li>
<li>A modular <a href="other.html#dlib_testing_suite">unit testing framework</a></li>
<li>Various <a href="metaprogramming.html">assert</a> macros useful for testing preconditions</li>
</ul>
</li>
<li><b>General Utilities</b>
<ul>
<li>A type-safe <a href="other.html#byte_orderer">object</a> to convert between big and little endian byte orderings</li>
<li>A <a href="parsing.html#cmd_line_parser">command line parser</a> with the ability to
parse and validate command lines with various types of arguments and options</li>
<li>An <a href="parsing.html#xml_parser">XML parser</a></li>
<li>An object that can perform <a href="parsing.html#base64">base64</a> conversions</li>
<li>Many <a href="containers.html">container classes</a></li>
<li><a href="other.html#serialize">Serialization support</a></li>
<li>Many <a href="other.html#memory_manager">memory manager</a> objects that implement
differnt memory pooling strategies</li>
</ul>
</li>
</ul>
</p>
</body>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>Introduction</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<!-- **************************** OVERVIEW SECTION **************************** -->
<h1>Overview</h1>
<p>
This library is a collection of various C++ objects I have created and found to be useful
over the last few years. Generally speaking, there is no focus on any specific domain
in the library, it mostly contains general utility sorts of things. One of the bigger
and more notable features is the API abstraction layer which allows you to create portable applications
that make use of TCP sockets, threads, file browsing, and simple graphical user interfaces. There
is, however, much more than just that.
</p>
<p>
This library also aims to be simple, portable, and modern. Everything is developed with the
<a href="http://en.wikipedia.org/wiki/Design_by_contract">Design by Contract</a>
methodology. You can read about Design by Contract on the internet
for more information but from
the point of view of a user of this library it basically means that there exists complete and precise
documentation and aggressive debugging modes that can be enabled.
</p>
<p>
I always try to make sure everything is as portable as possible. All platform specific code is
confined inside the API wrappers. Everything else is either layered on top of those wrappers
or is written in pure ISO standard C++. Currently the library is known to work on OS X,
MS Windows, Linux, Solaris, the BSDs, and HP-UX. It should work on any POSIX platform but I
haven't had the opportunity to test it on any others (if you have access to other platforms and
would like to help increase this list then let me know).
</p>
<p>
The rest of this page explains everything you need to know to get started using the library. It
explains where to find the documentation for each object/function and how to interpret
what you find there. For help compiling with dlib check out the <a href="compile.html">how to compile</a>
page. Or if you are having trouble finding where a particular object's documentation is located you may
be able to find it by consulting the <a href="term_index.html">index</a>.</p>
<p>
The library is also covered by the very liberal Boost Software License so feel free to use it
however you like.
</p>
<p>
Much of the organization and notation used in this library I learned from the
<a href="http://www.cse.ohio-state.edu/~weide/sce/now/">Software Component Engineering</a>
course sequence at OSU. As such, this library is heavily influenced by the Design by Contract and
generic programming methodologies.
</p>
<!-- **************************** NOTATION SECTION **************************** -->
<h1>Notation</h1>
<p>
For the most part I try to document my code in a way that any C++ programmer would understand
but for the sake of brevity I use some of the following uncommon notation.
</p>
<ul>
<li/><b> kernel, extension, and abstract </b>
<ul>
Each component of the library has a specification which defines its core behavior and interface. This
specification defines what is called the component's kernel. Additionally, each component may have any number of
extensions. An extension is essentially a specification for something that layers functionality on top of the
kernel of a component.
<br/>
<br/> In the naming of files I use the word abstract to indicate that a file
contains a specification of a kernel component or extension rather than an actual implementation.
</ul>
<br/><li/><b>/*! comments like this !*/</b>
<ul>
This is just for "formal comments." Generally these appear after a function prototype and contain
the requires/ensures stuff or at the top of a class and tell you general things about the class.
</ul>
<br/><li/> <b> requires/ensures/throws </b>
<ul>
These words appear in the formal comment following function prototypes and have the following meanings.
<br/><u>requires</u>: This defines a list of requirements for calling the function. These requirements
MUST be met or a call to the function has undefined results. (note that when the checking/debugging modes
are enabled on an object then it will throw the dlib::fatal_error exception with fatal_error::type == EBROKEN_ASSERT when the requires clause is
broken rather than causing "undefined results")
<br/><u>ensures</u>: This defines what the function does. It is a list of conditions that will be
true after the function finishes executing. Note that if an exception is thrown or the function returns
indicating an error occurred then nothing in the ensures clause is guaranteed to be true.
<br/><u>throws</u>: This defines what exceptions may be thrown by this function. It generally
tells you why the exception might be thrown. It also tells you what the function does in this event:
Does it have no effect at all? Does it corrupt any objects? etc...
<br/>
<br/>
Sometimes these blocks do not appear in the formal comment. The meanings in these cases are as follows:
<br/><u>missing requires</u>: There are no requirements, you may put anything in the function arguments.
<br/><u>missing ensures</u>: This means that the effects of the function are unspecified. This is often used
for call backs where the client programmer implements the actual function.
<br/><u>missing throws</u>: This means that the function does not throw anything.
<br/>
<br/>
So in summary, the requires clause must always be satisfied, the ensures clause tells you what the
function does when it does <i>not</i> throw or return an error, and the throws clause tells you what happens when the function
<i>does</i> throw.
</ul>
<br/><li/> <anchor>meaning_of_hash</anchor> <b> meaning of # symbol </b>
<ul>
I use this as a prefix on identifiers to make reference to the value of the identifier "after"
some event has occurred.
<br/><br/>
The most common place I use this notation is inside the formal comment following a function prototype.
If the # symbol appears in a requires/ensures/throws block then it means the value of
the identifier after the function has finished, otherwise all references to an identifier
refer to its value before the function was called.
<br/><br/>
An example will make it clear.
<pre><font color='#3333FF'>int</font> <b>funct</b><font face="Lucida Console">(</font>
<font color='#3333FF'> int</font>&amp; something
<font face="Lucida Console">);</font>
<font color='#009900'>/*!
requires
- something &gt; 4
ensures
- #some_other_function() == 9
- #funct() == something
- #something == something + 1
!*/</font>
</pre>
This says that funct() requires that "something" be greater than 4, that funct() will increment "something"
by 1, and funct() returns the original value of something. It also says that
<i>after</i> the call to funct() ends a call to some_other_function() will return the value 9.
</ul>
<br/><li/> <anchor>CONVENTION</anchor> <b> CONVENTION </b>
<ul>
This is a section of the formal comment which appears at the top of all classes which are
actual implementations (as opposed to specifications). This section of the comment contains
a list of invariants that tell you what the member variables are used for. It also relates
the state of the member variables to the class interface.
<br/>
<br/>
For example, you might see a line in this section that says "my_size == size()". This just means
that the member variable my_size always contains the value returned by the size() function.
</ul>
<br/><li/> <b> "initial value for its type" </b>
<ul>
I frequently say that after a function executes some variable or argument will have an
initial value for its type. This makes sense for objects with a user defined constructor,
but for anything else not so much. Therefore the initial value of a type with no user defined
constructor is undefined.
</ul>
</ul>
<!-- **************************** ORGANIZATION SECTION **************************** -->
<h1>Organization</h1>
<p>
The library can be thought of as a collection of components.
Each component consists of one "kernel" specification that defines exactly what the
component's interface looks like and what it does. Additionally each component may
have extensions to its kernel. Each kernel and extension specification can have many implementations.
</p>
<ul>
<li/> <b>File organization</b>
<ul>
Each component gets its own folder and one file in the root of the directory tree.
<br/><br/>
I will use the <a href="containers.html#queue">queue</a> object as a typical example and
explain what each of its files contain.
Below is the directory structure and all the files related to the queue component.
<br/><br/>
<ul><li/> <b> file tree </b>
<ul>
<li/> dlib/
<ul>
<li/> queue.h
<li/> queue/
<ul>
<li/> queue_kernel_abstract.h
<li/> queue_kernel_1.h
<li/> queue_kernel_2.h
<li/> queue_kernel_c.h
<li/> queue_sort_abstract.h
<li/> queue_sort_1.h
</ul>
</ul>
</ul>
<br/>
<li/> <a href="dlib/queue.h.html">queue.h</a>
<ul> This file does not contain any executable code. All it does is define the typedefs such as
kernel_1a, kernel_1a_c, etc... for the queue object. See the <a href="#creating_objects">Creating Objects</a>
section to learn what these typedefs are for.
</ul>
<li/> <a href="dlib/queue/queue_kernel_abstract.h.html"> queue_kernel_abstract.h </a>
<ul>
This file does not contain any code. It even has preprocessor directives that prevent
any of its contents from being included.
<br/>
<br/>
The purpose of this file is to define exactly what a queue object does and what its
interface is.
</ul>
<li/> <a href="dlib/queue/queue_sort_abstract.h.html"> queue_sort_abstract.h </a>
<ul>
This file also doesn't contain any code. Its only purpose is to define the sort
extension to queue objects.
</ul>
<li/> <a href="dlib/queue/queue_kernel_1.h.html"> queue_kernel_1.h </a>
<ul>
This file contains an implementation of the queue kernel specification found
in queue_kernel_abstract.h
</ul>
<li/> <a href="dlib/queue/queue_kernel_2.h.html"> queue_kernel_2.h </a>
<ul>
This file contains another implementation of the queue kernel specification found
in queue_kernel_abstract.h
</ul>
<li/> <a href="dlib/queue/queue_sort_1.h.html"> queue_sort_1.h </a>
<ul>
This file contains an implementation of the queue sort extension specification found
in queue_sort_abstract.h
</ul>
<li/> <a href="dlib/queue/queue_kernel_c.h.html"> queue_kernel_c.h </a>
<ul>
This file contains a templated class which wraps any implementation of the queue kernel
specification. It is used during debugging to check that the requires clauses are never
violated.
</ul>
</ul>
</ul>
</ul>
<!-- **************************** CREATING OBJECTS SECTION **************************** -->
<anchor>creating_objects</anchor>
<h1>Creating Objects</h1>
<p>
To create many of the objects in this library you need to choose which kernel implementation you would like and if you
want the checking version or any extensions.
</p>
<p>
To make this easy there are header files which define typedefs of all this stuff. For
example, to create a queue of ints using queue kernel implementation 1 you would type
<tt>dlib::queue&lt;int&gt;::kernel_1a my_queue;</tt>. Or to get the debugging/checking version you
would type <tt>dlib::queue&lt;int&gt;::kernel_1a_c my_queue;</tt>.
</p>
<p>
There can be a lot of different typedefs for each component. You can find a list of them
in the section for the component in question. For the queue component they can be found
<a href="containers.html#queue">here</a>.
</p>
<p>
None of the above applies to the API components (or any global functions or objects that don't list multiple implemenations
in their documenation). To use/create them you just need to include
the appropriate headers. For example, to create a mutex object from the <a href="api.html#threads">
threads</a> component you would simply type <tt>dlib::mutex my_mutex;</tt>. There is no
need to specify which kernel implementation. The correct kernel implementation
is determined by which platform you compile under. There are also no explicit checking versions
of the API components. However, there are <a href="metaprogramming.html#DLIB_ASSERT">DLIB_ASSERT</a> statements that perform checking and you can
enable them by #defining DEBUG or ENABLE_ASSERTS.
</p>
<!-- **************************** ASSUMPTIONS SECTION **************************** -->
<h1>Assumptions</h1>
There are some restrictions on the behavior of certain objects or functions.
Rather than replicating these restrictions all over the place in my documentation they
are listed here.
<ul>
<li/> <b> global swap() </b>
<ul>
It is assumed that this operator does not throw. Undefined behavior results if it does.
Note that std::swap() for all intrinsics and std::string does not throw.
</ul>
<br/><li/> <b> operator&lt;() </b>
<ul>
It is assumed that this operator (or std::less or any similar functor supplied by you to the library)
does not throw. Undefined behavior results if it does.
</ul>
<br/><li/> <b> dlib::general_hash </b>
<ul>
It is assumed that general_hash does not throw. Undefined behavior results if it does.
This is actually noted in the general hash spec file but I'm listing it here also for good measure.
</ul>
</ul>
<!-- **************************** THREAD SAFETY SECTION **************************** -->
<anchor>thread_safety</anchor>
<h1>Thread Safety</h1>
<p>
In the library there are three kinds of objects with regards to threading. There are objects
that are completely thread safe. Then there are objects that are not thread safe but can be
used if access to them is serialized using a mutex. Lastly, there are objects which share
some kind of global resource or are reference counted. The last kind of object is
extremely thread unfriendly and can only be used in a threaded program with great care.
</p>
<p>
How do you know which components/objects are thread safe and which aren't? The rule is that if
the specification for the component doesn't mention threading or thread safety then
it is ok to use as long as you serialize access to it. If the component might have
some global resources or be reference counted then the specifications will tell you this.
And lastly if the component is thread safe then the specification will tell you this also.
</p>
</body>
<!-- ************************************************************************* -->
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>Introduction</title>
<!-- ************************************************************************* -->
<body>
<br/><br/>
<!-- **************************** OVERVIEW SECTION **************************** -->
<h1>Overview</h1>
<p>
This library is a collection of various C++ objects I have created and found to be useful
over the last few years. Generally speaking, there is no focus on any specific domain
in the library, it mostly contains general utility sorts of things. One of the bigger
and more notable features is the API abstraction layer which allows you to create portable applications
that make use of TCP sockets, threads, file browsing, and simple graphical user interfaces. There
is, however, much more than just that.
</p>
<p>
This library also aims to be simple, portable, and modern. Everything is developed with the
<a href="http://en.wikipedia.org/wiki/Design_by_contract">Design by Contract</a>
methodology. You can read about Design by Contract on the internet
for more information but from
the point of view of a user of this library it basically means that there exists complete and precise
documentation and aggressive debugging modes that can be enabled.
</p>
<p>
I always try to make sure everything is as portable as possible. All platform specific code is
confined inside the API wrappers. Everything else is either layered on top of those wrappers
or is written in pure ISO standard C++. Currently the library is known to work on OS X,
MS Windows, Linux, Solaris, the BSDs, and HP-UX. It should work on any POSIX platform but I
haven't had the opportunity to test it on any others (if you have access to other platforms and
would like to help increase this list then let me know).
</p>
<p>
The rest of this page explains everything you need to know to get started using the library. It
explains where to find the documentation for each object/function and how to interpret
what you find there. For help compiling with dlib check out the <a href="compile.html">how to compile</a>
page. Or if you are having trouble finding where a particular object's documentation is located you may
be able to find it by consulting the <a href="term_index.html">index</a>.</p>
<p>
The library is also covered by the very liberal Boost Software License so feel free to use it
however you like.
</p>
<p>
Much of the organization and notation used in this library I learned from the
<a href="http://www.cse.ohio-state.edu/~weide/sce/now/">Software Component Engineering</a>
course sequence at OSU. As such, this library is heavily influenced by the Design by Contract and
generic programming methodologies.
</p>
<!-- **************************** NOTATION SECTION **************************** -->
<h1>Notation</h1>
<p>
For the most part I try to document my code in a way that any C++ programmer would understand
but for the sake of brevity I use some of the following uncommon notation.
</p>
<ul>
<li/><b> kernel, extension, and abstract </b>
<ul>
Each component of the library has a specification which defines its core behavior and interface. This
specification defines what is called the component's kernel. Additionally, each component may have any number of
extensions. An extension is essentially a specification for something that layers functionality on top of the
kernel of a component.
<br/>
<br/> In the naming of files I use the word abstract to indicate that a file
contains a specification of a kernel component or extension rather than an actual implementation.
</ul>
<br/><li/><b>/*! comments like this !*/</b>
<ul>
This is just for "formal comments." Generally these appear after a function prototype and contain
the requires/ensures stuff or at the top of a class and tell you general things about the class.
</ul>
<br/><li/> <b> requires/ensures/throws </b>
<ul>
These words appear in the formal comment following function prototypes and have the following meanings.
<br/><u>requires</u>: This defines a list of requirements for calling the function. These requirements
MUST be met or a call to the function has undefined results. (note that when the checking/debugging modes
are enabled on an object then it will throw the dlib::fatal_error exception with fatal_error::type == EBROKEN_ASSERT when the requires clause is
broken rather than causing "undefined results")
<br/><u>ensures</u>: This defines what the function does. It is a list of conditions that will be
true after the function finishes executing. Note that if an exception is thrown or the function returns
indicating an error occurred then nothing in the ensures clause is guaranteed to be true.
<br/><u>throws</u>: This defines what exceptions may be thrown by this function. It generally
tells you why the exception might be thrown. It also tells you what the function does in this event:
Does it have no effect at all? Does it corrupt any objects? etc...
<br/>
<br/>
Sometimes these blocks do not appear in the formal comment. The meanings in these cases are as follows:
<br/><u>missing requires</u>: There are no requirements, you may put anything in the function arguments.
<br/><u>missing ensures</u>: This means that the effects of the function are unspecified. This is often used
for call backs where the client programmer implements the actual function.
<br/><u>missing throws</u>: This means that the function does not throw anything.
<br/>
<br/>
So in summary, the requires clause must always be satisfied, the ensures clause tells you what the
function does when it does <i>not</i> throw or return an error, and the throws clause tells you what happens when the function
<i>does</i> throw.
</ul>
<br/><li/> <anchor>meaning_of_hash</anchor> <b> meaning of # symbol </b>
<ul>
I use this as a prefix on identifiers to make reference to the value of the identifier "after"
some event has occurred.
<br/><br/>
The most common place I use this notation is inside the formal comment following a function prototype.
If the # symbol appears in a requires/ensures/throws block then it means the value of
the identifier after the function has finished, otherwise all references to an identifier
refer to its value before the function was called.
<br/><br/>
An example will make it clear.
<pre><font color='#3333FF'>int</font> <b>funct</b><font face="Lucida Console">(</font>
<font color='#3333FF'> int</font>&amp; something
<font face="Lucida Console">);</font>
<font color='#009900'>/*!
requires
- something &gt; 4
ensures
- #some_other_function() == 9
- #funct() == something
- #something == something + 1
!*/</font>
</pre>
This says that funct() requires that "something" be greater than 4, that funct() will increment "something"
by 1, and funct() returns the original value of something. It also says that
<i>after</i> the call to funct() ends a call to some_other_function() will return the value 9.
</ul>
<br/><li/> <anchor>CONVENTION</anchor> <b> CONVENTION </b>
<ul>
This is a section of the formal comment which appears at the top of all classes which are
actual implementations (as opposed to specifications). This section of the comment contains
a list of invariants that tell you what the member variables are used for. It also relates
the state of the member variables to the class interface.
<br/>
<br/>
For example, you might see a line in this section that says "my_size == size()". This just means
that the member variable my_size always contains the value returned by the size() function.
</ul>
<br/><li/> <b> "initial value for its type" </b>
<ul>
I frequently say that after a function executes some variable or argument will have an
initial value for its type. This makes sense for objects with a user defined constructor,
but for anything else not so much. Therefore the initial value of a type with no user defined
constructor is undefined.
</ul>
</ul>
<!-- **************************** ORGANIZATION SECTION **************************** -->
<h1>Organization</h1>
<p>
The library can be thought of as a collection of components.
Each component consists of one "kernel" specification that defines exactly what the
component's interface looks like and what it does. Additionally each component may
have extensions to its kernel. Each kernel and extension specification can have many implementations.
</p>
<ul>
<li/> <b>File organization</b>
<ul>
Each component gets its own folder and one file in the root of the directory tree.
<br/><br/>
I will use the <a href="containers.html#queue">queue</a> object as a typical example and
explain what each of its files contain.
Below is the directory structure and all the files related to the queue component.
<br/><br/>
<ul><li/> <b> file tree </b>
<ul>
<li/> dlib/
<ul>
<li/> queue.h
<li/> queue/
<ul>
<li/> queue_kernel_abstract.h
<li/> queue_kernel_1.h
<li/> queue_kernel_2.h
<li/> queue_kernel_c.h
<li/> queue_sort_abstract.h
<li/> queue_sort_1.h
</ul>
</ul>
</ul>
<br/>
<li/> <a href="dlib/queue.h.html">queue.h</a>
<ul> This file does not contain any executable code. All it does is define the typedefs such as
kernel_1a, kernel_1a_c, etc... for the queue object. See the <a href="#creating_objects">Creating Objects</a>
section to learn what these typedefs are for.
</ul>
<li/> <a href="dlib/queue/queue_kernel_abstract.h.html"> queue_kernel_abstract.h </a>
<ul>
This file does not contain any code. It even has preprocessor directives that prevent
any of its contents from being included.
<br/>
<br/>
The purpose of this file is to define exactly what a queue object does and what its
interface is.
</ul>
<li/> <a href="dlib/queue/queue_sort_abstract.h.html"> queue_sort_abstract.h </a>
<ul>
This file also doesn't contain any code. Its only purpose is to define the sort
extension to queue objects.
</ul>
<li/> <a href="dlib/queue/queue_kernel_1.h.html"> queue_kernel_1.h </a>
<ul>
This file contains an implementation of the queue kernel specification found
in queue_kernel_abstract.h
</ul>
<li/> <a href="dlib/queue/queue_kernel_2.h.html"> queue_kernel_2.h </a>
<ul>
This file contains another implementation of the queue kernel specification found
in queue_kernel_abstract.h
</ul>
<li/> <a href="dlib/queue/queue_sort_1.h.html"> queue_sort_1.h </a>
<ul>
This file contains an implementation of the queue sort extension specification found
in queue_sort_abstract.h
</ul>
<li/> <a href="dlib/queue/queue_kernel_c.h.html"> queue_kernel_c.h </a>
<ul>
This file contains a templated class which wraps any implementation of the queue kernel
specification. It is used during debugging to check that the requires clauses are never
violated.
</ul>
</ul>
</ul>
</ul>
<!-- **************************** CREATING OBJECTS SECTION **************************** -->
<anchor>creating_objects</anchor>
<h1>Creating Objects</h1>
<p>
To create many of the objects in this library you need to choose which kernel implementation you would like and if you
want the checking version or any extensions.
</p>
<p>
To make this easy there are header files which define typedefs of all this stuff. For
example, to create a queue of ints using queue kernel implementation 1 you would type
<tt>dlib::queue&lt;int&gt;::kernel_1a my_queue;</tt>. Or to get the debugging/checking version you
would type <tt>dlib::queue&lt;int&gt;::kernel_1a_c my_queue;</tt>.
</p>
<p>
There can be a lot of different typedefs for each component. You can find a list of them
in the section for the component in question. For the queue component they can be found
<a href="containers.html#queue">here</a>.
</p>
<p>
None of the above applies to the API components (or any global functions or objects that don't list multiple implemenations
in their documenation). To use/create them you just need to include
the appropriate headers. For example, to create a mutex object from the <a href="api.html#threads">
threads</a> component you would simply type <tt>dlib::mutex my_mutex;</tt>. There is no
need to specify which kernel implementation. The correct kernel implementation
is determined by which platform you compile under. There are also no explicit checking versions
of the API components. However, there are <a href="metaprogramming.html#DLIB_ASSERT">DLIB_ASSERT</a> statements that perform checking and you can
enable them by #defining DEBUG or ENABLE_ASSERTS.
</p>
<!-- **************************** ASSUMPTIONS SECTION **************************** -->
<h1>Assumptions</h1>
There are some restrictions on the behavior of certain objects or functions.
Rather than replicating these restrictions all over the place in my documentation they
are listed here.
<ul>
<li/> <b> global swap() </b>
<ul>
It is assumed that this operator does not throw. Undefined behavior results if it does.
Note that std::swap() for all intrinsics and std::string does not throw.
</ul>
<br/><li/> <b> operator&lt;() </b>
<ul>
It is assumed that this operator (or std::less or any similar functor supplied by you to the library)
does not throw. Undefined behavior results if it does.
</ul>
<br/><li/> <b> dlib::general_hash </b>
<ul>
It is assumed that general_hash does not throw. Undefined behavior results if it does.
This is actually noted in the general hash spec file but I'm listing it here also for good measure.
</ul>
</ul>
<!-- **************************** THREAD SAFETY SECTION **************************** -->
<anchor>thread_safety</anchor>
<h1>Thread Safety</h1>
<p>
In the library there are three kinds of objects with regards to threading. There are objects
that are completely thread safe. Then there are objects that are not thread safe but can be
used if access to them is serialized using a mutex. Lastly, there are objects which share
some kind of global resource or are reference counted. The last kind of object is
extremely thread unfriendly and can only be used in a threaded program with great care.
</p>
<p>
How do you know which components/objects are thread safe and which aren't? The rule is that if
the specification for the component doesn't mention threading or thread safety then
it is ok to use as long as you serialize access to it. If the component might have
some global resources or be reference counted then the specifications will tell you this.
And lastly if the component is thread safe then the specification will tell you this also.
</p>
</body>
<!-- ************************************************************************* -->
</doc>
<text>
The Canterbury Corpus
file size packed size bpb corruption
text: 152089 86995 4.576 no
play: 125179 75430 4.82062 no
html: 24603 16209 5.27058 no
Csrc: 11150 7084 5.08269 no
list: 3721 2224 4.78151 no
Excl: 1029744 440758 3.42421 no
tech: 426754 248345 4.65552 no
poem: 481861 273394 4.53897 no
fax: 513216 75036 1.16966 no
SPRC: 38240 25660 5.3682 no
man: 4227 2663 5.03998 no
average: 4.42981
time: 875ms
The Calgary Corpus
file size packed size bpb corruption
bib: 111261 72533 5.21534 no
book1: 768771 435527 4.53219 no
book2: 610856 364597 4.7749 no
geo: 102400 72600 5.67188 no
news: 377109 244377 5.18422 no
obj1: 21504 16183 6.02046 no
obj2: 246814 189902 6.15531 no
paper1: 53161 33144 4.98772 no
paper2: 82199 47398 4.613 no
pic: 513216 75036 1.16966 no
progc: 39611 25885 5.22784 no
progl: 71646 42688 4.76655 no
progp: 49379 30180 4.88953 no
trans: 93695 64603 5.51603 no
average: 4.9089
time: 1.11sec
The Artificial Corpus
file size packed size bpb corruption
a: 1 7 56 no
aaa: 100000 20 0.0016 no
alphabet: 100000 58912 4.71296 no
random: 100000 75202 6.01616 no
average: 16.6827
time: 93ms
The Large Corpus
file size packed size bpb corruption
E.coli: 4638690 1162352 2.00462 no
bible: 4047392 2194059 4.33674 no
word: 2473400 1542086 4.98774 no
average: 3.77637
time: 3.766sec
<text>
The Canterbury Corpus
file size packed size bpb corruption
text: 152089 86995 4.576 no
play: 125179 75430 4.82062 no
html: 24603 16209 5.27058 no
Csrc: 11150 7084 5.08269 no
list: 3721 2224 4.78151 no
Excl: 1029744 440758 3.42421 no
tech: 426754 248345 4.65552 no
poem: 481861 273394 4.53897 no
fax: 513216 75036 1.16966 no
SPRC: 38240 25660 5.3682 no
man: 4227 2663 5.03998 no
average: 4.42981
time: 875ms
The Calgary Corpus
file size packed size bpb corruption
bib: 111261 72533 5.21534 no
book1: 768771 435527 4.53219 no
book2: 610856 364597 4.7749 no
geo: 102400 72600 5.67188 no
news: 377109 244377 5.18422 no
obj1: 21504 16183 6.02046 no
obj2: 246814 189902 6.15531 no
paper1: 53161 33144 4.98772 no
paper2: 82199 47398 4.613 no
pic: 513216 75036 1.16966 no
progc: 39611 25885 5.22784 no
progl: 71646 42688 4.76655 no
progp: 49379 30180 4.88953 no
trans: 93695 64603 5.51603 no
average: 4.9089
time: 1.11sec
The Artificial Corpus
file size packed size bpb corruption
a: 1 7 56 no
aaa: 100000 20 0.0016 no
alphabet: 100000 58912 4.71296 no
random: 100000 75202 6.01616 no
average: 16.6827
time: 93ms
The Large Corpus
file size packed size bpb corruption
E.coli: 4638690 1162352 2.00462 no
bible: 4047392 2194059 4.33674 no
word: 2473400 1542086 4.98774 no
average: 3.77637
time: 3.766sec
</text>
\ No newline at end of file
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>kernel_1a</title>
<body from_file="kernel_1a.txt"/>
<menu from_file="compression.xml"/>
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>kernel_1a</title>
<body from_file="kernel_1a.txt"/>
<menu from_file="compression.xml"/>
</doc>
<text>
The Canterbury Corpus
file size packed size bpb corruption
text: 152089 66165 3.48033 no
play: 125179 54572 3.48761 no
html: 24603 11661 3.79173 no
Csrc: 11150 4733 3.39587 no
list: 3721 1629 3.50228 no
Excl: 1029744 343447 2.66821 no
tech: 426754 188332 3.5305 no
poem: 481861 204240 3.39085 no
fax: 513216 54127 0.843731 no
SPRC: 38240 18307 3.82992 no
man: 4227 2100 3.97445 no
average: 3.26323
time: 844ms
The Calgary Corpus
file size packed size bpb corruption
bib: 111261 48130 3.46069 no
book1: 768771 346572 3.6065 no
book2: 610856 288605 3.77968 no
geo: 102400 61124 4.77531 no
news: 377109 196085 4.15975 no
obj1: 21504 12445 4.62984 no
obj2: 246814 127142 4.12106 no
paper1: 53161 25438 3.82807 no
paper2: 82199 37295 3.62973 no
pic: 513216 54127 0.843731 no
progc: 39611 19090 3.85549 no
progl: 71646 29773 3.32446 no
progp: 49379 20795 3.36904 no
trans: 93695 40922 3.49406 no
average: 3.6341
time: 1.109sec
The Artificial Corpus
file size packed size bpb corruption
a: 1 7 56 no
aaa: 100000 20 0.0016 no
alphabet: 100000 83 0.00664 no
random: 100000 77775 6.222 no
average: 15.5576
time: 94ms
The Large Corpus
file size packed size bpb corruption
E.coli: 4638690 1151913 1.98662 no
bible: 4047392 1651476 3.26428 no
word: 2473400 1133090 3.66488 no
average: 2.97193
time: 3.672sec
<text>
The Canterbury Corpus
file size packed size bpb corruption
text: 152089 66165 3.48033 no
play: 125179 54572 3.48761 no
html: 24603 11661 3.79173 no
Csrc: 11150 4733 3.39587 no
list: 3721 1629 3.50228 no
Excl: 1029744 343447 2.66821 no
tech: 426754 188332 3.5305 no
poem: 481861 204240 3.39085 no
fax: 513216 54127 0.843731 no
SPRC: 38240 18307 3.82992 no
man: 4227 2100 3.97445 no
average: 3.26323
time: 844ms
The Calgary Corpus
file size packed size bpb corruption
bib: 111261 48130 3.46069 no
book1: 768771 346572 3.6065 no
book2: 610856 288605 3.77968 no
geo: 102400 61124 4.77531 no
news: 377109 196085 4.15975 no
obj1: 21504 12445 4.62984 no
obj2: 246814 127142 4.12106 no
paper1: 53161 25438 3.82807 no
paper2: 82199 37295 3.62973 no
pic: 513216 54127 0.843731 no
progc: 39611 19090 3.85549 no
progl: 71646 29773 3.32446 no
progp: 49379 20795 3.36904 no
trans: 93695 40922 3.49406 no
average: 3.6341
time: 1.109sec
The Artificial Corpus
file size packed size bpb corruption
a: 1 7 56 no
aaa: 100000 20 0.0016 no
alphabet: 100000 83 0.00664 no
random: 100000 77775 6.222 no
average: 15.5576
time: 94ms
The Large Corpus
file size packed size bpb corruption
E.coli: 4638690 1151913 1.98662 no
bible: 4047392 1651476 3.26428 no
word: 2473400 1133090 3.66488 no
average: 2.97193
time: 3.672sec
</text>
\ No newline at end of file
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>kernel_1b</title>
<body from_file="kernel_1b.txt"/>
<menu from_file="compression.xml"/>
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>kernel_1b</title>
<body from_file="kernel_1b.txt"/>
<menu from_file="compression.xml"/>
</doc>
<text>
The Canterbury Corpus
file size packed size bpb corruption
text: 152089 51810 2.72525 no
play: 125179 44002 2.8121 no
html: 24603 8602 2.79706 no
Csrc: 11150 3399 2.43874 no
list: 3721 1272 2.73475 no
Excl: 1029744 237165 1.84252 no
tech: 426754 147090 2.75737 no
poem: 481861 169981 2.82208 no
fax: 513216 54230 0.845336 no
SPRC: 38240 15190 3.17782 no
man: 4227 1763 3.33665 no
average: 2.57179
time: 1.031sec
The Calgary Corpus
file size packed size bpb corruption
bib: 111261 37264 2.67939 no
book1: 768771 280052 2.91428 no
book2: 610856 221616 2.90237 no
geo: 102400 62115 4.85273 no
news: 377109 155282 3.29416 no
obj1: 21504 11235 4.17969 no
obj2: 246814 97319 3.15441 no
paper1: 53161 19664 2.95916 no
paper2: 82199 29837 2.90388 no
pic: 513216 54230 0.845336 no
progc: 39611 14610 2.9507 no
progl: 71646 21637 2.41599 no
progp: 49379 14204 2.30122 no
trans: 93695 27848 2.37776 no
average: 2.90936
time: 1.297sec
The Artificial Corpus
file size packed size bpb corruption
a: 1 7 56 no
aaa: 100000 18 0.00144 no
alphabet: 100000 65 0.0052 no
random: 100000 90704 7.25632 no
average: 15.8157
time: 203ms
The Large Corpus
file size packed size bpb corruption
E.coli: 4638690 1141437 1.96855 no
bible: 4047392 1263237 2.49689 no
word: 2473400 876621 2.83536 no
average: 2.4336
time: 3.391sec
<text>
The Canterbury Corpus
file size packed size bpb corruption
text: 152089 51810 2.72525 no
play: 125179 44002 2.8121 no
html: 24603 8602 2.79706 no
Csrc: 11150 3399 2.43874 no
list: 3721 1272 2.73475 no
Excl: 1029744 237165 1.84252 no
tech: 426754 147090 2.75737 no
poem: 481861 169981 2.82208 no
fax: 513216 54230 0.845336 no
SPRC: 38240 15190 3.17782 no
man: 4227 1763 3.33665 no
average: 2.57179
time: 1.031sec
The Calgary Corpus
file size packed size bpb corruption
bib: 111261 37264 2.67939 no
book1: 768771 280052 2.91428 no
book2: 610856 221616 2.90237 no
geo: 102400 62115 4.85273 no
news: 377109 155282 3.29416 no
obj1: 21504 11235 4.17969 no
obj2: 246814 97319 3.15441 no
paper1: 53161 19664 2.95916 no
paper2: 82199 29837 2.90388 no
pic: 513216 54230 0.845336 no
progc: 39611 14610 2.9507 no
progl: 71646 21637 2.41599 no
progp: 49379 14204 2.30122 no
trans: 93695 27848 2.37776 no
average: 2.90936
time: 1.297sec
The Artificial Corpus
file size packed size bpb corruption
a: 1 7 56 no
aaa: 100000 18 0.00144 no
alphabet: 100000 65 0.0052 no
random: 100000 90704 7.25632 no
average: 15.8157
time: 203ms
The Large Corpus
file size packed size bpb corruption
E.coli: 4638690 1141437 1.96855 no
bible: 4047392 1263237 2.49689 no
word: 2473400 876621 2.83536 no
average: 2.4336
time: 3.391sec
</text>
\ No newline at end of file
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>kernel_1c</title>
<body from_file="kernel_1c.txt"/>
<menu from_file="compression.xml"/>
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>kernel_1c</title>
<body from_file="kernel_1c.txt"/>
<menu from_file="compression.xml"/>
</doc>
<text>
The Canterbury Corpus
file size packed size bpb corruption
text: 152089 45580 2.39754 no
play: 125179 42432 2.71176 no
html: 24603 7745 2.51839 no
Csrc: 11150 3165 2.27085 no
list: 3721 1238 2.66165 no
Excl: 1029744 194875 1.51397 no
tech: 426754 111838 2.09653 no
poem: 481861 148110 2.45897 no
fax: 513216 56075 0.874096 no
SPRC: 38240 14248 2.98075 no
man: 4227 1736 3.28555 no
average: 2.34273
time: 1.812sec
The Calgary Corpus
file size packed size bpb corruption
bib: 111261 29161 2.09676 no
book1: 768771 235667 2.4524 no
book2: 610856 165032 2.16132 no
geo: 102400 67663 5.28617 no
news: 377109 128148 2.71853 no
obj1: 21504 10750 3.99926 no
obj2: 246814 82894 2.68685 no
paper1: 53161 17398 2.61816 no
paper2: 82199 26449 2.57414 no
pic: 513216 56075 0.874096 no
progc: 39611 13188 2.6635 no
progl: 71646 17135 1.9133 no
progp: 49379 11764 1.90591 no
trans: 93695 19602 1.67369 no
average: 2.54458
time: 2.36sec
The Artificial Corpus
file size packed size bpb corruption
a: 1 6 48 no
aaa: 100000 19 0.00152 no
alphabet: 100000 66 0.00528 no
random: 100000 89652 7.17216 no
average: 13.7947
time: 375ms
The Large Corpus
file size packed size bpb corruption
E.coli: 4638690 1130363 1.94945 no
bible: 4047392 871537 1.72266 no
word: 2473400 589688 1.9073 no
average: 1.8598
time: 4.484sec
<text>
The Canterbury Corpus
file size packed size bpb corruption
text: 152089 45580 2.39754 no
play: 125179 42432 2.71176 no
html: 24603 7745 2.51839 no
Csrc: 11150 3165 2.27085 no
list: 3721 1238 2.66165 no
Excl: 1029744 194875 1.51397 no
tech: 426754 111838 2.09653 no
poem: 481861 148110 2.45897 no
fax: 513216 56075 0.874096 no
SPRC: 38240 14248 2.98075 no
man: 4227 1736 3.28555 no
average: 2.34273
time: 1.812sec
The Calgary Corpus
file size packed size bpb corruption
bib: 111261 29161 2.09676 no
book1: 768771 235667 2.4524 no
book2: 610856 165032 2.16132 no
geo: 102400 67663 5.28617 no
news: 377109 128148 2.71853 no
obj1: 21504 10750 3.99926 no
obj2: 246814 82894 2.68685 no
paper1: 53161 17398 2.61816 no
paper2: 82199 26449 2.57414 no
pic: 513216 56075 0.874096 no
progc: 39611 13188 2.6635 no
progl: 71646 17135 1.9133 no
progp: 49379 11764 1.90591 no
trans: 93695 19602 1.67369 no
average: 2.54458
time: 2.36sec
The Artificial Corpus
file size packed size bpb corruption
a: 1 6 48 no
aaa: 100000 19 0.00152 no
alphabet: 100000 66 0.00528 no
random: 100000 89652 7.17216 no
average: 13.7947
time: 375ms
The Large Corpus
file size packed size bpb corruption
E.coli: 4638690 1130363 1.94945 no
bible: 4047392 871537 1.72266 no
word: 2473400 589688 1.9073 no
average: 1.8598
time: 4.484sec
</text>
\ No newline at end of file
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>kernel_1da</title>
<body from_file="kernel_1da.txt"/>
<menu from_file="compression.xml"/>
</doc>
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="stylesheet.xsl"?>
<doc>
<title>kernel_1da</title>
<body from_file="kernel_1da.txt"/>
<menu from_file="compression.xml"/>
</doc>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment