# PureBasic Forum

 It is currently Thu May 23, 2013 2:04 am

 All times are UTC + 1 hour

 Page 14 of 15 [ 224 posts ] Go to page Previous  1 ... 11, 12, 13, 14, 15  Next
 Print view Previous topic | Next topic
Author Message
 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Sun Jan 15, 2012 5:10 am

Joined: Sat Oct 17, 2009 10:51 pm
Posts: 919
It is not false. Textures should be in a power of two. The manual merely lists some of the more common sizes that are a power of two. Naturally, it will not list all possible sizes as this would be infinite. What sizes you can actually use are a limit of your GFX card and will also depend on the rendering API (and version) being used.

As to rectangle vs square, I have been out of school for a long time, so I may not be remembering correctly, but I thought a rectangle was a quadrilateral with four right angles and a square was a rectangle with four equal sides? If this is correct, then the manual would be listing rectangular dimensions. However, it is obviously not listing oblong rectangular dimensions, just square rectangular dimensions.

_________________
If you are new to PB you should check out the CodeArchiv. It has examples for almost everything you would want to do in PB.

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Sun Jan 15, 2012 6:57 am
 Enthusiast

Joined: Wed Oct 22, 2003 2:51 am
Posts: 734
Kuron wrote:
It is not false. Textures should be in a power of two. The manual merely lists some of the more common sizes that are a power of two. Naturally, it will not list all possible sizes as this would be infinite. What sizes you can actually use are a limit of your GFX card and will also depend on the rendering API (and version) being used.

As to rectangle vs square, I have been out of school for a long time, so I may not be remembering correctly, but I thought a rectangle was a quadrilateral with four right angles and a square was a rectangle with four equal sides? If this is correct, then the manual would be listing rectangular dimensions. However, it is obviously not listing oblong rectangular dimensions, just square rectangular dimensions.

As the Help file says :

Texture need to be Square ---> Square mean 64X64, 128X128, 256X256 or in the other end the texture Width = Texture Height and this is not true.

X-Wing Alliance game created by Totally Games/LucasArts use rectangular texture in their opt file (the opt file contain the geometry and textures packed together).

Best regards
Guimauve

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Sun Jan 15, 2012 12:25 pm

Joined: Sat Oct 17, 2009 10:51 pm
Posts: 919
I replied to your exact words previously. If you have an issue with what I was replying to, you need to take it up with the person who made the post that I was replying to, which would appear to be you. You can contact yourself here.

Guimauve wrote:
As the Help file says :

Texture need to be Square ---> Square mean 64X64, 128X128, 256X256 or in the other end the texture Width = Texture Height and this is not true.
These words above are also false. The manual does NOT say this. The manual clearly says: It's strongly recommended to make the texture square and with power of 2 width/height: 64x64, 128x128, 256x256... Old GFX cards can have limitation, so if possible limit the texture size to 256x256.

The manual says it is strongly recommended to make the texture square, it does NOT say the texture needs to be square.

The manual also says and with power of 2 width/height. The manual does NOT say the width and height have to be equal powers of 2.

As I stated before: The manual merely lists some of the more common sizes that are a power of two. Naturally, it will not list all possible sizes as this would be infinite. What sizes you can actually use are a limit of your GFX card and will also depend on the rendering API (and version) being used.

Guimauve wrote:
X-Wing Alliance game created by Totally Games/LucasArts use rectangular texture in their opt file (the opt file contain the geometry and textures packed together).
I am very happy for them. Achievements like this deserve to be recognized and praised. Perhaps you should send them a congratulatory cake, or at least a card and some flowers?

_________________
If you are new to PB you should check out the CodeArchiv. It has examples for almost everything you would want to do in PB.

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Sun Jan 15, 2012 3:52 pm
 Enthusiast

Joined: Wed Oct 22, 2003 2:51 am
Posts: 734
@Kuron : SORRY DARLING !

Bye Bye
Guimauve

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Wed Jan 18, 2012 12:15 pm

