[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gnash-commit
Subject:    [Gnash-commit] gnash ./ChangeLog backend/gnash.cpp server/Func...
From:       strk <strk () keybit ! net>
Date:       2006-02-26 21:44:54
Message-ID: E1FDThG-0004M5-8d () savannah ! gnu ! org
[Download RAW message or body]

CVSROOT:	/sources/gnash
Module name:	gnash
Branch: 	
Changes by:	strk <strk@savannah.gnu.org>	06/02/26 21:44:53

Modified files:
	.              : ChangeLog 
	backend        : gnash.cpp 
	server         : Function.cpp Movie.cpp Movie.h 
	                 MovieClipLoader.cpp Sprite.cpp Sprite.h 
	                 action.cpp action.h button.cpp button.h 
	                 font.cpp font.h fontlib.cpp fontlib.h gnash.h 
	                 impl.cpp impl.h morph.cpp morph.h morph2.cpp 
	                 morph2.h shape.cpp shape.h sound.cpp styles.cpp 
	                 styles.h text.cpp text.h 
	testsuite/actionscript.all: Makefile.am 
	utilities      : processor.cpp 

Log message:
	* server/action.cpp: fixed bug in doActionCallFunction making
	samples/slider.swf play fine.
	* server/: merged movie_definition_sub into
	movie_definition.
	* testsuite/actionscript.all/Makefile.am: provided
	OUTPUT_VERSION define for *.swf and *.vswf rules

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/ChangeLog.diff?tr1=1.160&tr2=1.161&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/backend/gnash.cpp.diff?tr1=1.11&tr2=1.12&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/Function.cpp.diff?tr1=1.7&tr2=1.8&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/Movie.cpp.diff?tr1=1.7&tr2=1.8&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/Movie.h.diff?tr1=1.6&tr2=1.7&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/MovieClipLoader.cpp.diff?tr1=1.9&tr2=1.10&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/Sprite.cpp.diff?tr1=1.14&tr2=1.15&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/Sprite.h.diff?tr1=1.8&tr2=1.9&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/action.cpp.diff?tr1=1.51&tr2=1.52&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/action.h.diff?tr1=1.22&tr2=1.23&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/button.cpp.diff?tr1=1.5&tr2=1.6&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/button.h.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/font.cpp.diff?tr1=1.5&tr2=1.6&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/font.h.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/fontlib.cpp.diff?tr1=1.4&tr2=1.5&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/fontlib.h.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/gnash.h.diff?tr1=1.12&tr2=1.13&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/impl.cpp.diff?tr1=1.20&tr2=1.21&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/impl.h.diff?tr1=1.12&tr2=1.13&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/morph.cpp.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/morph.h.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/morph2.cpp.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/morph2.h.diff?tr1=1.1&tr2=1.2&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/shape.cpp.diff?tr1=1.8&tr2=1.9&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/shape.h.diff?tr1=1.4&tr2=1.5&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/sound.cpp.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/styles.cpp.diff?tr1=1.5&tr2=1.6&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/styles.h.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/text.cpp.diff?tr1=1.7&tr2=1.8&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/text.h.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/testsuite/actionscript.all/Makefile.am.diff?tr1=1.16&tr2=1.17&r1=text&r2=text
 http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/utilities/processor.cpp.diff?tr1=1.4&tr2=1.5&r1=text&r2=text


Patches:
Index: gnash/ChangeLog
diff -u gnash/ChangeLog:1.160 gnash/ChangeLog:1.161
--- gnash/ChangeLog:1.160	Sun Feb 26 15:49:29 2006
+++ gnash/ChangeLog	Sun Feb 26 21:44:53 2006
@@ -1,3 +1,12 @@
+2006-02-26 Sandro Santilli <strk@keybit.net>
+
+	* server/action.cpp: fixed bug in doActionCallFunction making
+	samples/slider.swf play fine.
+	* server/: merged movie_definition_sub into
+	movie_definition.
+	* testsuite/actionscript.all/Makefile.am: provided
+	OUTPUT_VERSION define for *.swf and *.vswf rules
+
 2006-02-26  Rob Savoye  <rob@wharfrat.welcomehome.org>
 
 	* libbase/dlmalloc.h: Include stdlib.h instead of the depreciated
Index: gnash/backend/gnash.cpp
diff -u gnash/backend/gnash.cpp:1.11 gnash/backend/gnash.cpp:1.12
--- gnash/backend/gnash.cpp:1.11	Thu Feb 23 02:50:47 2006
+++ gnash/backend/gnash.cpp	Sun Feb 26 21:44:53 2006
@@ -33,6 +33,7 @@
 #include "tu_file.h"
 #include "tu_types.h"
 #include "xmlsocket.h"
+#include "Movie.h"
 
 bool gofast = false;		// FIXME: this flag gets set based on
 				// an XML message written using
Index: gnash/server/Function.cpp
diff -u gnash/server/Function.cpp:1.7 gnash/server/Function.cpp:1.8
--- gnash/server/Function.cpp:1.7	Sat Feb 25 03:54:03 2006
+++ gnash/server/Function.cpp	Sun Feb 26 21:44:53 2006
@@ -155,11 +155,8 @@
 			our_env->add_local(m_args[i].m_name, fn.arg(i));
 		}
 
-		// Set up local variable 'this'.
-		//    --strk(2006-02-07);
 		assert(fn.this_ptr);
 		our_env->set_local("this", fn.this_ptr);
-
 	}
 	else
 	{
Index: gnash/server/Movie.cpp
diff -u gnash/server/Movie.cpp:1.7 gnash/server/Movie.cpp:1.8
--- gnash/server/Movie.cpp:1.7	Sat Feb 25 03:54:03 2006
+++ gnash/server/Movie.cpp	Sun Feb 26 21:44:53 2006
@@ -157,7 +157,7 @@
 	    // it?  Compare a member function pointer, or
 	    // something?
 	    movie_def_impl*	def_impl = static_cast<movie_def_impl*>(source_movie);
-	    movie_definition_sub*	def = static_cast<movie_definition_sub*>(def_impl);
+	    movie_definition*	def = static_cast<movie_definition*>(def_impl);
 
 	    // Iterate in reverse, since we remove stuff along the way.
 	    for (int i = m_imports.size() - 1; i >= 0; i--)
@@ -411,7 +411,7 @@
 			    int	id = it->first;
 
 			    // Insert in correct place.
-			    unsigned int	insert;
+			    unsigned int insert;
 			    for (insert = 0; insert < font_ids.size(); insert++)
 				{
 				    if (font_ids[insert] > id)
@@ -761,4 +761,28 @@
 	    return m_movie->call_method_args(method_name, method_arg_fmt, args);
 	}
 
+
+void
+movieclip_init(as_object* global)
+{
+#if 0
+	// This is going to be the global MovieClip "class"/"function"
+	static function_as_object *func=new function_as_object();
+
+	// We make the 'prototype' element be a reference to
+	// the __proto__ element
+	as_object* proto = func->m_prototype;
+	proto->add_ref();
+
+	proto->set_member("constructor", func); //as_value(func));
+	proto->set_member_flags("constructor", 1);
+
+	func->set_member("prototype", as_value(proto));
+
+	// Register _global.Function
+	global->set_member("Function", func);
+#endif
+}
+
 } // namespace gnash
+
Index: gnash/server/Movie.h
diff -u gnash/server/Movie.h:1.6 gnash/server/Movie.h:1.7
--- gnash/server/Movie.h:1.6	Sat Feb 25 03:54:03 2006
+++ gnash/server/Movie.h	Sun Feb 26 21:44:53 2006
@@ -39,7 +39,6 @@
 #define GNASH_MOVIE_H
 
 #include "container.h"
-#include "impl.h" // for movie_definition_sub
 #include "button.h" // for mouse_button_state
 #include "timers.h" // for Timer
 #include "fontlib.h"
@@ -53,6 +52,7 @@
 	struct import_info;
 	struct movie_def_impl;
 	struct movie_root;
+	struct import_visitor; // in gnash.h
 
 	//
 	// Helper for movie_def_impl
@@ -78,264 +78,388 @@
 		}
 	};
 
