Jump to content
Sign in to follow this  
Guest

lines with gmax

Recommended Posts

Guest christian

Has anyone got lines to work with gmax?I tried the LINES_ material, but it seems as if that's used to build wireframe buildings. I want to make antennas on a building though. I tried to handcode some lines with the new DRAW_LINES, but the lines go completely berserk. I suspect that this feature doesn't work yet...Cheers, Christian

Share this post


Link to post
Share on other sites
Guest

I concur, every effort has resulted in only partial display...looks wacky.B

Share this post


Link to post
Share on other sites
Guest

Hi I have tried lines using Scasm commands and they don't work properly, specially at night, as either they become completelly full black or lighted as a candle.....Rafael

Share this post


Link to post
Share on other sites
Guest christian

That's because the vertices have normal vectors, which is stupid in the first place for lines. I don't know if you can set the normal vectors to 0.0, 0.0, 0.0...I can't get the lines to draw in an ordely fashion at all! The go all over the place. Can you please post a working scasm example (I can translate to bglc myself)?Cheers, Christian

Share this post


Link to post
Share on other sites

What do you exactly want to draw? I have used the lines_ prefix with success to draw a set of line with the shape of a cone (so they all end in one point). This worked fine. Do you want to draw a single line maybe?Arno


Member Netherlands 2000 Scenery Team[a href=http://home.wanadoo.nl/arno.gerretsen]http://home.wanadoo.nl/arno.gerretsen/banner.jpg[/a]

Arno

If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done.

FSDeveloper.com | Former Microsoft FS MVP | Blog

Share this post


Link to post
Share on other sites
Guest

Hi Christian,Phew...I did some test about 2 months agor or so...things are a litle far now in my memory.........by here goes an example.I draw polygons as well using the same line vertex,they are only visisble fron the front, so we can see better what is going on. You will notice that at night you will not see the lines at all, unless when using lightning. I can send you the example macro bgl compiled file if you wish.=================================================set( fsvers 0x800 )Area( C %1 %2 22 )IfVarRange( :lb01 346 %12 4 ) PerspectiveCall( :lb02 ) ShadowCall( :lb02 ):lb01Jump32( :lb99 ):lb02mif( %11 ) RefPoint( 2 :lb03 %4 %1 %2 v1= %10 E= %11 %13 %14 )melse RefPoint( 7 :lb03 %4 %1 %2 v1= %10 %13 %14 )mifendRotatedCall( :lb04 0 0 %5 ):lb03Return:lb04BglVersion( 800 )MaterialList( 0 1.0 0.0 0.0 0.5 0.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 0.0 ; 50% transparency 1.0 0.0 0.0 0.5 0.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0 1.0 0.0 0.0 0.5 0.0 ; 50% transparency Night lighted 1.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 0.0 ; Full opaque 1.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0 1.0 0.0 0.0 1.0 0.0 ; Full opaque Night lighted )VertexList( 0-17 0 0 0.0 0.0 -1.0 0 0 ; #V00000-17 10 0 0.0 0.0 -1.0 0 0 ; #V00001-7 10 0 0.0 0.0 -1.0 0 0 ; #V00002-7 0 0 0.0 0.0 -1.0 0 0 ; #V00003-5 0 0 0.0 0.0 -1.0 0 0 ; #V00004-5 14 0 0.0 0.0 -1.0 0 0 ; #V000055 14 0 0.0 0.0 -1.0 0 0 ; #V000065 0 0 0.0 0.0 -1.0 0 0 ; #V000077 0 0 0.0 0.0 -1.0 0 0 ; #V000087 20 0 0.0 0.0 -1.0 0 0 ; #V0000917 20 0 0.0 0.0 -1.0 0 0 ; #V0001017 0 0 0.0 0.0 -1.0 0 0 ; #V0001120 0 0 0.0 0.0 -1.0 0 0 ; #V0001220 30 0 0.0 0.0 -1.0 0 0 ; #V0001330 30 0 0.0 0.0 -1.0 0 0 ; #V0001430 0 0 0.0 0.0 -1.0 0 0 ; #V00015 )SetMaterial( 0 -1 ) ; 50% transparencyDrawTrilist( 0 2 1 0 3 2 0 )DrawLineList( 0 0 1 1 2 2 3 3 0 )SetMaterial( 1 -1 ) ; 50% transparency lightedDrawTrilist( 0 6 5 4 7 6 4 )DrawLineList( 0 4 5 5 6 6 7 7 4 )SetMaterial( 2 -1 ) ; Full opaqueDrawTrilist( 0 10 9 8 11 10 8 )DrawLineList( 0 8 9 9 10 10 11 11 8 )SetMaterial( 3 -1 ) ; Full opaque lightedDrawTrilist( 0 14 13 12 15 14 12 )DrawLineList( 0 12 13 13 14 14 15 15 12 )EndVersionReturn:lb99EndA===================================Best regards,Rafael>That's because the vertices have normal vectors, which is >stupid in the first place for lines. I don't know if you can >set the normal vectors to 0.0, 0.0, 0.0... >>I can't get the lines to draw in an ordely fashion at all! >The go all over the place. Can you please post a working >scasm example (I can translate to bglc myself)? >>Cheers, Christian

Share this post


Link to post
Share on other sites
Guest christian

Yes. I'm wondering if that's possible at all.Cheers, Christian

Share this post


Link to post
Share on other sites
Guest christian

Thanks. It looks like your lines are closed. Maybe that's the key, ie maybe it's not possible to just draw one single line?Cheers, Christian

Share this post


Link to post
Share on other sites
Guest

Thank you Rafael the above is real helpfull I thought there was a way to get splines to show properly in 2002 and now we know. Dan

Share this post


Link to post
Share on other sites
Guest

Hi Christian, +----------------+-----------+ 0 1 2The way it works is quite weird and archaic, previous version ways of doing lines was better....As in the design, you have two lines, to draw the lines you have to do:DrawListLines ( 0 0 1 1 2 )It would be wiser to do the full string in one shot, as 0 1 2Yes, you can draw just one line, no problems, as 0 1 in the exampleBestRafael >It looks like your lines are closed. Maybe that's the key, >ie maybe it's not possible to just draw one single line? >>Cheers, Christian

Share this post


Link to post
Share on other sites
Guest christian

Weird, I did exactly that (in BGLC that is), but as I said it completely messed things up.I'll have to do some more experiments then...Cheers, Christian

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...