Joined: Thu Apr 21, 2005 2:38 pm
Posts: 814
Location: Germany
The code example for CreatePopupMenu() in PB's help file contains the Windows API
constant #WM_RButtonDown and therefore doesn't work in PB's Linux and MacOS
versions. I therefore modified that code example for Linux:
Code:
ProcedureC RightClickHandler(*Event.GdkEventButton, *UserData, *DestroyNotify)
If *Event\type = #GDK_BUTTON_PRESS
If *Event\button = 3                ; Right mouse button?
EndIf
EndIf
gtk_main_do_event_(*Event)
EndProcedure

If OpenWindow(0, 200, 200, 200, 120, "Popup-Menu Example")
gdk_event_handler_set_(@RightClickHandler(), 0, 0)
MenuItem(1, "Open")      ; You can use all commands for creating a menu
EndIf
Repeat
Select WaitWindowEvent()     ; check for window events
Case 1 : Debug "Menu: Open"
Case 2 : Debug "Menu: Save"
Case 3 : Debug "Menu: Save as"
Case 4 : Quit = 1
Case 5 : Debug "Menu: PureBasic.exe"
Case 6 : Debug "Menu: Text.txt"
EndSelect
Case #PB_Event_CloseWindow
Quit = 1
EndSelect
Until Quit = 1
EndIf

And this is the modified code example for MacOS:
Code:
#kEventClassWindow = \$77696E64 ; 'wind'

Structure EventTypeSpec
EventClass.L
EventKind.L
EndStructure

ProcedureC RightClickHandler(*NextEventHandler, Event.L, UserData.L)
EndProcedure

Dim EventTypes.EventTypeSpec(0)

If OpenWindow(0, 200, 200, 200, 120, "Popup-Menu Example")
EventTypes(0)\EventClass = #kEventClassWindow
InstallEventHandler_(GetWindowEventTarget_(WindowID(0)), NewEventHandlerUPP_(@RightClickHandler()), 1, @EventTypes(), 0, 0)
MenuItem(1, "Open")      ; You can use all commands for creating a menu
EndIf
Repeat
Select WaitWindowEvent()     ; check for window events
Case 1 : Debug "Menu: Open"
Case 2 : Debug "Menu: Save"
Case 3 : Debug "Menu: Save as"
Case 4 : Quit = 1
Case 5 : Debug "Menu: PureBasic.exe"
Case 6 : Debug "Menu: Text.txt"
EndSelect
Case #PB_Event_CloseWindow
Quit = 1
EndSelect
Until Quit = 1
EndIf

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Fri Jan 20, 2012 2:17 am

Joined: Fri Oct 23, 2009 2:33 am
Posts: 2860
Location: Wales, UK
The Useful Internet Links page has a lot of broken links/discontinued websites.

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Sat Feb 04, 2012 9:47 pm
 PureBasic Team

Joined: Fri Apr 25, 2003 6:14 pm
Posts: 909
Location: Germany (Saxony, Deutscheinsiedel)
Thanks shardik for your code exemples!

But about the CreatePopupMenu() examples: I don't think (even more Fred & freak), that the PB help should be filled with API-related stuff/code examples. So it's already not so good, that the current help example uses a Windows-specific constant.

I think, it's time for a native implementation on all 3 supported OS, which is up to Fred & freak!

_________________
Bye,
...André
(PureBasicTeam::Docs & Support - PureArea.net | Order:: PureBasic | PureVisionXP)

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Sun Feb 12, 2012 10:29 pm
 PureBasic Team

Joined: Fri Apr 25, 2003 6:14 pm
Posts: 909
Location: Germany (Saxony, Deutscheinsiedel)
Shardik wrote:
unfortunately you seem to have forgotten to add a remark to each
SetGadgetItemColor() commands on the Mac don't work (in contrast
to the Windows and Linux version). Do you remember my fancy table
which lists all non-working color commands on the Mac? freak
description which doesn't work with color commands on the Mac:
freak wrote:

All needed notes are added to the manual, for PB4.61...

_________________
Bye,
...André
(PureBasicTeam::Docs & Support - PureArea.net | Order:: PureBasic | PureVisionXP)

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Thu Mar 01, 2012 8:03 pm