-
-	/// Immutable definition of a movie's contents.
+/// Client program's interface to the definition of a movie
+//
+/// (i.e. the shared constant source info).
+///
+struct movie_definition : public character_def
+{
+	virtual int	get_version() const = 0;
+	virtual float	get_width_pixels() const = 0;
+	virtual float	get_height_pixels() const = 0;
+	virtual int	get_frame_count() const = 0;
+	virtual float	get_frame_rate() const = 0;
+	
+	/// Create a playable movie instance from a def.
 	//
-	/// It cannot be played directly, and does not hold
-	/// current state; for that you need to call create_instance()
-	/// to get a movie_instance (movie_interface).
+	/// This calls add_ref() on the movie_interface internally.
+	/// Call drop_ref() on the movie_interface when you're done with it.
+	/// Or use smart_ptr<T> from base/smart_ptr.h if you want.
 	///
-	struct movie_def_impl : public movie_definition_sub
+	virtual movie_interface*	create_instance() = 0;
+	
+	virtual void	output_cached_data(tu_file* out, const cache_options& options) = 0;
+	virtual void	input_cached_data(tu_file* in) = 0;
+	
+	/// \brief
+	/// Causes this movie def to generate texture-mapped
+	/// versions of all the fonts it owns. 
+	//
+	/// This improves
+	/// speed and quality of text rendering.  The
+	/// texture-map data is serialized in the
+	/// output/input_cached_data() calls, so you can
+	/// preprocess this if you load cached data.
+	///
+	virtual void	generate_font_bitmaps() = 0;
+	
+	//
+	// (optional) API to support gnash::create_movie_no_recurse().
+	//
+	
+	/// \brief
+	/// Call visit_imported_movies() to retrieve a list of
+	/// names of movies imported into this movie.
+	//
+	/// visitor->visit() will be called back with the name
+	/// of each imported movie.
+	struct import_visitor
 	{
-		hash<int, smart_ptr<character_def> >		m_characters;
-		hash<int, smart_ptr<font> >	 		m_fonts;
-		hash<int, smart_ptr<bitmap_character_def> >	m_bitmap_characters;
-		hash<int, smart_ptr<sound_sample> >		m_sound_samples;
-
-		/// A list of movie control events for each frame.
-		std::vector<std::vector<execute_tag*> >	   		m_playlist;
-
-		/// Init actions for each frame.
-		std::vector<std::vector<execute_tag*> >	   m_init_action_list;
-
-		/// 0-based frame #'s
-		stringi_hash<int>	           m_named_frames;
-
-		stringi_hash<smart_ptr<resource> > m_exports;
+	    virtual ~import_visitor() {}
+	    virtual void	visit(const char* imported_movie_filename) = 0;
+	};
+	virtual void	visit_imported_movies(import_visitor* visitor) = 0;
+	
+	/// Call this to resolve an import of the given movie.
+	/// Replaces the dummy placeholder with the real
+	/// movie_definition* given.
+	virtual void	resolve_import(const char* name, movie_definition* def) = 0;
+	
+	//
+	// (optional) API to support host-driven creation of textures.
+	//
+	// Create the movie using gnash::create_movie_no_recurse(..., DO_NOT_LOAD_BITMAPS),
+	// and then initialize each bitmap info via get_bitmap_info_count(), \
get_bitmap_info(), +	// and bitmap_info::init_*_image() or your own subclassed API.
+	//
+	// E.g.:
+	//
+	// // During preprocessing:
+	// // This will create bitmap_info's using the rgba, rgb, alpha contructors.
+	// my_def = gnash::create_movie_no_recurse("myfile.swf", DO_LOAD_BITMAPS);
+	// int ct = my_def->get_bitmap_info_count();
+	// for (int i = 0; i < ct; i++)
+	// {
+	//	my_bitmap_info_subclass*	bi = NULL;
+	//	my_def->get_bitmap_info(i, (bitmap_info**) &bi);
+	//	my_precomputed_textures.push_back(bi->m_my_internal_texture_reference);
+	// }
+	// // Save out my internal data.
+	// my_precomputed_textures->write_into_some_cache_stream(...);
+	//
+	// // Later, during run-time loading:
+	// my_precomputed_textures->read_from_some_cache_stream(...);
+	// // This will create blank bitmap_info's.
+	// my_def = gnash::create_movie_no_recurse("myfile.swf", DO_NOT_LOAD_BITMAPS);
+	// 
+	// // Push cached texture info into the movie's bitmap_info structs.
+	// int	ct = my_def->get_bitmap_info_count();
+	// for (int i = 0; i < ct; i++)
+	// {
+	//	my_bitmap_info_subclass*	bi = (my_bitmap_info_subclass*) \
my_def->get_bitmap_info(i); \
+	//	bi->set_internal_texture_reference(my_precomputed_textures[i]); +	// }
+	virtual int	get_bitmap_info_count() const = 0;
+	virtual bitmap_info*	get_bitmap_info(int i) const = 0;
+
+	// From movie_definition_sub
+
+	virtual const std::vector<execute_tag*>&	get_playlist(int frame_number) = 0;
+	virtual const std::vector<execute_tag*>*	get_init_actions(int frame_number) = 0;
+	virtual smart_ptr<resource>	get_exported_resource(const tu_string& symbol) = 0;
+	virtual character_def*	get_character_def(int id) = 0;
+
+	virtual bool	get_labeled_frame(const char* label, int* frame_number) = 0;
+
+	// For use during creation.
+	virtual int	get_loading_frame() const = 0;
+	virtual void	add_character(int id, character_def* ch) = 0;
+	virtual void	add_font(int id, font* ch) = 0;
+	virtual font*	get_font(int id) = 0;
+	virtual void	add_execute_tag(execute_tag* c) = 0;
+	virtual void	add_init_action(int sprite_id, execute_tag* c) = 0;
+	virtual void	add_frame_name(const char* name) = 0;
+	virtual void	set_jpeg_loader(jpeg::input* j_in) = 0;
+	virtual jpeg::input*	get_jpeg_loader() = 0;
+	virtual bitmap_character_def*	get_bitmap_character(int character_id) = 0;
+	virtual void	add_bitmap_character(int character_id, bitmap_character_def* ch) = 0;
+	virtual sound_sample*	get_sound_sample(int character_id) = 0;
+	virtual void	add_sound_sample(int character_id, sound_sample* sam) = 0;
+	virtual void	export_resource(const tu_string& symbol, resource* res) = 0;
+	virtual void	add_import(const char* source_url, int id, const char* symbol_name) = \
0; +	virtual void	add_bitmap_info(bitmap_info* ch) = 0;
+
+	virtual create_bitmaps_flag	get_create_bitmaps() const = 0;
+	virtual create_font_shapes_flag	get_create_font_shapes() const = 0;
+};
+
+/// Immutable definition of a movie's contents.
+//
+/// It cannot be played directly, and does not hold
+/// current state; for that you need to call create_instance()
+/// to get a movie_instance (movie_interface).
+///
+struct movie_def_impl : public movie_definition
+{
+	hash<int, smart_ptr<character_def> >		m_characters;
+	hash<int, smart_ptr<font> >	 		m_fonts;
+	hash<int, smart_ptr<bitmap_character_def> >	m_bitmap_characters;
+	hash<int, smart_ptr<sound_sample> >		m_sound_samples;
 
-		/// Items we import.
-		std::vector<import_info>	m_imports;
+	/// A list of movie control events for each frame.
+	std::vector<std::vector<execute_tag*> >	   	m_playlist;
 
-		/// Movies we import from; hold a ref on these,
-		/// to keep them alive
-		std::vector<smart_ptr<movie_definition> >	m_import_source_movies;
+	/// Init actions for each frame.
+	std::vector<std::vector<execute_tag*> >	   m_init_action_list;
 
-		/// Bitmaps used in this movie; collected in one place to make
-		/// it possible for the host to manage them as textures.
-		std::vector<smart_ptr<bitmap_info> >	m_bitmap_list;
+	/// 0-based frame #'s
+	stringi_hash<int> m_named_frames;
 
-		create_bitmaps_flag	m_create_bitmaps;
-		create_font_shapes_flag	m_create_font_shapes;
+	stringi_hash<smart_ptr<resource> > m_exports;
 
-		rect	m_frame_size;
-		float	m_frame_rate;
-		int	m_frame_count;
-		int	m_version;
-		int	m_loading_frame;
-		uint32	m_file_length;
+	/// Items we import.
+	std::vector<import_info> m_imports;
 
-		jpeg::input*	m_jpeg_in;
+	/// Movies we import from; hold a ref on these,
+	/// to keep them alive
+	std::vector<smart_ptr<movie_definition> > m_import_source_movies;
 
-		movie_def_impl(create_bitmaps_flag cbf,
-				create_font_shapes_flag cfs)
-			:
-			m_create_bitmaps(cbf),
-			m_create_font_shapes(cfs),
-			m_frame_rate(30.0f),
-			m_frame_count(0),
-			m_version(0),
-			m_loading_frame(0),
-			m_jpeg_in(0)
-			{
-			}
+	/// Bitmaps used in this movie; collected in one place to make
+	/// it possible for the host to manage them as textures.
+	std::vector<smart_ptr<bitmap_info> >	m_bitmap_list;
 
-		~movie_def_impl();
+	create_bitmaps_flag	m_create_bitmaps;
+	create_font_shapes_flag	m_create_font_shapes;
 
-		// ...
-		int	get_frame_count() const { return m_frame_count; }
-		float	get_frame_rate() const { return m_frame_rate; }
+	rect	m_frame_size;
+	float	m_frame_rate;
+	int	m_frame_count;
+	int	m_version;
+	int	m_loading_frame;
+	uint32	m_file_length;
 
-		float	get_width_pixels() const
-		{
-			return ceilf(TWIPS_TO_PIXELS(m_frame_size.width()));
-		}
+	jpeg::input*	m_jpeg_in;
 
-		float	get_height_pixels() const
+	movie_def_impl(create_bitmaps_flag cbf,
+			create_font_shapes_flag cfs)
+		:
+		m_create_bitmaps(cbf),
+		m_create_font_shapes(cfs),
+		m_frame_rate(30.0f),
+		m_frame_count(0),
+		m_version(0),
+		m_loading_frame(0),
+		m_jpeg_in(0)
 		{
-			return ceilf(TWIPS_TO_PIXELS(m_frame_size.height()));
 		}
 
-		virtual int	get_version() const { return m_version; }
+	~movie_def_impl();
 
-		virtual int	get_loading_frame() const
-		{
-			return m_loading_frame;
-		}
+	// ...
+	int	get_frame_count() const { return m_frame_count; }
+	float	get_frame_rate() const { return m_frame_rate; }
 
-		uint32	get_file_bytes() const { return m_file_length; }
+	float	get_width_pixels() const
+	{
+		return ceilf(TWIPS_TO_PIXELS(m_frame_size.width()));
+	}
 
-		/// Returns DO_CREATE_BITMAPS if we're supposed to
-		/// initialize our bitmap infos, or DO_NOT_INIT_BITMAPS
-		/// if we're supposed to create blank placeholder
-		/// bitmaps (to be init'd later explicitly by the host
-		/// program).
-		virtual create_bitmaps_flag get_create_bitmaps() const
-		{
-	    		return m_create_bitmaps;
-		}
+	float	get_height_pixels() const
+	{
+		return ceilf(TWIPS_TO_PIXELS(m_frame_size.height()));
+	}
 
-		/// Returns DO_LOAD_FONT_SHAPES if we're supposed to
-		/// initialize our font shape info, or
-		/// DO_NOT_LOAD_FONT_SHAPES if we're supposed to not
-		/// create any (vector) font glyph shapes, and instead
-		/// rely on precached textured fonts glyphs.
-		virtual create_font_shapes_flag	get_create_font_shapes() const
-		{
-		    return m_create_font_shapes;
-		}
+	virtual int	get_version() const { return m_version; }
 
-		/// All bitmap_info's used by this movie should be
-		/// registered with this API.
-		virtual void	add_bitmap_info(bitmap_info* bi)
-		{
-		    m_bitmap_list.push_back(bi);
-		}
+	virtual int	get_loading_frame() const
+	{
+		return m_loading_frame;
+	}
 
-		virtual int get_bitmap_info_count() const
-		{
-			return m_bitmap_list.size();
-		}
+	uint32	get_file_bytes() const { return m_file_length; }
 
-		virtual bitmap_info*	get_bitmap_info(int i) const
-		{
-			return m_bitmap_list[i].get_ptr();
-		}
-
-		/// Expose one of our resources under the given symbol,
-		/// for export.  Other movies can import it.
-		virtual void export_resource(const tu_string& symbol,
-				resource* res)
-		{
-		    // SWF sometimes exports the same thing more than once!
-		    m_exports.set(symbol, res);
-		}
+	/// Returns DO_CREATE_BITMAPS if we're supposed to
+	/// initialize our bitmap infos, or DO_NOT_INIT_BITMAPS
+	/// if we're supposed to create blank placeholder
+	/// bitmaps (to be init'd later explicitly by the host
+	/// program).
+	virtual create_bitmaps_flag get_create_bitmaps() const
+	{
+		return m_create_bitmaps;
+	}
 
-		/// Get the named exported resource, if we expose it.
-		/// Otherwise return NULL.
-		virtual smart_ptr<resource> get_exported_resource(const tu_string& symbol)
-		{
-		    smart_ptr<resource>	res;
-		    m_exports.get(symbol, &res);
-		    return res;
-		}
+	/// Returns DO_LOAD_FONT_SHAPES if we're supposed to
+	/// initialize our font shape info, or
+	/// DO_NOT_LOAD_FONT_SHAPES if we're supposed to not
+	/// create any (vector) font glyph shapes, and instead
+	/// rely on precached textured fonts glyphs.
+	virtual create_font_shapes_flag	get_create_font_shapes() const
+	{
+	    return m_create_font_shapes;
+	}
 
-		/// Adds an entry to a table of resources that need to
-		/// be imported from other movies.  Client code must
-		/// call resolve_import() later, when the source movie
-		/// has been loaded, so that the actual resource can be
-		/// used.
-		virtual void add_import(const char* source_url, int id, const char* symbol)
-		{
-		    assert(in_import_table(id) == false);
+	/// All bitmap_info's used by this movie should be
+	/// registered with this API.
+	virtual void	add_bitmap_info(bitmap_info* bi)
+	{
+	    m_bitmap_list.push_back(bi);
+	}
 
-		    m_imports.push_back(import_info(source_url, id, symbol));
-		}
+	virtual int get_bitmap_info_count() const
+	{
+		return m_bitmap_list.size();
+	}
 
-		/// Debug helper; returns true if the given
-		/// character_id is listed in the import table.
-    		bool in_import_table(int character_id);
+	virtual bitmap_info*	get_bitmap_info(int i) const
+	{
+		return m_bitmap_list[i].get_ptr();
+	}
 
-		/// Calls back the visitor for each movie that we
-		/// import symbols from.
-		virtual void visit_imported_movies(import_visitor* visitor);
+	/// Expose one of our resources under the given symbol,
+	/// for export.  Other movies can import it.
+	virtual void export_resource(const tu_string& symbol,
+			resource* res)
+	{
+	    // SWF sometimes exports the same thing more than once!
+	    m_exports.set(symbol, res);
+	}
+
+	/// Get the named exported resource, if we expose it.
+	/// Otherwise return NULL.
+	virtual smart_ptr<resource> get_exported_resource(const tu_string& symbol)
+	{
+	    smart_ptr<resource>	res;
+	    m_exports.get(symbol, &res);
+	    return res;
+	}
+
+	/// Adds an entry to a table of resources that need to
+	/// be imported from other movies.  Client code must
+	/// call resolve_import() later, when the source movie
+	/// has been loaded, so that the actual resource can be
+	/// used.
+	virtual void add_import(const char* source_url, int id, const char* symbol)
+	{
+	    assert(in_import_table(id) == false);
 
-		/// Grabs the stuff we want from the source movie.
-		virtual void resolve_import(const char* source_url,
-			movie_definition* source_movie);
+	    m_imports.push_back(import_info(source_url, id, symbol));
+	}
 
-		void add_character(int character_id, character_def* c);
+	/// Debug helper; returns true if the given
+	/// character_id is listed in the import table.
+	bool in_import_table(int character_id);
 
-		character_def*	get_character_def(int character_id);
+	/// Calls back the visitor for each movie that we
+	/// import symbols from.
+	virtual void visit_imported_movies(import_visitor* visitor);
 
-		/// Returns 0-based frame #
-		bool get_labeled_frame(const char* label, int* frame_number)
-		{
-	    		return m_named_frames.get(label, frame_number);
-		}
+	/// Grabs the stuff we want from the source movie.
+	virtual void resolve_import(const char* source_url,
+		movie_definition* source_movie);
 
-    		void	add_font(int font_id, font* f);
-    		font*	get_font(int font_id);
-    		bitmap_character_def*	get_bitmap_character(int character_id);
-    		void	add_bitmap_character(int character_id, bitmap_character_def* ch);
-    		sound_sample*	get_sound_sample(int character_id);
-    		virtual void	add_sound_sample(int character_id, sound_sample* sam);
+	void add_character(int character_id, character_def* c);
 
-		/// Add an execute_tag to this movie_definition's playlist
-		void	add_execute_tag(execute_tag* e)
-		{
-		    assert(e);
-		    m_playlist[m_loading_frame].push_back(e);
-		}
+	character_def*	get_character_def(int character_id);
 
-		/// Need to execute the given tag before entering the
-		/// currently-loading frame for the first time.
-		///
-		/// @@ AFAIK, the sprite_id is totally pointless -- correct?
-		void	add_init_action(int sprite_id, execute_tag* e)
-		{
-		    assert(e);
-		    m_init_action_list[m_loading_frame].push_back(e);
-		}
+	/// Returns 0-based frame #
+	bool get_labeled_frame(const char* label, int* frame_number)
+	{
+		return m_named_frames.get(label, frame_number);
+	}
 
-		/// Labels the frame currently being loaded with the
-		/// given name.  A copy of the name string is made and
-		/// kept in this object.
-		void	add_frame_name(const char* name)
-		{
-		    assert(m_loading_frame >= 0 && m_loading_frame < m_frame_count);
+	void	add_font(int font_id, font* f);
+	font*	get_font(int font_id);
+	bitmap_character_def*	get_bitmap_character(int character_id);
+	void	add_bitmap_character(int character_id, bitmap_character_def* ch);
+	sound_sample*	get_sound_sample(int character_id);
+	virtual void	add_sound_sample(int character_id, sound_sample* sam);
 
-		    tu_string	n = name;
-		    assert(m_named_frames.get(n, NULL) == false);	// frame should not already have \
                a name (?)
-		    m_named_frames.add(n, m_loading_frame);	// stores 0-based frame #
-		}
+	/// Add an execute_tag to this movie_definition's playlist
+	void	add_execute_tag(execute_tag* e)
+	{
+	    assert(e);
+	    m_playlist[m_loading_frame].push_back(e);
+	}
 
-		/// Set an input object for later loading DefineBits
-		/// images (JPEG images without the table info).
-		void	set_jpeg_loader(jpeg::input* j_in)
-		{
-		    assert(m_jpeg_in == NULL);
-		    m_jpeg_in = j_in;
-		}
+	/// Need to execute the given tag before entering the
+	/// currently-loading frame for the first time.
+	///
+	/// @@ AFAIK, the sprite_id is totally pointless -- correct?
+	void	add_init_action(int sprite_id, execute_tag* e)
+	{
+	    assert(e);
+	    m_init_action_list[m_loading_frame].push_back(e);
+	}
+
+	/// Labels the frame currently being loaded with the
+	/// given name.  A copy of the name string is made and
+	/// kept in this object.
+	void	add_frame_name(const char* name)
+	{
+	    assert(m_loading_frame >= 0 && m_loading_frame < m_frame_count);
 
-		/// Get the jpeg input loader, to load a DefineBits
-		/// image (one without table info).
-		jpeg::input*	get_jpeg_loader()
-		{
-		    return m_jpeg_in;
-		}
+	    tu_string	n = name;
+	    assert(m_named_frames.get(n, NULL) == false);	// frame should not already have \
a name (?) +	    m_named_frames.add(n, m_loading_frame);	// stores 0-based frame #
+	}
+
+	/// Set an input object for later loading DefineBits
+	/// images (JPEG images without the table info).
+	void	set_jpeg_loader(jpeg::input* j_in)
+	{
+	    assert(m_jpeg_in == NULL);
+	    m_jpeg_in = j_in;
+	}
+
+	/// Get the jpeg input loader, to load a DefineBits
+	/// image (one without table info).
+	jpeg::input*	get_jpeg_loader()
+	{
+	    return m_jpeg_in;
+	}
 
-		virtual const std::vector<execute_tag*>& get_playlist(int frame_number) { return \
m_playlist[frame_number]; } +	virtual const std::vector<execute_tag*>& \
get_playlist(int frame_number) { return m_playlist[frame_number]; }  
-		virtual const std::vector<execute_tag*>*get_init_actions(int frame_number) { \
return &m_init_action_list[frame_number]; } +	virtual const \
std::vector<execute_tag*>*get_init_actions(int frame_number) { return \
&m_init_action_list[frame_number]; }  
-		/// Read Movie definition from an SWF file.
-		//
-		/// This function uses the gnash::s_tag_loaders
-		/// global variable to interpret specific tag types.
-		///
-		void read(tu_file *in);
+	/// Read Movie definition from an SWF file.
+	//
+	/// This function uses the gnash::s_tag_loaders
+	/// global variable to interpret specific tag types.
+	///
+	void read(tu_file *in);
 
-		/// Fill up *fonts with fonts that we own.
-		void get_owned_fonts(std::vector<font*>* fonts);
+	/// Fill up *fonts with fonts that we own.
+	void get_owned_fonts(std::vector<font*>* fonts);
 
-		/// Generate bitmaps for our fonts, if necessary.
-		void generate_font_bitmaps();
+	/// Generate bitmaps for our fonts, if necessary.
+	void generate_font_bitmaps();
 
-		/// Dump our cached data into the given stream.
-		void output_cached_data(tu_file* out,
-			const cache_options& options);
+	/// Dump our cached data into the given stream.
+	void output_cached_data(tu_file* out,
+		const cache_options& options);
 
-		/// Read in cached data and use it to prime our
-		/// loaded characters.
-		void	input_cached_data(tu_file* in);
+	/// Read in cached data and use it to prime our
+	/// loaded characters.
+	void	input_cached_data(tu_file* in);
 
-	    	/// Create a playable movie_root instance from a def.
-		//
-		/// The _root reference of the newly created instance
-		/// will be set to a newly created sprite_instace (Help!)
-		///
-		movie_interface* create_instance();
-	};
+	/// Create a playable movie_root instance from a def.
+	//
+	/// The _root reference of the newly created instance
+	/// will be set to a newly created sprite_instace (Help!)
+	///
+	movie_interface* create_instance();
+};
 
 
 	/// Global, shared root state for a movie and all its characters.
