Away3D 4.0 + Flex SDK anim compile but don’t load

Software: Away3D 4.x

Olivier R, Newbie
Posted: 03 April 2012 09:20 PM   Total Posts: 4

Hi,
I get very strange behaviour when I compile this simple code :

package{
import away3d.containers.View3D;

import flash.display.Sprite;
import flash.text.*;

[SWF(width=“800”, height=“600”, frameRate=“12”, backgroundColor=”#f0c0f0”)]

public class test extends Sprite{

  private var dbg:TextField;
  private var view:View3D;

  public function test(){
  dbg = new TextField();
  dbg.x = 0;
  dbg.y = 0;
  dbg.width = 100;
  dbg.height = 120;
  dbg.background = true;
  dbg.backgroundColor = 0xc0c0f0;
  dbg.text = “ok”;
  addChild(dbg);
  }
}
}

it compile well, but when I run it, nothing appear, the screen stay white,
and a right click show the menu with just two lines,
one saying that the anim is not loaded,
the other is about adobe flash player ...
if I open a new tab and come back to the anim the background is now #f0c0f0

but now if I comment the following line :

//private var view:View3D;

the textfield is then visible and the right menu is ok ...
I don’t know if it’s an away3d bug,
don’t hesitate to ask if you need some more infos,

my config :
Away3D 4.0 beta
flex_sdk_4.6.0.23201B
Shockwave Flash 11.2 r202 ubuntu/linux 10.04 x86_64
firefox 11.0, chromium 17.0.963.79, opera 11.62

thanks

   

Olivier R, Newbie
Posted: 04 April 2012 07:30 AM   Total Posts: 4   [ # 1 ]

I’ve just try it with away3d from github :
away3d-core-fp11-v4.0.0-beta-34-gca7da2f
I get the same result,
trying to run it in the flashdebugger 11.1,
with a View3D it crash with this error :

(flashplayerdebugger:16775): GLib-GObject-WARNING **: instance with invalid (NULL) class pointer

(flashplayerdebugger:16775): GLib-GObject-CRITICAL **: g_signal_handlers_disconnect_matched: assertion `G_TYPE_CHECK_INSTANCE (instance)’ failed

without the View3D it run well ...

   

Olivier R, Newbie
Posted: 04 April 2012 11:14 AM   Total Posts: 4   [ # 2 ]

trying with the last playerglobal.swc (11.2),
same problem ...

   

Olivier R, Newbie
Posted: 04 April 2012 12:48 PM   Total Posts: 4   [ # 3 ]

erff, that’s a bug between keyboard and chair,
defining static-link-runtime-shared-libraries to true make it run well,
sorry for the noise ...

   

blindspot, Newbie
Posted: 05 April 2012 03:00 AM   Total Posts: 1   [ # 4 ]

thanks for the info…. now it really helpful to me.

 

 

   

charlito, Jr. Member
Posted: 09 April 2012 02:26 PM   Total Posts: 36   [ # 5 ]

hi dude.

srry u couldt get any help before, but this is really far from a bug.. post ur code in the apropiate forum so u can get a faster answare.

im not sure what do you wanna do.
to see any scene.. u need to render it.

the basic will be
*declare ur objects
*declare the material/texture of ur objects
*declare ur meshes
*mesh1=new Mesh(YourObject,YourMaterial)
*addMesh to the view.  //so u could render it
*render ur scene in a EnterFrameEvent or like so.

var myPlane:PlaneGeometry = new PlaneGeometry(10010011false);
var 
texture:ColorMaterial = new ColorMaterial(0x000fff);
var 
myMesh:Mesh = new Mesh(myPlanetexture);
addChild(view);
addEventListener(Event.ENTER_FRAMEloop);
}
   
function loop(e:Event):void
{
 view
.render();

this will be like the super basics…

its weird that such a great frameworks as this has such a lack of good tutorials..
i just dont understand why the creators dont make some..


but. hope i was helpfull

greatings.

 

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X