Joined: Tue Nov 13, 2007 12:42 pm
Posts: 1307
Location: Manchester, UK
Could "Command lines" and/or "Parameters" be added to the index please and let it point to ProgramParameter...

I've just wasted a good half hour looking for how to get the command line parameters... and as it's something that I rarely use, I can forsee myself doing the same again in a year or two...

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Tue Mar 27, 2012 8:10 am
 Moderator

Joined: Sat Apr 26, 2003 1:11 am
Posts: 1300
complete the physic commands in the docs,
see here:
viewtopic.php?f=16&t=39390&start=25

[Andre on 5th Oct. 2012: done with PB5.00b4]

_________________
SPAMINATOR NR.1

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Tue Mar 27, 2012 10:38 am

Joined: Wed Aug 31, 2005 11:09 pm
Posts: 2240
Location: Italy
Foz wrote:
Could "Command lines" and/or "Parameters" be added to the index please and let it point to ProgramParameter... I've just wasted a good half hour looking for how to get the command line parameters...

Index only match the correct name. If you don' know the correct name and you are looking for it use the search field. Entering "commandline" in the search field returns ProgramParameter.

_________________
[ Home ] [ My PC ] [ New to PB ? ]

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Mon Apr 30, 2012 5:39 pm

Joined: Sat Apr 26, 2003 8:26 am
Posts: 1290
PB help for Chr():
Quote:
Syntax

Text\$ = Chr(ASCII-Value)

Description

Returns the character associated with the given ASCII value.

Works also in Unicode mode (and it should!), so it would be nice to make that clear in the documentation:

"Returns a string with the character associated with the given ASCII/UNICODE value."

Code:
Debug Chr(401)
Debug Chr(956)

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Thu May 10, 2012 1:17 am

Joined: Mon Jul 25, 2005 3:51 pm
Posts: 2401
Location: Utah, USA
On the page for "Array" in the manual the example Array.pb and the help page is missing.

Originally reported in this link by akee.

[Andre on 5th Oct. 2012: works in PB5.00b4]

_________________

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Mon May 14, 2012 10:52 pm
 PureBasic Team

Joined: Fri Apr 25, 2003 6:14 pm
Posts: 909
Location: Germany (Saxony, Deutscheinsiedel)
Danilo wrote:
PB help for Chr():
Works also in Unicode mode (and it should!), so it would be nice to make that clear in the documentation:

_________________
Bye,
...André
(PureBasicTeam::Docs & Support - PureArea.net | Order:: PureBasic | PureVisionXP)

Top

 Post subject: Re: PureBasic Docs - Errors & needed improvements to the manPosted: Sun Aug 05, 2012 2:26 pm

Joined: Fri Oct 23, 2009 2:33 am
Posts: 2860
Location: Wales, UK
Images: The Help does not distinguish between a PB ImageID and an OS Image Handle, which is in fact critical. Please see this thread:
http://www.purebasic.fr/english/viewtopic.php?f=5&t=50761&p=386616#p386616

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.

Top

 Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending
 Page 14 of 15 [ 224 posts ] Go to page Previous  1 ... 11, 12, 13, 14, 15  Next

 All times are UTC + 1 hour

#### Who is online

Users browsing this forum: No registered users and 0 guests

 You cannot post new topics in this forumYou cannot reply to topics in this forumYou cannot edit your posts in this forumYou cannot delete your posts in this forum

Search for:
 Jump to:  Select a forum ------------------ PureBasic    Coding Questions    Game Programming    3D Programming    Assembly Programming    The PureBasic Editor    The PureBasic Form Designer    General Discussion    Feature Requests and Wishlists    Tricks 'n' Tips Bug Reports    Bugs - Windows    Bugs - Linux    Bugs - Mac OSX    Bugs - Documentation OS Specific    AmigaOS    Linux    Windows    Mac OSX Miscellaneous    Announcement    Off Topic Showcase    Applications - Feedback and Discussion    PureFORM & JaPBe    TailBite