@@ -513,6 +637,11 @@
 		}
 	};
 
+
+
+/// Initialize the global MovieClip constructor
+void movieclip_init(as_object* global);
+
 } // namespace gnash
 
 #endif // GNASH_MOVIE_H
Index: gnash/server/MovieClipLoader.cpp
diff -u gnash/server/MovieClipLoader.cpp:1.9 gnash/server/MovieClipLoader.cpp:1.10
--- gnash/server/MovieClipLoader.cpp:1.9	Sat Feb 25 03:54:03 2006
+++ gnash/server/MovieClipLoader.cpp	Sun Feb 26 21:44:53 2006
@@ -42,6 +42,7 @@
 #endif
 #endif
 #include "MovieClipLoader.h"
+#include "Movie.h" // for movie_definition::create_instance, to be renamed
 #include "log.h"
 #include "tu_file.h"
 #include "image.h"
@@ -343,10 +344,9 @@
 
 	if (suffix == ".swf")
 	{
-		movie_definition_sub* md = \
-			create_library_movie_sub(filespec.c_str());
+		movie_definition* md = create_library_movie(filespec.c_str());
 		if (md == NULL) {
-			log_error("can't create movie_definition_sub for %s\n",
+			log_error("can't create movie_definition for %s\n",
 				filespec.c_str());
 			return;
 		}
@@ -441,7 +441,7 @@
 
 		movie *mov = target->to_movie();
 		//movie_definition *def = mov->get_movie_definition();
-		//movie_definition_sub *m = (movie_definition_sub *)mov;
+		//movie_definition *m = (movie_definition *)mov;
 		//target->add_bitmap_info(bi);
 
 		character* tar = (character*)mov;
@@ -459,11 +459,11 @@
 			filespec.length() - 3);
 		swfm += "swf";
 
-		movie_definition_sub  *ms = create_movie_sub(swfm.c_str());
+		movie_definition *ms = create_movie(swfm.c_str());
 		// The file may not exist.
 		if (ms) { 
 			movie_interface* extern_movie = \
-				create_library_movie_inst_sub(ms);
+				create_library_movie_inst(ms);
 			character * newchar = \
 				ms->create_character_instance(tar->get_parent(),
 						id);
@@ -473,7 +473,7 @@
 		//movie* new_movie = static_cast<movie*>(extern_movie)->get_root_movie();
      
 // #else
-//     movie_definition_sub  *ms;
+//     movie_definition*ms;
 //     ms->add_bitmap_info(bi);
 // #endif
 		//movie* m = mov->get_root_movie();
Index: gnash/server/Sprite.cpp
diff -u gnash/server/Sprite.cpp:1.14 gnash/server/Sprite.cpp:1.15
--- gnash/server/Sprite.cpp:1.14	Sat Feb 25 03:54:03 2006
+++ gnash/server/Sprite.cpp	Sun Feb 26 21:44:53 2006
@@ -230,14 +230,7 @@
 		//
 
 		// Get target's movie definition
-		movie_definition *m1 = sprite->get_movie_definition();
-
-
-		// text_character_def ctor insists in having
-		// a movie_definition_sub...
-		movie_definition_sub *mds = dynamic_cast<movie_definition_sub*>(m1);
-		assert(mds);
-
+		movie_definition *mds = sprite->get_movie_definition();
 
 		log_msg("Target's movie definition at %p\n", mds);
 
Index: gnash/server/Sprite.h
diff -u gnash/server/Sprite.h:1.8 gnash/server/Sprite.h:1.9
--- gnash/server/Sprite.h:1.8	Sat Feb 25 03:54:03 2006
+++ gnash/server/Sprite.h	Sun Feb 26 21:44:53 2006
@@ -59,15 +59,15 @@
 	//
 	// sprite_definition
 	//
-	struct sprite_definition : public movie_definition_sub
+	struct sprite_definition : public movie_definition
 	{
-		movie_definition_sub* m_movie_def;	// parent movie.
+		movie_definition* m_movie_def;	// parent movie.
 		std::vector<std::vector<execute_tag*> > m_playlist;	// movie control events for \
each frame.  stringi_hash<int> m_named_frames;	// stores 0-based frame #'s
 		int m_frame_count;
 		int m_loading_frame;
 
-		sprite_definition(movie_definition_sub* m) :
+		sprite_definition(movie_definition* m) :
 			m_movie_def(m),
 			m_frame_count(0),
 			m_loading_frame(0)
@@ -259,7 +259,7 @@
 	/// Stateful Sprite object. Also known as a MovieClip.
 	struct sprite_instance : public character
 	{
-		smart_ptr<movie_definition_sub>	m_def;
+		smart_ptr<movie_definition>	m_def;
 		movie_root*	m_root;
 
 		display_list	m_display_list;
@@ -295,7 +295,7 @@
 		};
 		mouse_state m_mouse_state;
 
-		sprite_instance(movie_definition_sub* def,
+		sprite_instance(movie_definition* def,
 			movie_root* r, movie* parent, int id)
 			:
 			character(parent, id),
Index: gnash/server/action.cpp
diff -u gnash/server/action.cpp:1.51 gnash/server/action.cpp:1.52
--- gnash/server/action.cpp:1.51	Sat Feb 25 03:54:03 2006
+++ gnash/server/action.cpp	Sun Feb 26 21:44:53 2006
@@ -18,6 +18,7 @@
 #include "tu_random.h"
 
 #include "gstring.h"
+#include "Movie.h" // for movie_definition::create_instance
 #include "MovieClipLoader.h"
 #include "Function.h"
 #include "timers.h"
@@ -134,10 +135,10 @@
 		tu_string infile = get_workdir();
 		infile += url;
 
-		movie_definition_sub*	md = create_library_movie_sub(infile.c_str());
+		movie_definition* md = create_library_movie(infile.c_str());
 		if (md == NULL)
 		{
-			log_error("can't create movie_definition_sub for %s\n", infile.c_str());
+			log_error("can't create movie_definition for %s\n", infile.c_str());
 			return;
 		}
 
@@ -145,7 +146,7 @@
 
 		if (target == root_movie)
 		{
-			extern_movie = create_library_movie_inst_sub(md);			
+			extern_movie = create_library_movie_inst(md);			
 			if (extern_movie == NULL)
 			{
 				log_error("can't create extern root movie_interface for %s\n", infile.c_str());
@@ -510,8 +511,7 @@
 		so->sound = fn.arg(0).to_tu_string();
 
 		// check the import.
-		movie_definition_sub*	def = (movie_definition_sub*)
-			fn.env->get_target()->get_root_movie()->get_movie_definition();
+		movie_definition* def = \
fn.env->get_target()->get_root_movie()->get_movie_definition();  assert(def);
 		smart_ptr<resource> res = def->get_exported_resource(so->sound);
 		if (res == NULL)
@@ -1457,6 +1457,7 @@
 			s_global->set_member("isFinite", as_global_isfinite);
 
 			function_init(s_global.get_ptr());
+			movieclip_init(s_global.get_ptr());
 			math_init();
 			key_init();
 		}
@@ -1563,7 +1564,7 @@
 		}
 	};
 
-	void	do_action_loader(stream* in, int tag_type, movie_definition_sub* m)
+	void	do_action_loader(stream* in, int tag_type, movie_definition* m)
 	{
 		IF_VERBOSE_PARSE(log_msg("tag %d: do_action_loader\n", tag_type));
 
@@ -1585,7 +1586,7 @@
 	//
 
 
-	void	do_init_action_loader(stream* in, int tag_type, movie_definition_sub* m)
+	void	do_init_action_loader(stream* in, int tag_type, movie_definition* m)
 	{
 		assert(tag_type == 59);
 
@@ -1885,7 +1886,7 @@
 
 		// Get an object
 		as_value& obj_value = env->top(1);
-		as_object*	obj = obj_value.to_object();
+		as_object* obj = obj_value.to_object();
 		//log_msg(" method object: %p\n", obj);
 
 		// Get number of arguments
@@ -1961,7 +1962,10 @@
 			function = env->top(0);
 		}
 		int	nargs = (int) env->top(1).to_number();
-		as_value	result = call_method(function, env, NULL, nargs, env->get_top_index() - \
2); +
+		as_value result = call_method(function, env, env->get_target(),
+				nargs, env->get_top_index() - 2);
+
 		env->drop(nargs + 1);
 		env->top(0) = result;
 	}
Index: gnash/server/action.h
diff -u gnash/server/action.h:1.22 gnash/server/action.h:1.23
--- gnash/server/action.h:1.22	Sat Feb 25 03:54:03 2006
+++ gnash/server/action.h	Sun Feb 26 21:44:53 2006
@@ -291,6 +291,7 @@
 		/// function2 uses this
 		std::vector<as_value>	m_local_register;
 
+		/// Movie target. 
 		movie*	m_target;
 
 		/// Variables available in this environment
Index: gnash/server/button.cpp
diff -u gnash/server/button.cpp:1.5 gnash/server/button.cpp:1.6
--- gnash/server/button.cpp:1.5	Sat Feb 25 03:54:03 2006
+++ gnash/server/button.cpp	Sun Feb 26 21:44:53 2006
@@ -12,6 +12,7 @@
 #include "render.h"
 #include "sound.h"
 #include "stream.h"
+#include "Movie.h"
 
 
 /*
@@ -301,8 +302,7 @@
 			int r, r_num =  m_def->m_button_records.size();
 			m_record_character.resize(r_num);
 
-			movie_definition_sub*	movie_def = static_cast<movie_definition_sub*>(
-				parent->get_root_movie()->get_movie_definition());
+			movie_definition* movie_def = parent->get_root_movie()->get_movie_definition();
 
 			for (r = 0; r < r_num; r++)
 			{
@@ -780,7 +780,7 @@
 	// button_record
 	//
 
-	bool	button_record::read(stream* in, int tag_type, movie_definition_sub* m)
+	bool	button_record::read(stream* in, int tag_type, movie_definition* m)
 	// Return true if we read a record; false if this is a null record.
 	{
 		int	flags = in->read_u8();
@@ -902,7 +902,7 @@
 
 
 
-	void	button_character_definition::read(stream* in, int tag_type, \
movie_definition_sub* m) +	void	button_character_definition::read(stream* in, int \
tag_type, movie_definition* m)  // Initialize from the given stream.
 	{
 		assert(tag_type == 7 || tag_type == 17 || tag_type == 34);
Index: gnash/server/button.h
diff -u gnash/server/button.h:1.2 gnash/server/button.h:1.3
--- gnash/server/button.h:1.2	Sat Feb 25 03:54:03 2006
+++ gnash/server/button.h	Sun Feb 26 21:44:53 2006
@@ -62,7 +62,7 @@
 		matrix	m_button_matrix;
 		cxform	m_button_cxform;
 
-		bool	read(stream* in, int tag_type, movie_definition_sub* m);
+		bool	read(stream* in, int tag_type, movie_definition* m);
 	};
 	
 
@@ -122,7 +122,7 @@
 
 		struct button_sound_def
 		{
-			void	read(stream* in, movie_definition_sub* m);
+			void	read(stream* in, movie_definition* m);
 			button_sound_info m_button_sounds[4];
 		};
 
@@ -136,7 +136,7 @@
 		virtual ~button_character_definition();
 
 		character*	create_character_instance(movie* parent, int id);
-		void	read(stream* in, int tag_type, movie_definition_sub* m);
+		void	read(stream* in, int tag_type, movie_definition* m);
 	};
 
 };	// end namespace gnash
Index: gnash/server/font.cpp
diff -u gnash/server/font.cpp:1.5 gnash/server/font.cpp:1.6
--- gnash/server/font.cpp:1.5	Sat Feb 25 03:54:03 2006
+++ gnash/server/font.cpp	Sun Feb 26 21:44:53 2006
@@ -12,6 +12,7 @@
 #include "log.h"
 #include "shape.h"
 #include "tu_file.h"
+#include "Movie.h"
 
 namespace gnash {
 	font::font()
@@ -99,7 +100,7 @@
 	}
 
 
-	void	font::read(stream* in, int tag_type, movie_definition_sub* m)
+	void	font::read(stream* in, int tag_type, movie_definition* m)
 	{
 		assert(tag_type == 10 || tag_type == 48);
 
Index: gnash/server/font.h
diff -u gnash/server/font.h:1.2 gnash/server/font.h:1.3
--- gnash/server/font.h:1.2	Sat Feb 25 03:54:03 2006
+++ gnash/server/font.h	Sun Feb 26 21:44:53 2006
@@ -59,7 +59,7 @@
 
 		int	get_glyph_count() const { return m_glyphs.size(); }
 		shape_character_def*	get_glyph(int glyph_index) const;
-		void	read(stream* in, int tag_type, movie_definition_sub* m);
+		void	read(stream* in, int tag_type, movie_definition* m);
 		void	read_font_info(stream* in);
 
 		void	output_cached_data(tu_file* out, const cache_options& options);
@@ -68,7 +68,7 @@
 		void	wipe_texture_glyphs();
 
 		const char*	get_name() const { return m_name; }
-		movie_definition_sub*	get_owning_movie() const { return m_owning_movie; }
+		movie_definition* get_owning_movie() const { return m_owning_movie; }
 
 		const texture_glyph&	get_texture_glyph(int glyph_index) const;
 		void	add_texture_glyph(int glyph_index, const texture_glyph& glyph);
@@ -90,7 +90,7 @@
 		int	m_texture_glyph_nominal_size;
 
 		char*	m_name;
-		movie_definition_sub*	m_owning_movie;
+		movie_definition*	m_owning_movie;
 		bool	m_has_layout;
 		bool	m_unicode_chars;
 		bool	m_shift_jis_chars;
Index: gnash/server/fontlib.cpp
diff -u gnash/server/fontlib.cpp:1.4 gnash/server/fontlib.cpp:1.5
--- gnash/server/fontlib.cpp:1.4	Sat Feb 25 03:54:03 2006
+++ gnash/server/fontlib.cpp	Sun Feb 26 21:44:53 2006
@@ -17,6 +17,7 @@
 #include "styles.h"
 #include "tesselate.h"
 #include "render.h"
+#include "Movie.h"
 
 
 namespace gnash {
@@ -214,7 +215,7 @@
 	}
 
 
-	void	finish_current_texture(movie_definition_sub* owner)
+	void	finish_current_texture(movie_definition* owner)
 	{
 		if (s_pending_glyphs.size() == 0)
 		{
@@ -741,7 +742,7 @@
 	}
 
 
-	void	pack_and_assign_glyphs(std::vector<rendered_glyph_info>* glyph_info, \
movie_definition_sub* owner) \
+	void	pack_and_assign_glyphs(std::vector<rendered_glyph_info>* glyph_info, \
movie_definition* owner)  // Pack the given glyphs into textures, and push the
 	// texture_glyph info into the source fonts.
 	//
@@ -873,7 +874,7 @@
 	}
 
 
-	static void	generate_font_bitmaps(std::vector<rendered_glyph_info>* glyph_info, \
font* f, movie_definition_sub* owner) +	static \
void	generate_font_bitmaps(std::vector<rendered_glyph_info>* glyph_info, font* f, \
movie_definition* owner)  // Render images for each of the font's glyphs, and put the
 	// info about them in the given array.
 	{
@@ -937,7 +938,7 @@
 	//
 
 
-	void	generate_font_bitmaps(const std::vector<font*>& fonts, movie_definition_sub* \
owner) +	void	generate_font_bitmaps(const std::vector<font*>& fonts, \
movie_definition* owner)  // Build cached textures from glyph outlines.
 	{
 		assert(s_render_buffer == NULL);
@@ -983,7 +984,7 @@
 	void	output_cached_data(
 		tu_file* out,
 		const std::vector<font*>& fonts,
-		movie_definition_sub* owner,
+		movie_definition* owner,
 		const cache_options& options)
 	// Save cached font data, including glyph textures, to a
 	// stream.  This is used by the movie caching code.
@@ -1086,7 +1087,7 @@
 	}
 	
 
-	void	input_cached_data(tu_file* in, const std::vector<font*>& fonts, \
movie_definition_sub* owner) +	void	input_cached_data(tu_file* in, const \
std::vector<font*>& fonts, movie_definition* owner)  // Load a stream containing \
previously-saved font glyph textures.  {
 		// load number of bitmaps.
Index: gnash/server/fontlib.h
diff -u gnash/server/fontlib.h:1.2 gnash/server/fontlib.h:1.3
--- gnash/server/fontlib.h:1.2	Sat Feb 25 03:54:03 2006
+++ gnash/server/fontlib.h	Sun Feb 26 21:44:53 2006
@@ -32,19 +32,19 @@
 		float	get_texture_glyph_max_height(const font* f);
 
 		// Builds cached glyph textures from shape info.
-		void	generate_font_bitmaps(const std::vector<font*>& fonts, movie_definition_sub* \
owner); +		void	generate_font_bitmaps(const std::vector<font*>& fonts, \
movie_definition* owner);  
 		// Save cached font data, including glyph textures, to a
 		// stream.
 		void	output_cached_data(
 			tu_file* out,
 			const std::vector<font*>& fonts,
-			movie_definition_sub* owner,
+			movie_definition* owner,
 			const cache_options& options);
 		
 		// Load a stream containing previously-saved cachded font
 		// data, including glyph texture info.
-		void	input_cached_data(tu_file* in, const std::vector<font*>& fonts, \
movie_definition_sub* owner); +		void	input_cached_data(tu_file* in, const \
std::vector<font*>& fonts, movie_definition* owner);  
 	}	// end namespace fontlib
 }	// end namespace gnash
Index: gnash/server/gnash.h
diff -u gnash/server/gnash.h:1.12 gnash/server/gnash.h:1.13
--- gnash/server/gnash.h:1.12	Wed Feb 15 23:35:53 2006
+++ gnash/server/gnash.h	Sun Feb 26 21:44:53 2006
@@ -63,6 +63,7 @@
 struct font;
 struct movie;
 struct movie_interface;
+struct movie_definition;
 struct render_handler;
 struct resource;
 struct rgba;
@@ -167,8 +168,8 @@
 /// Immutable data representing the template of a movie element.
 //
 /// This is not really a public interface.  It's here so it
-/// can be mixed into movie_definition, movie_definition_sub,
-/// and sprite_definition, without using multiple inheritance.
+/// can be mixed into movie_definition and sprite_definition,
+/// without using multiple inheritance.
 ///
 struct character_def : public resource
 {
@@ -204,101 +205,6 @@
 };
 
 
-/// Client program's interface to the definition of a movie
-//
-/// (i.e. the shared constant source info).
-///
-struct movie_definition : public character_def
-{
-	virtual int	get_version() const = 0;
-	virtual float	get_width_pixels() const = 0;
-	virtual float	get_height_pixels() const = 0;
-	virtual int	get_frame_count() const = 0;
-	virtual float	get_frame_rate() const = 0;
-	
-	/// Create a playable movie instance from a def.
-	//
-	/// This calls add_ref() on the movie_interface internally.
-	/// Call drop_ref() on the movie_interface when you're done with it.
-	/// Or use smart_ptr<T> from base/smart_ptr.h if you want.
-	///
-	virtual movie_interface*	create_instance() = 0;
-	
-	virtual void	output_cached_data(tu_file* out, const cache_options& options) = 0;
-	virtual void	input_cached_data(tu_file* in) = 0;
-	
-	/// \brief
-	/// Causes this movie def to generate texture-mapped
-	/// versions of all the fonts it owns. 
-	//
-	/// This improves
-	/// speed and quality of text rendering.  The
-	/// texture-map data is serialized in the
-	/// output/input_cached_data() calls, so you can
-	/// preprocess this if you load cached data.
-	///
-	virtual void	generate_font_bitmaps() = 0;
-	
-	//
-	// (optional) API to support gnash::create_movie_no_recurse().
-	//
-	
-	/// \brief
-	/// Call visit_imported_movies() to retrieve a list of
-	/// names of movies imported into this movie.
-	//
-	/// visitor->visit() will be called back with the name
-	/// of each imported movie.
-	struct import_visitor
-	{
-	    virtual ~import_visitor() {}
-	    virtual void	visit(const char* imported_movie_filename) = 0;
-	};
-	virtual void	visit_imported_movies(import_visitor* visitor) = 0;
-	
-	/// Call this to resolve an import of the given movie.
-	/// Replaces the dummy placeholder with the real
-	/// movie_definition* given.
-	virtual void	resolve_import(const char* name, movie_definition* def) = 0;
-	
-	//
-	// (optional) API to support host-driven creation of textures.
-	//
-	// Create the movie using gnash::create_movie_no_recurse(..., DO_NOT_LOAD_BITMAPS),
-	// and then initialize each bitmap info via get_bitmap_info_count(), \
                get_bitmap_info(),
-	// and bitmap_info::init_*_image() or your own subclassed API.
-	//
-	// E.g.:
-	//
-	// // During preprocessing:
-	// // This will create bitmap_info's using the rgba, rgb, alpha contructors.
-	// my_def = gnash::create_movie_no_recurse("myfile.swf", DO_LOAD_BITMAPS);
-	// int ct = my_def->get_bitmap_info_count();
-	// for (int i = 0; i < ct; i++)
-	// {
-	//	my_bitmap_info_subclass*	bi = NULL;
-	//	my_def->get_bitmap_info(i, (bitmap_info**) &bi);
-	//	my_precomputed_textures.push_back(bi->m_my_internal_texture_reference);
-	// }
-	// // Save out my internal data.
-	// my_precomputed_textures->write_into_some_cache_stream(...);
-	//
-	// // Later, during run-time loading:
-	// my_precomputed_textures->read_from_some_cache_stream(...);
-	// // This will create blank bitmap_info's.
-	// my_def = gnash::create_movie_no_recurse("myfile.swf", DO_NOT_LOAD_BITMAPS);
-	// 
-	// // Push cached texture info into the movie's bitmap_info structs.
-	// int	ct = my_def->get_bitmap_info_count();
-	// for (int i = 0; i < ct; i++)
-	// {
-	//	my_bitmap_info_subclass*	bi = (my_bitmap_info_subclass*) \
                my_def->get_bitmap_info(i);
-	//	bi->set_internal_texture_reference(my_precomputed_textures[i]);
-	// }
-	virtual int	get_bitmap_info_count() const = 0;
-	virtual bitmap_info*	get_bitmap_info(int i) const = 0;
-};
-
 
 /// An independent stateful live movie.
 //
Index: gnash/server/impl.cpp
diff -u gnash/server/impl.cpp:1.20 gnash/server/impl.cpp:1.21
--- gnash/server/impl.cpp:1.20	Sat Feb 25 03:54:03 2006
+++ gnash/server/impl.cpp	Sun Feb 26 21:44:53 2006
@@ -407,17 +407,7 @@
     delete original_in;
 }
 
-
-
-movie_definition*	create_movie(const char* filename)
-    // Create the movie definition from the specified .swf file.
-{
-    //printf("%s: filename is %s\n",  __PRETTY_FUNCTION__, filename);
-    return create_movie_sub(filename);
-}
-
-
-movie_definition_sub*	create_movie_sub(const char* filename)
+movie_definition* create_movie(const char* filename)
 {
     //printf("%s: filename is %s\n",  __PRETTY_FUNCTION__, filename);
     if (s_opener_function == NULL)
@@ -522,8 +512,8 @@
 //
 
 
-static stringi_hash< smart_ptr<movie_definition_sub> >	s_movie_library;
-static hash< movie_definition_sub*, smart_ptr<movie_interface> \
>	s_movie_library_inst; +static stringi_hash< smart_ptr<movie_definition> \
> >	s_movie_library;
+static hash< movie_definition*, smart_ptr<movie_interface> >	s_movie_library_inst;
 static std::vector<movie_interface*> s_extern_sprites;
 static movie_interface* s_current_root;
 
@@ -584,16 +574,10 @@
     s_movie_library_inst.clear();
 }
 
-movie_definition*	create_library_movie(const char* filename)
-    // Try to load a movie from the given url, if we haven't
-    // loaded it already.  Add it to our library on success, and
-    // return a pointer to it.
-{
-    return create_library_movie_sub(filename);
-}
-
-
-movie_definition_sub*	create_library_movie_sub(const char* filename)
+// Try to load a movie from the given url, if we haven't
+// loaded it already.  Add it to our library on success, and
+// return a pointer to it.
+movie_definition* create_library_movie(const char* filename)
 {
     tu_string	fn(filename);
 
@@ -601,7 +585,7 @@
 
     // Is the movie already in the library?
     {
-	smart_ptr<movie_definition_sub>	m;
+	smart_ptr<movie_definition>	m;
 	s_movie_library.get(fn, &m);
 	if (m != NULL)
 	    {
@@ -613,7 +597,7 @@
     }
 
     // Try to open a file under the filename.
-    movie_definition_sub*	mov = create_movie_sub(filename);
+    movie_definition* mov = create_movie(filename);
 
     if (mov == NULL)
 	{
@@ -628,14 +612,8 @@
     mov->add_ref();
     return mov;
 }
-	
-movie_interface*	create_library_movie_inst(movie_definition* md)
-{
-    return create_library_movie_inst_sub((movie_definition_sub*)md);
-}
-
 
-movie_interface*	create_library_movie_inst_sub(movie_definition_sub* md)
+movie_interface* create_library_movie_inst(movie_definition* md)
 {
     // Is the movie instance already in the library?
     {
@@ -772,12 +750,12 @@
 //
 
 
-void	null_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	null_loader(stream* in, int tag_type, movie_definition* m)
     // Silently ignore the contents of this tag.
 {
 }
 
-void	frame_label_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	frame_label_loader(stream* in, int tag_type, movie_definition* m)
     // Label the current frame of m with the name from the stream.
 {
     char*	n = in->read_string();
@@ -812,7 +790,7 @@
 };
 
 
-void	set_background_color_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	set_background_color_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 9);
     assert(m);
@@ -859,7 +837,7 @@
 };
 #endif
 
-void	jpeg_tables_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	jpeg_tables_loader(stream* in, int tag_type, movie_definition* m)
     // Load JPEG compression tables that can be used to load
     // images further along in the stream.
 {
@@ -874,7 +852,7 @@
 }
 
 
-void	define_bits_jpeg_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	define_bits_jpeg_loader(stream* in, int tag_type, movie_definition* m)
     // A JPEG image without included tables; those should be in an
     // existing jpeg::input object stored in the movie.
 {
@@ -915,7 +893,7 @@
 }
 
 
-void	define_bits_jpeg2_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	define_bits_jpeg2_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 21);
 		
@@ -1007,7 +985,7 @@
 #endif // TU_CONFIG_LINK_TO_ZLIB
 
 
-void	define_bits_jpeg3_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	define_bits_jpeg3_loader(stream* in, int tag_type, movie_definition* m)
     // loads a define_bits_jpeg3 tag. This is a jpeg file with an alpha
     // channel using zlib compression.
 {
@@ -1068,7 +1046,7 @@
 }
 
 
-void	define_bits_lossless_2_loader(stream* in, int tag_type, movie_definition_sub* \
m) +void	define_bits_lossless_2_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 20 || tag_type == 36);
 
@@ -1316,7 +1294,7 @@
 }
 
 
-void	define_shape_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	define_shape_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 2
 	   || tag_type == 22
@@ -1333,7 +1311,7 @@
     m->add_character(character_id, ch);
 }
 
-void define_shape_morph_loader(stream* in, int tag_type, movie_definition_sub* m)
+void define_shape_morph_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 46);
     Uint16 character_id = in->read_u16();
@@ -1348,7 +1326,7 @@
 //
 
 
-void	define_font_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	define_font_loader(stream* in, int tag_type, movie_definition* m)
     // Load a DefineFont or DefineFont2 tag.
 {
     assert(tag_type == 10 || tag_type == 48);
@@ -1367,7 +1345,7 @@
 }
 
 
-void	define_font_info_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	define_font_info_loader(stream* in, int tag_type, movie_definition* m)
     // Load a DefineFontInfo tag.  This adds information to an
     // existing font.
 {
@@ -1765,7 +1743,7 @@
 
 
 	
-void	place_object_2_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	place_object_2_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 4 || tag_type == 26);
 
@@ -1783,7 +1761,7 @@
 
 
 
-void	sprite_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	sprite_loader(stream* in, int tag_type, movie_definition* m)
     // Create and initialize a sprite, and add it to the movie.
 {
     assert(tag_type == SWF::DEFINESPRITE); // 39 - DefineSprite
@@ -1806,7 +1784,7 @@
 
 // end_tag doesn't actually need to exist.
 
-void	end_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	end_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 0);
     assert(in->get_position() == in->get_tag_end_position());
@@ -1864,7 +1842,7 @@
 };
 
 
-void	remove_object_2_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	remove_object_2_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 5 || tag_type == 28);
 
@@ -1877,7 +1855,7 @@
 }
 
 
-void	button_sound_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	button_sound_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 17);
 
@@ -1889,7 +1867,7 @@
 }
 
 
-void	button_character_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	button_character_loader(stream* in, int tag_type, movie_definition* m)
 {
     assert(tag_type == 7 || tag_type == 34);
 
@@ -1909,7 +1887,7 @@
 //
 
 
-void	export_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	export_loader(stream* in, int tag_type, movie_definition* m)
     // Load an export tag (for exposing internal resources of m)
 {
     assert(tag_type == 56);
@@ -1955,7 +1933,7 @@
 //
 
 
-void	import_loader(stream* in, int tag_type, movie_definition_sub* m)
+void	import_loader(stream* in, int tag_type, movie_definition* m)
     // Load an import tag (for pulling in external resources)
 {
     assert(tag_type == 57);
@@ -1966,11 +1944,11 @@
     IF_VERBOSE_PARSE(log_msg("  import: source_url = %s, count = %d\n", source_url, \
count));  
     // Try to load the source movie into the movie library.
-    movie_definition_sub*	source_movie = NULL;
+    movie_definition*	source_movie = NULL;
 
     if (s_no_recurse_while_loading == false)
 	{
-	    source_movie = create_library_movie_sub(source_url);
+	    source_movie = create_library_movie(source_url);
 	    if (source_movie == NULL)
 		{
 		    // Give up on imports.
@@ -1994,7 +1972,7 @@
 		{
 		    // @@ TODO get rid of this, always use
 		    // s_no_recurse_while_loading, change
-		    // create_movie_sub().
+		    // create_movie().
 
 		    smart_ptr<resource> res = source_movie->get_exported_resource(symbol_name);
 		    if (res == NULL)
Index: gnash/server/impl.h
diff -u gnash/server/impl.h:1.12 gnash/server/impl.h:1.13
--- gnash/server/impl.h:1.12	Sat Feb 25 03:54:03 2006
+++ gnash/server/impl.h	Sun Feb 26 21:44:53 2006
@@ -52,44 +52,6 @@
 
 	void save_extern_movie(movie_interface* m);
 
-	/// Extra internal interfaces added to movie_definition
-	struct movie_definition_sub : public movie_definition
-	// @@@ why not adding to movie_definition instead ?
-	{
-		virtual const std::vector<execute_tag*>&	get_playlist(int frame_number) = 0;
-		virtual const std::vector<execute_tag*>*	get_init_actions(int frame_number) = 0;
-		virtual smart_ptr<resource>	get_exported_resource(const tu_string& symbol) = 0;
-		virtual character_def*	get_character_def(int id) = 0;
-
-		virtual bool	get_labeled_frame(const char* label, int* frame_number) = 0;
-
-		// For use during creation.
-		virtual int	get_loading_frame() const = 0;
-		virtual void	add_character(int id, character_def* ch) = 0;
-		virtual void	add_font(int id, font* ch) = 0;
-		virtual font*	get_font(int id) = 0;
-		virtual void	add_execute_tag(execute_tag* c) = 0;
-		virtual void	add_init_action(int sprite_id, execute_tag* c) = 0;
-		virtual void	add_frame_name(const char* name) = 0;
-		virtual void	set_jpeg_loader(jpeg::input* j_in) = 0;
-		virtual jpeg::input*	get_jpeg_loader() = 0;
-		virtual bitmap_character_def*	get_bitmap_character(int character_id) = 0;
-		virtual void	add_bitmap_character(int character_id, bitmap_character_def* ch) = 0;
-		virtual sound_sample*	get_sound_sample(int character_id) = 0;
-		virtual void	add_sound_sample(int character_id, sound_sample* sam) = 0;
-		virtual void	export_resource(const tu_string& symbol, resource* res) = 0;
-		virtual void	add_import(const char* source_url, int id, const char* symbol_name) = \
                0;
-		virtual void	add_bitmap_info(bitmap_info* ch) = 0;
-
-		virtual create_bitmaps_flag	get_create_bitmaps() const = 0;
-		virtual create_font_shapes_flag	get_create_font_shapes() const = 0;
-	};
-
-
-	// For internal use.
-	movie_definition_sub*	create_movie_sub(const char* filename);
-	movie_definition_sub*	create_library_movie_sub(const char* filename);
-	movie_interface*	create_library_movie_inst_sub(movie_definition_sub* md);
 
 //v for extern movies
 
@@ -653,7 +615,7 @@
 	// to call this in order to handle special tag types.
 
 	/// Signature of an SWF tag loader
-	typedef void (*loader_function)(stream* input, int tag_type, movie_definition_sub* \
m); +	typedef void (*loader_function)(stream* input, int tag_type, movie_definition* \
m);  
 	/// Register a tag loader for the given tag
 	void	register_tag_loader(int tag_type, loader_function lf);
@@ -662,32 +624,32 @@
 	extern hash<int, loader_function> s_tag_loaders;
 	
 	// Tag loader functions.
-	void	null_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	set_background_color_loader(stream* in, int tag_type, movie_definition_sub* \
                m);
-	void	jpeg_tables_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_bits_jpeg_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_bits_jpeg2_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_bits_jpeg3_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_shape_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_shape_morph_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_font_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_font_info_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_text_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_edit_text_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	place_object_2_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_bits_lossless_2_loader(stream* in, int tag_type, movie_definition_sub* \
                m);
-	void	sprite_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	end_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	remove_object_2_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	do_action_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	button_character_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	frame_label_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	export_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	import_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	define_sound_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	start_sound_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	button_sound_loader(stream* in, int tag_type, movie_definition_sub* m);
-	void	do_init_action_loader(stream* in, int tag_type, movie_definition_sub* m);
+	void	null_loader(stream* in, int tag_type, movie_definition* m);
+	void	set_background_color_loader(stream* in, int tag_type, movie_definition* m);
+	void	jpeg_tables_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_bits_jpeg_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_bits_jpeg2_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_bits_jpeg3_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_shape_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_shape_morph_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_font_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_font_info_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_text_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_edit_text_loader(stream* in, int tag_type, movie_definition* m);
+	void	place_object_2_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_bits_lossless_2_loader(stream* in, int tag_type, movie_definition* m);
+	void	sprite_loader(stream* in, int tag_type, movie_definition* m);
+	void	end_loader(stream* in, int tag_type, movie_definition* m);
+	void	remove_object_2_loader(stream* in, int tag_type, movie_definition* m);
+	void	do_action_loader(stream* in, int tag_type, movie_definition* m);
+	void	button_character_loader(stream* in, int tag_type, movie_definition* m);
+	void	frame_label_loader(stream* in, int tag_type, movie_definition* m);
+	void	export_loader(stream* in, int tag_type, movie_definition* m);
+	void	import_loader(stream* in, int tag_type, movie_definition* m);
+	void	define_sound_loader(stream* in, int tag_type, movie_definition* m);
+	void	start_sound_loader(stream* in, int tag_type, movie_definition* m);
+	void	button_sound_loader(stream* in, int tag_type, movie_definition* m);
+	void	do_init_action_loader(stream* in, int tag_type, movie_definition* m);
 	// sound_stream_loader();	// head, head2, block
 
 
Index: gnash/server/morph.cpp
diff -u gnash/server/morph.cpp:1.2 gnash/server/morph.cpp:1.3
--- gnash/server/morph.cpp:1.2	Sat Feb 25 15:27:35 2006
+++ gnash/server/morph.cpp	Sun Feb 26 21:44:53 2006
@@ -72,7 +72,7 @@
 	}
 
 	void shape_morph_def::read(stream *in, int tag_type, bool with_style,
-				   movie_definition_sub *m)
+				   movie_definition*m)
 	{
 		assert(tag_type == 46);
 		int pos = in->get_underlying_stream()->get_position();
@@ -156,7 +156,7 @@
 	}
 
 	int shape_morph_def::read_shape_record(stream* in,
-					       movie_definition_sub* m,
+					       movie_definition* m,
 					       bool start)
 	{
 		morph_path current_path;
@@ -305,7 +305,7 @@
 	{
 	}
 
-	morph_fill_style::morph_fill_style(stream* in, movie_definition_sub *m)
+	morph_fill_style::morph_fill_style(stream* in, movie_definition*m)
 		:
 		m_bitmap_character(0)
 	{
@@ -316,7 +316,7 @@
 	{
 	}
 
-	void morph_fill_style::read(stream* in, movie_definition_sub* m)
+	void morph_fill_style::read(stream* in, movie_definition* m)
 	{
 		m_type = in->read_u8();
 		switch(m_type) {
Index: gnash/server/morph.h
diff -u gnash/server/morph.h:1.2 gnash/server/morph.h:1.3
--- gnash/server/morph.h:1.2	Sat Feb 25 15:27:35 2006
+++ gnash/server/morph.h	Sun Feb 26 21:44:53 2006
@@ -32,12 +32,12 @@
                 virtual ~shape_morph_def();
                 virtual void display(character *instance_info);
                 void read(stream* in, int tag_type, bool with_style,
-			  movie_definition_sub* m);
+			  movie_definition* m);
 		virtual void tesselate(float error_tolerance, tesselate::trapezoid_accepter \
*accepter, float ratio) const;  
         private:
 		void read_edge(stream* in, edge& e, float& x, float& y);
-		int read_shape_record(stream* in, movie_definition_sub* m,
+		int read_shape_record(stream* in, movie_definition* m,
 				      bool start);
 
 		rect	m_bound_orig, m_bound_target;
Index: gnash/server/morph2.cpp
diff -u gnash/server/morph2.cpp:1.3 gnash/server/morph2.cpp:1.4
--- gnash/server/morph2.cpp:1.3	Sat Feb 25 03:15:51 2006
+++ gnash/server/morph2.cpp	Sun Feb 26 21:44:53 2006
@@ -8,6 +8,7 @@
 
 #include "morph2.h"
 #include "stream.h"
+#include "Movie.h"
 
 
 namespace gnash {
@@ -112,7 +113,7 @@
 	}
 
   
-	void	morph2_character_def::read(stream* in, int tag_type, bool with_style, \
movie_definition_sub* md) +	void	morph2_character_def::read(stream* in, int tag_type, \
bool with_style, movie_definition* md)  {
 		UNUSED(tag_type);
 		UNUSED(with_style);
Index: gnash/server/morph2.h
diff -u gnash/server/morph2.h:1.1 gnash/server/morph2.h:1.2
--- gnash/server/morph2.h:1.1	Tue Dec 20 21:01:18 2005
+++ gnash/server/morph2.h	Sun Feb 26 21:44:53 2006
@@ -14,7 +14,7 @@
 	{
 		morph2_character_def();
 		virtual ~morph2_character_def();
-		void	read(stream* in, int tag_type, bool with_style, movie_definition_sub* m);
+		void	read(stream* in, int tag_type, bool with_style, movie_definition* m);
 		virtual void	display(character* inst);
 		void lerp_matrix(matrix& t, const matrix& m1, const matrix& m2, const float \
ratio);  
Index: gnash/server/shape.cpp
diff -u gnash/server/shape.cpp:1.8 gnash/server/shape.cpp:1.9
--- gnash/server/shape.cpp:1.8	Sat Feb 25 03:54:03 2006
+++ gnash/server/shape.cpp	Sun Feb 26 21:44:53 2006
@@ -13,6 +13,7 @@
 #include "render.h"
 #include "stream.h"
 #include "tesselate.h"
+#include "Movie.h"
 
 #include "tu_file.h"
 
@@ -789,7 +790,7 @@
 	//
 
 
-	static void	read_fill_styles(std::vector<fill_style>* styles, stream* in, int \
tag_type, movie_definition_sub* m) +	static \
void	read_fill_styles(std::vector<fill_style>* styles, stream* in, int tag_type, \
movie_definition* m)  // Read fill styles, and push them onto the given style array.
 	{
 		assert(styles);
@@ -862,7 +863,7 @@
 	}
 
 
-	void	shape_character_def::read(stream* in, int tag_type, bool with_style, \
movie_definition_sub* m) +	void	shape_character_def::read(stream* in, int tag_type, \
bool with_style, movie_definition* m)  {
 		if (with_style)
 		{
Index: gnash/server/shape.h
diff -u gnash/server/shape.h:1.4 gnash/server/shape.h:1.5
--- gnash/server/shape.h:1.4	Sat Feb 25 03:54:03 2006
+++ gnash/server/shape.h	Sun Feb 26 21:44:53 2006
@@ -150,7 +150,7 @@
 		float	get_height_local();
 		float	get_width_local();
 
-		void	read(stream* in, int tag_type, bool with_style, movie_definition_sub* m);
+		void	read(stream* in, int tag_type, bool with_style, movie_definition* m);
 		void	display(
 			const matrix& mat,
 			const cxform& cx,
Index: gnash/server/sound.cpp
diff -u gnash/server/sound.cpp:1.2 gnash/server/sound.cpp:1.3
--- gnash/server/sound.cpp:1.2	Fri Jan 27 00:54:38 2006
+++ gnash/server/sound.cpp	Sun Feb 26 21:44:53 2006
@@ -10,6 +10,7 @@
 #include "stream.h"
 #include "impl.h"
 #include "log.h"
+#include "Movie.h"
 
 namespace gnash {
 	// Callback interface to host, for handling sounds.  If it's NULL,
@@ -48,7 +49,7 @@
 		bool stereo);
 
 
-	void	define_sound_loader(stream* in, int tag_type, movie_definition_sub* m)
+	void	define_sound_loader(stream* in, int tag_type, movie_definition* m)
 	// Load a DefineSound tag.
 	{
 		assert(tag_type == 14);
@@ -138,7 +139,7 @@
 		}
 
 
-		void	read(stream* in, int tag_type, movie_definition_sub* m, const \
sound_sample_impl* sam) +		void	read(stream* in, int tag_type, movie_definition* m, \
const sound_sample_impl* sam)  // Initialize this StartSound tag from the stream & \
given sample.  // Insert ourself into the movie.
 		{
@@ -184,7 +185,7 @@
 	};
 
 
-	void	start_sound_loader(stream* in, int tag_type, movie_definition_sub* m)
+	void	start_sound_loader(stream* in, int tag_type, movie_definition* m)
 	// Load a StartSound tag.
 	{
 		assert(tag_type == 15);
@@ -215,7 +216,7 @@
 
 
 // @@ currently not implemented
-//	void	sound_stream_loader(stream* in, int tag_type, movie_definition_sub* m)
+//	void	sound_stream_loader(stream* in, int tag_type, movie_definition* m)
 //	// Load the various stream-related tags: SoundStreamHead,
 //	// SoundStreamHead2, SoundStreamBlock.
 //	{
Index: gnash/server/styles.cpp
diff -u gnash/server/styles.cpp:1.5 gnash/server/styles.cpp:1.6
--- gnash/server/styles.cpp:1.5	Sat Feb 25 03:15:51 2006
+++ gnash/server/styles.cpp	Sun Feb 26 21:44:53 2006
@@ -11,6 +11,7 @@
 #include "log.h"
 #include "render.h"
 #include "stream.h"
+#include "Movie.h"
 
 namespace gnash {
 	//
@@ -50,7 +51,7 @@
 	{
 	}
 
-	void	fill_style::read(stream* in, int tag_type, movie_definition_sub* md)
+	void	fill_style::read(stream* in, int tag_type, movie_definition* md)
 	{
 		m_type = in->read_u8();
 
Index: gnash/server/styles.h
diff -u gnash/server/styles.h:1.3 gnash/server/styles.h:1.4
--- gnash/server/styles.h:1.3	Sat Feb 25 03:54:03 2006
+++ gnash/server/styles.h	Sun Feb 26 21:44:53 2006
@@ -38,7 +38,7 @@
 		fill_style();
 		virtual ~fill_style();
 
-		void	read(stream* in, int tag_type, movie_definition_sub* m);
+		void	read(stream* in, int tag_type, movie_definition* m);
 		rgba	sample_gradient(int ratio) const;
 		gnash::bitmap_info*	create_gradient_bitmap() const;
 		virtual void	apply(int fill_side, float ratio) const;
@@ -66,10 +66,10 @@
 	struct morph_fill_style : public base_fill_style
 	{
 		morph_fill_style();
-		morph_fill_style(stream* in, movie_definition_sub* m);
+		morph_fill_style(stream* in, movie_definition* m);
 		virtual ~morph_fill_style();
 		
-		void read(stream* in, movie_definition_sub* m);
+		void read(stream* in, movie_definition* m);
 		rgba sample_gradient(int ratio, float morph);
 		bitmap_info* create_gradient_bitmap(float morph) const;
 		virtual void apply(int fill_side, float morph) const;
Index: gnash/server/text.cpp
diff -u gnash/server/text.cpp:1.7 gnash/server/text.cpp:1.8
--- gnash/server/text.cpp:1.7	Sat Feb 25 03:54:03 2006
+++ gnash/server/text.cpp	Sun Feb 26 21:44:53 2006
@@ -17,10 +17,11 @@
 #include "render.h"
 #include "textformat.h"
 #include "text.h"
+#include "Movie.h"
 
 namespace gnash {
 
-	void text_style::resolve_font(movie_definition_sub* root_def) const
+	void text_style::resolve_font(movie_definition* root_def) const
 	{
 		if (m_font == NULL)
 		{
@@ -50,7 +51,7 @@
 		const matrix& this_mat,
 		character* inst,
 		const std::vector<text_glyph_record>& records,
-		movie_definition_sub* root_def)
+		movie_definition* root_def)
 	{
 		static std::vector<fill_style>	s_dummy_style;	// used to pass a color on to \
shape_character::display()  static std::vector<line_style>	s_dummy_line_style;
@@ -175,7 +176,7 @@
 	// 
 
 	void text_character_def::read(stream* in, int tag_type,
-			movie_definition_sub* m)
+			movie_definition* m)
 	{
 		assert(m != NULL);
 		assert(tag_type == 11 || tag_type == 33);
@@ -296,7 +297,7 @@
 
 
 	/// Read a DefineText tag.
-	void	define_text_loader(stream* in, int tag_type, movie_definition_sub* m)
+	void	define_text_loader(stream* in, int tag_type, movie_definition* m)
 	{
 		assert(tag_type == 11 || tag_type == 33);
 
@@ -318,7 +319,7 @@
 
 	void
 	edit_text_character_def::read(stream* in, int tag_type,
-			movie_definition_sub* m)
+			movie_definition* m)
 	{
 		assert(m != NULL);
 		assert(tag_type == 37);
@@ -936,7 +937,7 @@
 	}
 
 
-	void	define_edit_text_loader(stream* in, int tag_type, movie_definition_sub* m)
+	void	define_edit_text_loader(stream* in, int tag_type, movie_definition* m)
 	// Read a DefineText tag.
 	{
 		assert(tag_type == 37);
Index: gnash/server/text.h
diff -u gnash/server/text.h:1.3 gnash/server/text.h:1.4
--- gnash/server/text.h:1.3	Sat Feb 25 03:54:03 2006
+++ gnash/server/text.h	Sun Feb 26 21:44:53 2006
@@ -57,7 +57,7 @@
 		{
 		}
 
-		void	resolve_font(movie_definition_sub* root_def) const;
+		void	resolve_font(movie_definition* root_def) const;
 	};
 
 
@@ -84,19 +84,19 @@
 	///
 	struct text_character_def : public character_def
 	{
-		movie_definition_sub*	m_root_def;
+		movie_definition*	m_root_def;
 		rect	m_rect;
 		matrix	m_matrix;
 		std::vector<text_glyph_record>	m_text_glyph_records;
 
-		text_character_def(movie_definition_sub* root_def)
+		text_character_def(movie_definition* root_def)
 			:
 			m_root_def(root_def)
 		{
 			assert(m_root_def);
 		}
 
-		void read(stream* in, int tag_type, movie_definition_sub* m);
+		void read(stream* in, int tag_type, movie_definition* m);
 
 		/// Draw the string.
 		void display(character* inst);
@@ -110,7 +110,7 @@
 	///
 	struct edit_text_character_def : public character_def
 	{
-		movie_definition_sub*	m_root_def;
+		movie_definition*	m_root_def;
 		rect			m_rect;
 		tu_string		m_default_name;
 		text_format		m_format;
@@ -191,7 +191,7 @@
 		float	m_leading;
 		tu_string	m_default_text;
 
-		edit_text_character_def(movie_definition_sub* root_def)
+		edit_text_character_def(movie_definition* root_def)
 			:
 			m_root_def(root_def),
 			m_word_wrap(false),
@@ -233,7 +233,7 @@
 
 
 		/// Initialize from SWF input stream (tag 37)
-		void read(stream* in, int tag_type, movie_definition_sub* m);
+		void read(stream* in, int tag_type, movie_definition* m);
 	};
 
 	/// ...
Index: gnash/testsuite/actionscript.all/Makefile.am
diff -u gnash/testsuite/actionscript.all/Makefile.am:1.16 \
                gnash/testsuite/actionscript.all/Makefile.am:1.17
--- gnash/testsuite/actionscript.all/Makefile.am:1.16	Wed Feb 15 10:34:23 2006
+++ gnash/testsuite/actionscript.all/Makefile.am	Sun Feb 26 21:44:53 2006
@@ -121,14 +121,14 @@
 #  MAKESWF_FLAGS=-DUSE_XTRACE make Whatever.swf
 .as.swf: 
 	@if test x"$(MAKESWF)" != x; then \
-	  $(MAKESWF) $(MAKESWF_FLAGS) -o $@ $< ; \
+	  $(MAKESWF) -DOUTPUT_VERSION=6 -v6 $(MAKESWF_FLAGS) -o $@ $< ; \
 	else \
 	  echo "You need to install Ming to compile"; \
 	fi
 
 .as.vswf: 
 	@if test x"$(MAKESWF)" != x; then \
-	  $(MAKESWF) -DUSE_XTRACE $(MAKESWF_FLAGS) -o $@ $< ; \
+	  $(MAKESWF) -DUSE_XTRACE -DOUTPUT_VERSION=6 -v6 $(MAKESWF_FLAGS) -o $@ $< ; \
 	else \
 	  echo "You need to install Ming to compile"; \
 	fi
Index: gnash/utilities/processor.cpp
diff -u gnash/utilities/processor.cpp:1.4 gnash/utilities/processor.cpp:1.5
--- gnash/utilities/processor.cpp:1.4	Sat Feb 25 03:54:03 2006
+++ gnash/utilities/processor.cpp	Sun Feb 26 21:44:53 2006
@@ -16,6 +16,7 @@
 #include "tu_file.h"
 #include "container.h"
 #include "gnash.h"
+#include "Movie.h"
 
 bool gofast = false;		// FIXME: this flag gets set based on
 				// an XML message written using


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic